From deabae191b34bdd350c7fe6c0c9ad05defa8d08c Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Tue, 1 Jun 2010 21:08:38 +1000 Subject: [PATCH] s3:auth Rename user_info->client_domain -> user_info->client.domain_name This is closer to the structure I want for a common struct auth_usersupplied_info. Andrew Bartlett --- source3/auth/auth.c | 2 +- source3/auth/auth_domain.c | 4 ++-- source3/auth/auth_netlogond.c | 2 +- source3/auth/check_samsec.c | 2 +- source3/auth/user_info.c | 6 +++--- source3/include/auth.h | 2 +- 6 files changed, 9 insertions(+), 9 deletions(-) diff --git a/source3/auth/auth.c b/source3/auth/auth.c index 2801fc32dcf..8d351ae390a 100644 --- a/source3/auth/auth.c +++ b/source3/auth/auth.c @@ -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)); diff --git a/source3/auth/auth_domain.c b/source3/auth/auth_domain.c index 30d81a6c122..aea82ed66c3 100644 --- a/source3/auth/auth_domain.c +++ b/source3/auth/auth_domain.c @@ -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 */ diff --git a/source3/auth/auth_netlogond.c b/source3/auth/auth_netlogond.c index bb900ce4a2c..947fd3a4294 100644 --- a/source3/auth/auth_netlogond.c +++ b/source3/auth/auth_netlogond.c @@ -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 */ diff --git a/source3/auth/check_samsec.c b/source3/auth/check_samsec.c index 04ec10f1e83..5228811422a 100644 --- a/source3/auth/check_samsec.c +++ b/source3/auth/check_samsec.c @@ -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); diff --git a/source3/auth/user_info.c b/source3/auth/user_info.c index ca492d41353..fdf80344cdb 100644 --- a/source3/auth/user_info.c +++ b/source3/auth/user_info.c @@ -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); diff --git a/source3/include/auth.h b/source3/include/auth.h index 71b944f8047..5a494537d1b 100644 --- a/source3/include/auth.h +++ b/source3/include/auth.h @@ -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 -- 2.34.1