diff options
author | Andrew Bartlett <abartlet@samba.org> | 2012-01-14 11:40:18 +1100 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2012-01-18 16:23:25 +0100 |
commit | 45ec777e0ea78a1194980624ac9127a42b4b29fe (patch) | |
tree | 4ba6b2a487221d75b16275970786f43c727e0e24 | |
parent | 545c1ad1b939015b618a1a979c435dbba70845bd (diff) | |
download | samba-45ec777e0ea78a1194980624ac9127a42b4b29fe.tar.gz samba-45ec777e0ea78a1194980624ac9127a42b4b29fe.tar.xz samba-45ec777e0ea78a1194980624ac9127a42b4b29fe.zip |
s3-gse: Make gensec_gse cope with non-DCE GSSAPI
The validation of the mutual authentication reply produces no further
data to send to the server.
Andrew Bartlett
Signed-off-by: Stefan Metzmacher <metze@samba.org>
-rw-r--r-- | source3/librpc/crypto/gse.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/source3/librpc/crypto/gse.c b/source3/librpc/crypto/gse.c index c7ce38e14f..010d525229 100644 --- a/source3/librpc/crypto/gse.c +++ b/source3/librpc/crypto/gse.c @@ -350,12 +350,15 @@ static NTSTATUS gse_get_client_auth_token(TALLOC_CTX *mem_ctx, goto done; } - blob = data_blob_talloc(mem_ctx, out_data.value, out_data.length); - if (!blob.data) { - status = NT_STATUS_NO_MEMORY; - } + /* we may be told to return nothing */ + if (out_data.length) { + blob = data_blob_talloc(mem_ctx, out_data.value, out_data.length); + if (!blob.data) { + status = NT_STATUS_NO_MEMORY; + } - gss_maj = gss_release_buffer(&gss_min, &out_data); + gss_maj = gss_release_buffer(&gss_min, &out_data); + } done: *token_out = blob; |