1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-27 03:21:53 +03:00

cmd_lsa_lookup_sids: Check return code from string_to_sid; skip SIDs

which are not valid.
(This used to be commit bfb6104521)
This commit is contained in:
Martin Pool 2003-02-18 01:35:19 +00:00
parent 49c3018cbc
commit 05e3070b23

View File

@ -210,8 +210,11 @@ static NTSTATUS cmd_lsa_lookup_sids(struct cli_state *cli, TALLOC_CTX *mem_ctx,
goto done;
}
for (i = 0; i < argc - 1; i++)
string_to_sid(&sids[i], argv[i + 1]);
for (i = 0; i < argc - 1; i++)
if (!string_to_sid(&sids[i], argv[i + 1])) {
result = NT_STATUS_INVALID_SID;
goto done;
}
/* Lookup the SIDs */