summaryrefslogtreecommitdiff
path: root/source3/smbd
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2009-02-19 23:41:48 +0100
committerVolker Lendecke <vl@samba.org>2009-02-21 14:04:14 +0100
commit4aed9abbf84deb47e7a3aec025268a3c1e6b29bb (patch)
treed11cd47acd6bcf3617fd2075c02ebed8ef653146 /source3/smbd
parente9467ff26ed429dbb2d4249da5bedf545664253b (diff)
downloadsamba-4aed9abbf84deb47e7a3aec025268a3c1e6b29bb.tar.gz
samba-4aed9abbf84deb47e7a3aec025268a3c1e6b29bb.tar.bz2
samba-4aed9abbf84deb47e7a3aec025268a3c1e6b29bb.zip
Remove the static "chal" from ntlmssp.c:get_challenge()
Diffstat (limited to 'source3/smbd')
-rw-r--r--source3/smbd/negprot.c5
-rw-r--r--source3/smbd/sesssetup.c7
2 files changed, 6 insertions, 6 deletions
diff --git a/source3/smbd/negprot.c b/source3/smbd/negprot.c
index 57608a9b40..a921954c49 100644
--- a/source3/smbd/negprot.c
+++ b/source3/smbd/negprot.c
@@ -27,7 +27,6 @@ extern enum protocol_types Protocol;
static void get_challenge(uint8 buff[8])
{
NTSTATUS nt_status;
- const uint8 *cryptkey;
/* We might be called more than once, multiple negprots are
* permitted */
@@ -42,8 +41,8 @@ static void get_challenge(uint8 buff[8])
smb_panic("cannot make_negprot_global_auth_context!");
}
DEBUG(10, ("get challenge: getting challenge\n"));
- cryptkey = negprot_global_auth_context->get_ntlm_challenge(negprot_global_auth_context);
- memcpy(buff, cryptkey, 8);
+ negprot_global_auth_context->get_ntlm_challenge(
+ negprot_global_auth_context, buff);
}
/****************************************************************************
diff --git a/source3/smbd/sesssetup.c b/source3/smbd/sesssetup.c
index 7a03ef7f3c..8a09ed39a9 100644
--- a/source3/smbd/sesssetup.c
+++ b/source3/smbd/sesssetup.c
@@ -1691,14 +1691,15 @@ void reply_sesssetup_and_X(struct smb_request *req)
}
} else {
struct auth_context *plaintext_auth_context = NULL;
- const uint8 *chal;
nt_status = make_auth_context_subsystem(
&plaintext_auth_context);
if (NT_STATUS_IS_OK(nt_status)) {
- chal = plaintext_auth_context->get_ntlm_challenge(
- plaintext_auth_context);
+ uint8_t chal[8];
+
+ plaintext_auth_context->get_ntlm_challenge(
+ plaintext_auth_context, chal);
if (!make_user_info_for_reply(&user_info,
user, domain, chal,