diff options
author | Simo Sorce <ssorce@redhat.com> | 2010-05-27 03:41:56 -0400 |
---|---|---|
committer | Günther Deschner <gd@samba.org> | 2010-05-28 00:55:53 +0200 |
commit | d9cffc01be58184312a6a7b55bd523cf8daefa78 (patch) | |
tree | a7037d21510273479d752c9c7964264ac12524a1 /source3/smbd | |
parent | 6713f3d945f09a732e620641771d9ff403aca9ef (diff) | |
download | samba-d9cffc01be58184312a6a7b55bd523cf8daefa78.tar.gz samba-d9cffc01be58184312a6a7b55bd523cf8daefa78.tar.bz2 samba-d9cffc01be58184312a6a7b55bd523cf8daefa78.zip |
s3:auth use info3 in auth_serversupplied_info
Signed-off-by: Günther Deschner <gd@samba.org>
Diffstat (limited to 'source3/smbd')
-rw-r--r-- | source3/smbd/lanman.c | 9 | ||||
-rw-r--r-- | source3/smbd/password.c | 6 | ||||
-rw-r--r-- | source3/smbd/process.c | 3 | ||||
-rw-r--r-- | source3/smbd/service.c | 12 | ||||
-rw-r--r-- | source3/smbd/sesssetup.c | 6 | ||||
-rw-r--r-- | source3/smbd/smb2_sesssetup.c | 8 | ||||
-rw-r--r-- | source3/smbd/uid.c | 6 |
7 files changed, 25 insertions, 25 deletions
diff --git a/source3/smbd/lanman.c b/source3/smbd/lanman.c index 77ed2d422f..c0bc9090b8 100644 --- a/source3/smbd/lanman.c +++ b/source3/smbd/lanman.c @@ -113,7 +113,7 @@ static int CopyExpanded(connection_struct *conn, conn->connectpath, conn->server_info->utok.gid, conn->server_info->sanitized_username, - pdb_get_domain(conn->server_info->sam_account), + conn->server_info->info3->base.domain.string, buf); if (!buf) { *p_space_remaining = 0; @@ -164,7 +164,7 @@ static int StrlenExpanded(connection_struct *conn, int snum, char *s) conn->connectpath, conn->server_info->utok.gid, conn->server_info->sanitized_username, - pdb_get_domain(conn->server_info->sam_account), + conn->server_info->info3->base.domain.string, buf); if (!buf) { return 0; @@ -4455,8 +4455,9 @@ static bool api_WWkstaUserLogon(connection_struct *conn,uint16 vuid, } PACKS(&desc,"z",lp_workgroup());/* domain */ - PACKS(&desc,"z", vuser ? pdb_get_logon_script( - vuser->server_info->sam_account) : ""); /* script path */ + PACKS(&desc,"z", vuser ? + vuser->server_info->info3->base.logon_script.string + : ""); /* script path */ PACKI(&desc,"D",0x00000000); /* reserved */ } diff --git a/source3/smbd/password.c b/source3/smbd/password.c index 5cf290c158..809a913d6c 100644 --- a/source3/smbd/password.c +++ b/source3/smbd/password.c @@ -274,12 +274,12 @@ int register_existing_vuid(struct smbd_server_connection *sconn, (unsigned int)vuser->server_info->utok.gid, vuser->server_info->unix_name, vuser->server_info->sanitized_username, - pdb_get_domain(vuser->server_info->sam_account), + vuser->server_info->info3->base.domain.string, vuser->server_info->guest )); DEBUG(3, ("register_existing_vuid: User name: %s\t" "Real name: %s\n", vuser->server_info->unix_name, - pdb_get_fullname(vuser->server_info->sam_account))); + vuser->server_info->info3->base.full_name.string)); if (!vuser->server_info->ptok) { DEBUG(1, ("register_existing_vuid: server_info does not " @@ -324,7 +324,7 @@ int register_existing_vuid(struct smbd_server_connection *sconn, set_current_user_info( vuser->server_info->sanitized_username, vuser->server_info->unix_name, - pdb_get_domain(vuser->server_info->sam_account)); + vuser->server_info->info3->base.domain.string); return vuser->vuid; diff --git a/source3/smbd/process.c b/source3/smbd/process.c index ed70b9cdd8..c8497577a4 100644 --- a/source3/smbd/process.c +++ b/source3/smbd/process.c @@ -1451,8 +1451,7 @@ static connection_struct *switch_message(uint8 type, struct smb_request *req, in set_current_user_info( vuser->server_info->sanitized_username, vuser->server_info->unix_name, - pdb_get_domain(vuser->server_info - ->sam_account)); + vuser->server_info->info3->base.domain.string); } } } diff --git a/source3/smbd/service.c b/source3/smbd/service.c index 689f0e2f07..afd9cad27d 100644 --- a/source3/smbd/service.c +++ b/source3/smbd/service.c @@ -589,7 +589,7 @@ static NTSTATUS create_connection_server_info(struct smbd_server_connection *sco } } else { if (!user_ok_token(vuid_serverinfo->unix_name, - pdb_get_domain(vuid_serverinfo->sam_account), + vuid_serverinfo->info3->base.domain.string, vuid_serverinfo->ptok, snum)) { DEBUG(2, ("user '%s' (from session setup) not " "permitted to access this share " @@ -788,7 +788,7 @@ connection_struct *make_connection_snum(struct smbd_server_connection *sconn, conn->connectpath, conn->server_info->utok.gid, conn->server_info->sanitized_username, - pdb_get_domain(conn->server_info->sam_account), + conn->server_info->info3->base.domain.string, lp_pathname(snum)); if (!s) { *pstatus = NT_STATUS_NO_MEMORY; @@ -915,7 +915,7 @@ connection_struct *make_connection_snum(struct smbd_server_connection *sconn, conn->connectpath, conn->server_info->utok.gid, conn->server_info->sanitized_username, - pdb_get_domain(conn->server_info->sam_account), + conn->server_info->info3->base.domain.string, lp_rootpreexec(snum)); DEBUG(5,("cmd=%s\n",cmd)); ret = smbrun(cmd,NULL); @@ -953,7 +953,7 @@ connection_struct *make_connection_snum(struct smbd_server_connection *sconn, conn->connectpath, conn->server_info->utok.gid, conn->server_info->sanitized_username, - pdb_get_domain(conn->server_info->sam_account), + conn->server_info->info3->base.domain.string, lp_preexec(snum)); ret = smbrun(cmd,NULL); TALLOC_FREE(cmd); @@ -1257,7 +1257,7 @@ void close_cnum(connection_struct *conn, uint16 vuid) conn->connectpath, conn->server_info->utok.gid, conn->server_info->sanitized_username, - pdb_get_domain(conn->server_info->sam_account), + conn->server_info->info3->base.domain.string, lp_postexec(SNUM(conn))); smbrun(cmd,NULL); TALLOC_FREE(cmd); @@ -1273,7 +1273,7 @@ void close_cnum(connection_struct *conn, uint16 vuid) conn->connectpath, conn->server_info->utok.gid, conn->server_info->sanitized_username, - pdb_get_domain(conn->server_info->sam_account), + conn->server_info->info3->base.domain.string, lp_rootpostexec(SNUM(conn))); smbrun(cmd,NULL); TALLOC_FREE(cmd); diff --git a/source3/smbd/sesssetup.c b/source3/smbd/sesssetup.c index df39aed0ed..a561e3a593 100644 --- a/source3/smbd/sesssetup.c +++ b/source3/smbd/sesssetup.c @@ -529,9 +529,9 @@ static void reply_spnego_kerberos(struct smb_request *req, * we end up with the local netbios name in substitutions for * %D. */ - if (server_info->sam_account != NULL) { - pdb_set_domain(server_info->sam_account, - domain, PDB_SET); + if (server_info->info3 != NULL) { + server_info->info3->base.domain.string = + talloc_strdup(server_info->info3, domain); } } diff --git a/source3/smbd/smb2_sesssetup.c b/source3/smbd/smb2_sesssetup.c index 92e77a5ff2..7ac003fad6 100644 --- a/source3/smbd/smb2_sesssetup.c +++ b/source3/smbd/smb2_sesssetup.c @@ -371,9 +371,9 @@ static NTSTATUS smbd_smb2_session_setup_krb5(struct smbd_smb2_session *session, * we end up with the local netbios name in substitutions for * %D. */ - if (session->server_info->sam_account != NULL) { - pdb_set_domain(session->server_info->sam_account, - domain, PDB_SET); + if (session->server_info->info3 != NULL) { + session->server_info->info3->base.domain.string = + talloc_strdup(session->server_info->info3, domain); } } @@ -979,7 +979,7 @@ NTSTATUS smbd_smb2_request_check_session(struct smbd_smb2_request *req) set_current_user_info(session->server_info->sanitized_username, session->server_info->unix_name, - pdb_get_domain(session->server_info->sam_account)); + session->server_info->info3->base.domain.string); req->session = session; diff --git a/source3/smbd/uid.c b/source3/smbd/uid.c index 5e61098ecb..f34ec5540a 100644 --- a/source3/smbd/uid.c +++ b/source3/smbd/uid.c @@ -104,13 +104,13 @@ static bool check_user_ok(connection_struct *conn, } if (!user_ok_token(server_info->unix_name, - pdb_get_domain(server_info->sam_account), + server_info->info3->base.domain.string, server_info->ptok, snum)) return(False); readonly_share = is_share_read_only_for_token( server_info->unix_name, - pdb_get_domain(server_info->sam_account), + server_info->info3->base.domain.string, server_info->ptok, conn); @@ -132,7 +132,7 @@ static bool check_user_ok(connection_struct *conn, admin_user = token_contains_name_in_list( server_info->unix_name, - pdb_get_domain(server_info->sam_account), + server_info->info3->base.domain.string, NULL, server_info->ptok, lp_admin_users(snum)); if (valid_vuid) { |