[SCM] Samba Shared Repository - branch v3-6-test updated

Karolin Seeger kseeger at samba.org
Tue Jul 26 13:23:34 MDT 2011


The branch, v3-6-test has been updated
       via  e173f04 Fix bug 8314] - smbd crash with unknown user.
      from  589bc35 s3 swat: Create random nonce in CGI mode

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-6-test


- Log -----------------------------------------------------------------
commit e173f04a822944e96171866d9fbf43301cd611a4
Author: Jeremy Allison <jra at samba.org>
Date:   Fri Jul 22 16:42:51 2011 -0700

    Fix bug 8314] - smbd crash with unknown user.
    
    All other auth modules code with being called with
    auth_method->private_data being NULL, make the auth_server
    module cope with this too.

-----------------------------------------------------------------------

Summary of changes:
 source3/auth/auth_server.c |   15 +++++++++++----
 1 files changed, 11 insertions(+), 4 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/auth/auth_server.c b/source3/auth/auth_server.c
index 1dfa646..fdd7671 100644
--- a/source3/auth/auth_server.c
+++ b/source3/auth/auth_server.c
@@ -277,16 +277,23 @@ static NTSTATUS check_smbserver_security(const struct auth_context *auth_context
 					 const struct auth_usersupplied_info *user_info,
 					 struct auth_serversupplied_info **server_info)
 {
-	struct server_security_state *state = talloc_get_type_abort(
-		my_private_data, struct server_security_state);
-	struct cli_state *cli;
+	struct server_security_state *state = NULL;
+	struct cli_state *cli = NULL;
 	static bool tested_password_server = False;
 	static bool bad_password_server = False;
 	NTSTATUS nt_status = NT_STATUS_NOT_IMPLEMENTED;
 	bool locally_made_cli = False;
 
-	DEBUG(10, ("Check auth for: [%s]\n", user_info->mapped.account_name));
+	DEBUG(10, ("check_smbserver_security: Check auth for: [%s]\n",
+		user_info->mapped.account_name));
+
+	if (my_private_data == NULL) {
+		DEBUG(10,("check_smbserver_security: "
+			"password server is not connected\n"));
+		return NT_STATUS_LOGON_FAILURE;
+	}
 
+	state = talloc_get_type_abort(my_private_data, struct server_security_state);
 	cli = state->cli;
 
 	if (cli) {


-- 
Samba Shared Repository


More information about the samba-cvs mailing list