1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-22 13:34:15 +03:00

s3-auth use security_token_has_sid() from the common code

The wrapper call is left here to avoid changing semantics for
the NULL parameter case.

Andrew Bartlett

Signed-off-by: Andrew Tridgell <tridge@samba.org>
This commit is contained in:
Andrew Bartlett 2010-09-17 14:55:56 +10:00 committed by Andrew Tridgell
parent deb7c02436
commit 58cf83732a

View File

@ -36,17 +36,10 @@
bool nt_token_check_sid ( const struct dom_sid *sid, const struct security_token *token )
{
int i;
if ( !sid || !token )
return False;
for ( i=0; i<token->num_sids; i++ ) {
if ( dom_sid_equal( sid, &token->sids[i] ) )
return True;
}
return False;
return security_token_has_sid(token, sid);
}
bool nt_token_check_domain_rid( struct security_token *token, uint32 rid )
@ -983,7 +976,7 @@ bool user_in_group_sid(const char *username, const struct dom_sid *group_sid)
return False;
}
result = nt_token_check_sid(group_sid, token);
result = security_token_has_sid(token, group_sid);
TALLOC_FREE(mem_ctx);
return result;