summaryrefslogtreecommitdiff
path: root/libcli
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2017-09-19 16:45:27 -0700
committerVolker Lendecke <vl@samba.org>2017-09-25 09:43:13 +0200
commit32e823e08df305919ba0a001a389eb88b7d1be68 (patch)
tree0b5c382d8325e94c3189e4148c9cc3cd7c3e9a2f /libcli
parentd7e31d9f4d9ce7395e458ac341dd83ac06255a20 (diff)
downloadsamba-32e823e08df305919ba0a001a389eb88b7d1be68.tar.gz
netlogon_creds_cli: Pass "capabilities" up from creds_cli_check
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Diffstat (limited to 'libcli')
-rw-r--r--libcli/auth/netlogon_creds_cli.c14
-rw-r--r--libcli/auth/netlogon_creds_cli.h6
2 files changed, 15 insertions, 5 deletions
diff --git a/libcli/auth/netlogon_creds_cli.c b/libcli/auth/netlogon_creds_cli.c
index 31bd98ddc94..cb3d6a9eeb4 100644
--- a/libcli/auth/netlogon_creds_cli.c
+++ b/libcli/auth/netlogon_creds_cli.c
@@ -1728,8 +1728,11 @@ static void netlogon_creds_cli_check_caps(struct tevent_req *subreq)
tevent_req_done(req);
}
-NTSTATUS netlogon_creds_cli_check_recv(struct tevent_req *req)
+NTSTATUS netlogon_creds_cli_check_recv(struct tevent_req *req,
+ union netr_Capabilities *capabilities)
{
+ struct netlogon_creds_cli_check_state *state = tevent_req_data(
+ req, struct netlogon_creds_cli_check_state);
NTSTATUS status;
if (tevent_req_is_nterror(req, &status)) {
@@ -1738,12 +1741,17 @@ NTSTATUS netlogon_creds_cli_check_recv(struct tevent_req *req)
return status;
}
+ if (capabilities != NULL) {
+ *capabilities = state->caps;
+ }
+
tevent_req_received(req);
return NT_STATUS_OK;
}
NTSTATUS netlogon_creds_cli_check(struct netlogon_creds_cli_context *context,
- struct dcerpc_binding_handle *b)
+ struct dcerpc_binding_handle *b,
+ union netr_Capabilities *capabilities)
{
TALLOC_CTX *frame = talloc_stackframe();
struct tevent_context *ev;
@@ -1761,7 +1769,7 @@ NTSTATUS netlogon_creds_cli_check(struct netlogon_creds_cli_context *context,
if (!tevent_req_poll_ntstatus(req, ev, &status)) {
goto fail;
}
- status = netlogon_creds_cli_check_recv(req);
+ status = netlogon_creds_cli_check_recv(req, capabilities);
fail:
TALLOC_FREE(frame);
return status;
diff --git a/libcli/auth/netlogon_creds_cli.h b/libcli/auth/netlogon_creds_cli.h
index 62d11ac283e..56a2dd9bc77 100644
--- a/libcli/auth/netlogon_creds_cli.h
+++ b/libcli/auth/netlogon_creds_cli.h
@@ -116,9 +116,11 @@ struct tevent_req *netlogon_creds_cli_check_send(TALLOC_CTX *mem_ctx,
struct tevent_context *ev,
struct netlogon_creds_cli_context *context,
struct dcerpc_binding_handle *b);
-NTSTATUS netlogon_creds_cli_check_recv(struct tevent_req *req);
+NTSTATUS netlogon_creds_cli_check_recv(struct tevent_req *req,
+ union netr_Capabilities *capabilities);
NTSTATUS netlogon_creds_cli_check(struct netlogon_creds_cli_context *context,
- struct dcerpc_binding_handle *b);
+ struct dcerpc_binding_handle *b,
+ union netr_Capabilities *capabilities);
struct tevent_req *netlogon_creds_cli_ServerPasswordSet_send(TALLOC_CTX *mem_ctx,
struct tevent_context *ev,