From 170b345e0c688b178eb37a73a8110dec68a8ae31 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Fri, 17 Sep 2010 15:31:28 +1000 Subject: s3-auth Use security_token_debug() from common code This prints the security token including the privileges as strings instead of just a bitmap. Andrew Bartlett Signed-off-by: Andrew Tridgell --- source3/auth/auth_util.c | 2 +- source3/auth/token_util.c | 26 -------------------------- 2 files changed, 1 insertion(+), 27 deletions(-) (limited to 'source3/auth') diff --git a/source3/auth/auth_util.c b/source3/auth/auth_util.c index 98cef79141..73713093c2 100644 --- a/source3/auth/auth_util.c +++ b/source3/auth/auth_util.c @@ -516,7 +516,7 @@ NTSTATUS create_local_token(struct auth_serversupplied_info *server_info) &server_info->ptok->num_sids); } - debug_nt_user_token(DBGC_AUTH, 10, server_info->ptok); + security_token_debug(DBGC_AUTH, 10, server_info->ptok); debug_unix_user_token(DBGC_AUTH, 10, server_info->utok.uid, server_info->utok.gid, diff --git a/source3/auth/token_util.c b/source3/auth/token_util.c index 17078d1e96..1a7c4816e8 100644 --- a/source3/auth/token_util.c +++ b/source3/auth/token_util.c @@ -641,32 +641,6 @@ static NTSTATUS finalize_local_nt_token(struct security_token *result, return NT_STATUS_OK; } -/**************************************************************************** - prints a struct security_token to debug output. -****************************************************************************/ - -void debug_nt_user_token(int dbg_class, int dbg_lev, struct security_token *token) -{ - size_t i; - - if (!token) { - DEBUGC(dbg_class, dbg_lev, ("NT user token: (NULL)\n")); - return; - } - - DEBUGC(dbg_class, dbg_lev, - ("NT user token of user %s\n", - sid_string_dbg(&token->sids[0]) )); - DEBUGADDC(dbg_class, dbg_lev, - ("contains %lu SIDs\n", (unsigned long)token->num_sids)); - for (i = 0; i < token->num_sids; i++) - DEBUGADDC(dbg_class, dbg_lev, - ("SID[%3lu]: %s\n", (unsigned long)i, - sid_string_dbg(&token->sids[i]))); - - DEBUGADDC(dbg_class, dbg_lev,("Privilege mask: 0x%llx\n", (unsigned long long)token->privilege_mask)); -} - /**************************************************************************** prints a UNIX 'token' to debug output. ****************************************************************************/ -- cgit