summaryrefslogtreecommitdiffstats
path: root/source4/libcli
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2004-11-16 13:05:51 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:05:53 -0500
commit4af8f37d64dc24e6747589b90eae253d930b311a (patch)
treefcfbd30b1f01fdf738cb02f9322f54351d90b350 /source4/libcli
parent536601aeba8adb3fe3ac4af19088910c31959f93 (diff)
downloadsamba-4af8f37d64dc24e6747589b90eae253d930b311a.tar.gz
samba-4af8f37d64dc24e6747589b90eae253d930b311a.tar.xz
samba-4af8f37d64dc24e6747589b90eae253d930b311a.zip
r3786: send a mechListMIC to make the current samba3 client happy
metze (This used to be commit 2403186562698b8e13c20741a0cbed812e1b8e89)
Diffstat (limited to 'source4/libcli')
-rw-r--r--source4/libcli/auth/spnego.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/source4/libcli/auth/spnego.c b/source4/libcli/auth/spnego.c
index 316deaee0d8..b6436fe8c6f 100644
--- a/source4/libcli/auth/spnego.c
+++ b/source4/libcli/auth/spnego.c
@@ -465,11 +465,19 @@ static NTSTATUS gensec_spnego_update(struct gensec_security *gensec_security, TA
return nt_status;
} else {
const char **mechlist = gensec_security_oids(out_mem_ctx, OID_SPNEGO);
+ const char *mechListMIC;
+
+ mechListMIC = talloc_asprintf(out_mem_ctx,"%s$@%s",
+ lp_netbios_name(),
+ lp_realm());
+ if (!mechListMIC) {
+ return NT_STATUS_NO_MEMORY;
+ }
spnego_out.type = SPNEGO_NEG_TOKEN_INIT;
spnego_out.negTokenInit.mechTypes = mechlist;
spnego_out.negTokenInit.reqFlags = 0;
- spnego_out.negTokenInit.mechListMIC = null_data_blob;
+ spnego_out.negTokenInit.mechListMIC = data_blob(mechListMIC, strlen(mechListMIC));
spnego_out.negTokenInit.mechToken = unwrapped_out;
if (spnego_write_data(out_mem_ctx, out, &spnego_out) == -1) {