mirror of
https://github.com/samba-team/samba.git
synced 2025-08-26 01:49:31 +03:00
winbind: Use dom_sid_str_buf
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Gary Lockyer <gary@catalyst.net.nz>
This commit is contained in:
committed by
Andrew Bartlett
parent
1d5c00a34d
commit
534620d160
@ -30,6 +30,7 @@
|
||||
#include "smbldap.h"
|
||||
#include "nsswitch/winbind_client.h"
|
||||
#include "lib/winbind_util.h"
|
||||
#include "libcli/security/dom_sid.h"
|
||||
|
||||
/*
|
||||
* Config and connection info per domain.
|
||||
@ -454,6 +455,7 @@ static NTSTATUS idmap_rfc_2307_sids_to_names(TALLOC_CTX *mem_ctx,
|
||||
enum lsa_SidType lsa_type;
|
||||
struct id_map *id = ids[i];
|
||||
struct idmap_rfc2307_map *map = &maps[i];
|
||||
struct dom_sid_buf buf;
|
||||
bool b;
|
||||
|
||||
/* by default calls to winbindd are disabled
|
||||
@ -465,7 +467,7 @@ static NTSTATUS idmap_rfc_2307_sids_to_names(TALLOC_CTX *mem_ctx,
|
||||
|
||||
if (!b) {
|
||||
DEBUG(1, ("Lookup sid %s failed.\n",
|
||||
sid_string_dbg(ids[i]->sid)));
|
||||
dom_sid_str_buf(ids[i]->sid, &buf)));
|
||||
continue;
|
||||
}
|
||||
|
||||
@ -491,7 +493,8 @@ static NTSTATUS idmap_rfc_2307_sids_to_names(TALLOC_CTX *mem_ctx,
|
||||
|
||||
default:
|
||||
DEBUG(1, ("Unknown lsa type %d for sid %s\n",
|
||||
lsa_type, sid_string_dbg(id->sid)));
|
||||
lsa_type,
|
||||
dom_sid_str_buf(id->sid, &buf)));
|
||||
id->status = ID_UNMAPPED;
|
||||
continue;
|
||||
}
|
||||
|
@ -108,9 +108,10 @@ struct tevent_req *wb_sids2xids_send(TALLOC_CTX *mem_ctx,
|
||||
* the same index.
|
||||
*/
|
||||
for (i=0; i<state->num_sids; i++) {
|
||||
struct dom_sid_buf buf;
|
||||
|
||||
DEBUG(10, ("SID %d: %s\n", (int)i,
|
||||
sid_string_dbg(&state->sids[i])));
|
||||
dom_sid_str_buf(&state->sids[i], &buf)));
|
||||
|
||||
if (wb_sids2xids_in_cache(&state->sids[i], &state->cached[i])) {
|
||||
continue;
|
||||
|
@ -19,6 +19,7 @@
|
||||
|
||||
#include "includes.h"
|
||||
#include "winbindd.h"
|
||||
#include "libcli/security/dom_sid.h"
|
||||
|
||||
struct winbindd_lookupname_state {
|
||||
struct tevent_context *ev;
|
||||
@ -112,8 +113,10 @@ NTSTATUS winbindd_lookupname_recv(struct tevent_req *req,
|
||||
NTSTATUS status;
|
||||
|
||||
if (tevent_req_is_nterror(req, &status)) {
|
||||
struct dom_sid_buf buf;
|
||||
DEBUG(5, ("Could not convert sid %s: %s\n",
|
||||
sid_string_dbg(&state->sid), nt_errstr(status)));
|
||||
dom_sid_str_buf(&state->sid, &buf),
|
||||
nt_errstr(status)));
|
||||
return status;
|
||||
}
|
||||
sid_to_fstring(response->data.sid.sid, &state->sid);
|
||||
|
Reference in New Issue
Block a user