summaryrefslogtreecommitdiff
path: root/source3/rpc_client
diff options
context:
space:
mode:
authorRalph Boehme <slow@samba.org>2017-11-30 23:35:40 +0100
committerRalph Boehme <slow@samba.org>2018-01-13 08:24:08 +0100
commit489e942aa99d8f8a37ce2286923d8c97e97a4181 (patch)
tree23dcb2bc6c782e10709fa0921d5ca35a640c85f7 /source3/rpc_client
parent7082ebbbfb6db036655b63f84c39b6406b963a23 (diff)
downloadsamba-489e942aa99d8f8a37ce2286923d8c97e97a4181.tar.gz
s3/rpc_client: return validation from rpccli_netlogon functions
Return the validation info instead of the already mapped info3. Higher layers need info6 if available, this is the first step in passing the unmapped info up to callers. Signed-off-by: Ralph Boehme <slow@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
Diffstat (limited to 'source3/rpc_client')
-rw-r--r--source3/rpc_client/cli_netlogon.c27
-rw-r--r--source3/rpc_client/cli_netlogon.h8
2 files changed, 15 insertions, 20 deletions
diff --git a/source3/rpc_client/cli_netlogon.c b/source3/rpc_client/cli_netlogon.c
index 67c87354e69..800b995215c 100644
--- a/source3/rpc_client/cli_netlogon.c
+++ b/source3/rpc_client/cli_netlogon.c
@@ -461,7 +461,8 @@ NTSTATUS rpccli_netlogon_password_logon(
enum netr_LogonInfoClass logon_type,
uint8_t *authoritative,
uint32_t *flags,
- struct netr_SamInfo3 **info3)
+ uint16_t *_validation_level,
+ union netr_Validation **_validation)
{
TALLOC_CTX *frame = talloc_stackframe();
NTSTATUS status;
@@ -572,7 +573,7 @@ NTSTATUS rpccli_netlogon_password_logon(
binding_handle,
logon_type,
logon,
- frame,
+ mem_ctx,
&validation_level,
&validation,
authoritative,
@@ -582,14 +583,9 @@ NTSTATUS rpccli_netlogon_password_logon(
return status;
}
- status = map_validation_to_info3(mem_ctx,
- validation_level, validation,
- info3);
TALLOC_FREE(frame);
- if (!NT_STATUS_IS_OK(status)) {
- return status;
- }
-
+ *_validation_level = validation_level;
+ *_validation = validation;
return NT_STATUS_OK;
}
@@ -614,7 +610,8 @@ NTSTATUS rpccli_netlogon_network_logon(
DATA_BLOB nt_response,
uint8_t *authoritative,
uint32_t *flags,
- struct netr_SamInfo3 **info3)
+ uint16_t *_validation_level,
+ union netr_Validation **_validation)
{
NTSTATUS status;
const char *workstation_name_slash;
@@ -625,7 +622,7 @@ NTSTATUS rpccli_netlogon_network_logon(
struct netr_ChallengeResponse lm;
struct netr_ChallengeResponse nt;
- *info3 = NULL;
+ *_validation = NULL;
ZERO_STRUCT(lm);
ZERO_STRUCT(nt);
@@ -686,12 +683,8 @@ NTSTATUS rpccli_netlogon_network_logon(
return status;
}
- status = map_validation_to_info3(mem_ctx,
- validation_level, validation,
- info3);
- if (!NT_STATUS_IS_OK(status)) {
- return status;
- }
+ *_validation_level = validation_level;
+ *_validation = validation;
return NT_STATUS_OK;
}
diff --git a/source3/rpc_client/cli_netlogon.h b/source3/rpc_client/cli_netlogon.h
index db8eb502029..d31bdee461f 100644
--- a/source3/rpc_client/cli_netlogon.h
+++ b/source3/rpc_client/cli_netlogon.h
@@ -71,9 +71,10 @@ NTSTATUS rpccli_netlogon_password_logon(
enum netr_LogonInfoClass logon_type,
uint8_t *authoritative,
uint32_t *flags,
- struct netr_SamInfo3 **info3);
+ uint16_t *_validation_level,
+ union netr_Validation **_validation);
NTSTATUS rpccli_netlogon_network_logon(
- struct netlogon_creds_cli_context *creds,
+ struct netlogon_creds_cli_context *creds_ctx,
struct dcerpc_binding_handle *binding_handle,
TALLOC_CTX *mem_ctx,
uint32_t logon_parameters,
@@ -85,6 +86,7 @@ NTSTATUS rpccli_netlogon_network_logon(
DATA_BLOB nt_response,
uint8_t *authoritative,
uint32_t *flags,
- struct netr_SamInfo3 **info3);
+ uint16_t *_validation_level,
+ union netr_Validation **_validation);
#endif /* _RPC_CLIENT_CLI_NETLOGON_H_ */