summaryrefslogtreecommitdiff
path: root/source3/rpc_client
diff options
context:
space:
mode:
authorSimo Sorce <idra@samba.org>2010-08-02 12:15:43 -0400
committerSimo Sorce <idra@samba.org>2010-08-17 06:33:13 -0400
commit86914b8fab764667ca5021f44b61c0222dbb2e09 (patch)
tree9b94e7ed6c25030dc6a7889bae90759441c2d534 /source3/rpc_client
parent26a3ba60e661bc2eaf05a2c03f8851d252515d3e (diff)
downloadsamba-86914b8fab764667ca5021f44b61c0222dbb2e09.tar.gz
samba-86914b8fab764667ca5021f44b61c0222dbb2e09.tar.bz2
samba-86914b8fab764667ca5021f44b61c0222dbb2e09.zip
s3-dcerpc: properly implement gse/spnego_get_session_key
Diffstat (limited to 'source3/rpc_client')
-rw-r--r--source3/rpc_client/cli_pipe.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/source3/rpc_client/cli_pipe.c b/source3/rpc_client/cli_pipe.c
index 1bee2f875b..2466418e39 100644
--- a/source3/rpc_client/cli_pipe.c
+++ b/source3/rpc_client/cli_pipe.c
@@ -3451,19 +3451,16 @@ NTSTATUS cli_get_session_key(TALLOC_CTX *mem_ctx,
make_dup = true;
break;
case DCERPC_AUTH_TYPE_SPNEGO:
- sk = spnego_get_session_key(a->a_u.spnego_state);
- if (sk.length == 0) {
- return NT_STATUS_NO_USER_SESSION_KEY;
- }
- make_dup = true;
+ sk = spnego_get_session_key(mem_ctx, a->a_u.spnego_state);
+ make_dup = false;
break;
case DCERPC_AUTH_TYPE_NTLMSSP:
sk = auth_ntlmssp_get_session_key(a->a_u.auth_ntlmssp_state);
make_dup = true;
break;
case DCERPC_AUTH_TYPE_KRB5:
- sk = gse_get_session_key(a->a_u.gssapi_state);
- make_dup = true;
+ sk = gse_get_session_key(mem_ctx, a->a_u.gssapi_state);
+ make_dup = false;
break;
case DCERPC_AUTH_TYPE_NONE:
sk = data_blob_const(a->user_session_key.data,