Ensure we check the return from make_user_info before dereferencing the value returne...
authorJeremy Allison <jra@samba.org>
Tue, 9 Nov 2010 21:24:03 +0000 (13:24 -0800)
committerJeremy Allison <jra@samba.org>
Wed, 10 Nov 2010 01:14:17 +0000 (01:14 +0000)
Jeremy.

source3/auth/auth_ntlmssp.c

index 3905914884c0b7b2c8dfe6ea957ab44871f4487c..4262d15a95ede3bed6448096f1d1298794df3419 100644 (file)
@@ -135,12 +135,12 @@ static NTSTATUS auth_ntlmssp_check_password(struct ntlmssp_state *ntlmssp_state,
                                       NULL, NULL, NULL,
                                       AUTH_PASSWORD_RESPONSE);
 
-       user_info->logon_parameters = MSV1_0_ALLOW_SERVER_TRUST_ACCOUNT | MSV1_0_ALLOW_WORKSTATION_TRUST_ACCOUNT;
-
        if (!NT_STATUS_IS_OK(nt_status)) {
                return nt_status;
        }
 
+       user_info->logon_parameters = MSV1_0_ALLOW_SERVER_TRUST_ACCOUNT | MSV1_0_ALLOW_WORKSTATION_TRUST_ACCOUNT;
+
        nt_status = auth_ntlmssp_state->auth_context->check_ntlm_password(auth_ntlmssp_state->auth_context, 
                                                                          user_info, &auth_ntlmssp_state->server_info);