s3:auth Rename user_info->client_domain -> user_info->client.domain_name
authorAndrew Bartlett <abartlet@samba.org>
Tue, 1 Jun 2010 11:08:38 +0000 (21:08 +1000)
committerAndrew Bartlett <abartlet@samba.org>
Mon, 7 Jun 2010 13:34:28 +0000 (23:34 +1000)
This is closer to the structure I want for a common struct
auth_usersupplied_info.

Andrew Bartlett

source3/auth/auth.c
source3/auth/auth_domain.c
source3/auth/auth_netlogond.c
source3/auth/check_samsec.c
source3/auth/user_info.c
source3/include/auth.h

index 2801fc32dcf4ae79b815013bfd46f01a59e9798b..8d351ae390a4f09ce84d8736b08ee5b2f0549205 100644 (file)
@@ -214,7 +214,7 @@ static NTSTATUS check_ntlm_password(const struct auth_context *auth_context,
                return NT_STATUS_LOGON_FAILURE;
 
        DEBUG(3, ("check_ntlm_password:  Checking password for unmapped user [%s]\\[%s]@[%s] with the new password interface\n", 
-                 user_info->client_domain, user_info->client.account_name, user_info->workstation_name));
+                 user_info->client.domain_name, user_info->client.account_name, user_info->workstation_name));
 
        DEBUG(3, ("check_ntlm_password:  mapped user is: [%s]\\[%s]@[%s]\n", 
                  user_info->domain, user_info->mapped.account_name, user_info->workstation_name));
index 30d81a6c1224ebcebd5b0804653a2ef43cf4b1e0..aea82ed66c33a92826d8a08aebdbd95b17a9187c 100644 (file)
@@ -309,7 +309,7 @@ static NTSTATUS domain_client_validate(TALLOC_CTX *mem_ctx,
                                                      user_info->logon_parameters,/* flags such as 'allow workstation logon' */ 
                                                      dc_name,                    /* server name */
                                                      user_info->client.account_name,        /* user name logging on. */
-                                                     user_info->client_domain,   /* domain name */
+                                                     user_info->client.domain_name,   /* domain name */
                                                      user_info->workstation_name,/* workstation name */
                                                      chal,                       /* 8 byte challenge. */
                                                      user_info->lm_resp,         /* lanman 24 byte response */
@@ -325,7 +325,7 @@ static NTSTATUS domain_client_validate(TALLOC_CTX *mem_ctx,
                DEBUG(0,("domain_client_validate: unable to validate password "
                          "for user %s in domain %s to Domain controller %s. "
                          "Error was %s.\n", user_info->client.account_name,
-                         user_info->client_domain, dc_name, 
+                         user_info->client.domain_name, dc_name,
                          nt_errstr(nt_status)));
 
                /* map to something more useful */
index bb900ce4a2c9b2cf34bf32210f8df522a5da75bf..947fd3a429449b359f1e869195697dcb1d6163ec 100644 (file)
@@ -84,7 +84,7 @@ static NTSTATUS netlogond_validate(TALLOC_CTX *mem_ctx,
                                                        * workstation logon' */
                global_myname(),                       /* server name */
                user_info->client.account_name,                   /* user name logging on. */
-               user_info->client_domain,              /* domain name */
+               user_info->client.domain_name,              /* domain name */
                user_info->workstation_name,           /* workstation name */
                (uchar *)auth_context->challenge.data, /* 8 byte challenge. */
                user_info->lm_resp,                    /* lanman 24 byte response */
index 04ec10f1e8308630a79c9d618ca8d70818f68e66..5228811422a62a260c4ac3359be6544cc01c1e7d 100644 (file)
@@ -100,7 +100,7 @@ static NTSTATUS sam_password_ok(TALLOC_CTX *mem_ctx,
                                           &user_info->lm_resp, &user_info->nt_resp,
                                           username,
                                           user_info->client.account_name,
-                                          user_info->client_domain,
+                                          user_info->client.domain_name,
                                           lm_hash,
                                           nt_hash,
                                           user_sess_key, lm_sess_key);
index ca492d41353d43c8a3285a1199fca2784fa9e4c9..fdf80344cdbebcfe0cfa16bc0f0f5ac678b0ccfc 100644 (file)
@@ -70,8 +70,8 @@ NTSTATUS make_user_info(struct auth_usersupplied_info **user_info,
                return NT_STATUS_NO_MEMORY;
        }
 
-       (*user_info)->client_domain = SMB_STRDUP(client_domain);
-       if ((*user_info)->client_domain == NULL) {
+       (*user_info)->client.domain_name = SMB_STRDUP(client_domain);
+       if ((*user_info)->client.domain_name == NULL) {
                free_user_info(user_info);
                return NT_STATUS_NO_MEMORY;
        }
@@ -119,8 +119,8 @@ void free_user_info(struct auth_usersupplied_info **user_info)
                }
                SAFE_FREE((*user_info)->client.account_name);
                SAFE_FREE((*user_info)->mapped.account_name);
-               SAFE_FREE((*user_info)->client_domain);
                SAFE_FREE((*user_info)->domain);
+               SAFE_FREE((*user_info)->client.domain_name);
                SAFE_FREE((*user_info)->workstation_name);
                data_blob_free(&(*user_info)->lm_resp);
                data_blob_free(&(*user_info)->nt_resp);
index 71b944f804795e99b3c746a719c6400f4138c410..5a494537d1b5e86433d6dd50c69ecc54664b9a83 100644 (file)
@@ -29,10 +29,10 @@ struct auth_usersupplied_info {
        bool encrypted;
        struct {
                char *account_name;   /* username before/after mapping */
+               char *domain_name;    /* username before/after mapping */
        } client, mapped;
 
        bool was_mapped;              /* Did the username map actually match? */
-       char *client_domain;          /* domain name string */
        char *domain;                 /* domain name after mapping */
        char *internal_username;      /* username after mapping */
        const char *workstation_name; /* workstation name (netbios calling