diff options
author | Volker Lendecke <vl@samba.org> | 2008-04-30 17:42:39 +0200 |
---|---|---|
committer | Volker Lendecke <vl@samba.org> | 2008-05-05 18:28:59 +0200 |
commit | bec1dfab27be3db888eeb451b4547f16e08e93c3 (patch) | |
tree | f1b85618a0bf8ecd39a07d0039fb3b843477f6f1 /source3/auth | |
parent | a683625d7fe0be58da23b98828b445478df1606f (diff) | |
download | samba-bec1dfab27be3db888eeb451b4547f16e08e93c3.tar.gz samba-bec1dfab27be3db888eeb451b4547f16e08e93c3.tar.xz samba-bec1dfab27be3db888eeb451b4547f16e08e93c3.zip |
Remove "userdom_struct user" from "struct user_struct"
(This used to be commit 420de035237bb08bc470c9eb820f3da2edaa6805)
Diffstat (limited to 'source3/auth')
-rw-r--r-- | source3/auth/auth_util.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/source3/auth/auth_util.c b/source3/auth/auth_util.c index 78f275d8672..51164256065 100644 --- a/source3/auth/auth_util.c +++ b/source3/auth/auth_util.c @@ -1107,6 +1107,7 @@ static NTSTATUS make_new_server_info_guest(auth_serversupplied_info **server_inf DOM_SID guest_sid; bool ret; char zeros[16]; + fstring tmp; if ( !(sampass = samu_new( NULL )) ) { return NT_STATUS_NO_MEMORY; @@ -1145,6 +1146,9 @@ static NTSTATUS make_new_server_info_guest(auth_serversupplied_info **server_inf (*server_info)->user_session_key = data_blob(zeros, sizeof(zeros)); (*server_info)->lm_session_key = data_blob(zeros, sizeof(zeros)); + alpha_strcpy(tmp, pdb_get_username(sampass), ". _-$", sizeof(tmp)); + (*server_info)->sanitized_username = talloc_strdup(*server_info, tmp); + return NT_STATUS_OK; } @@ -1200,6 +1204,12 @@ static auth_serversupplied_info *copy_serverinfo(auth_serversupplied_info *src) return NULL; } + dst->sanitized_username = talloc_strdup(dst, src->sanitized_username); + if (!dst->sanitized_username) { + TALLOC_FREE(dst); + return NULL; + } + return dst; } |