diff options
author | Jeremy Allison <jra@samba.org> | 2006-01-13 23:23:09 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2006-01-13 23:23:09 +0000 |
commit | 60ecfbb046b77c1be9656b6e69affc06668e134c (patch) | |
tree | bb8f222703a4e0ae43efe42c166130fd29ee93aa | |
parent | 57d94d3d83b0f7e8775fe630346c66cd9a4abb75 (diff) | |
download | samba-60ecfbb046b77c1be9656b6e69affc06668e134c.tar.gz samba-60ecfbb046b77c1be9656b6e69affc06668e134c.tar.xz samba-60ecfbb046b77c1be9656b6e69affc06668e134c.zip |
r12920: Fix for #3401 from Andrew Bartlett. Original fix from
Yau Lam Yiu <yiuext@cs.ust.hk>.
Jeremy.
-rw-r--r-- | source/libsmb/ntlmssp.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/source/libsmb/ntlmssp.c b/source/libsmb/ntlmssp.c index 0becc7fdee3..6dd623047a0 100644 --- a/source/libsmb/ntlmssp.c +++ b/source/libsmb/ntlmssp.c @@ -384,6 +384,11 @@ static void ntlmssp_handle_neg_flags(struct ntlmssp_state *ntlmssp_state, void ntlmssp_weaken_keys(NTLMSSP_STATE *ntlmssp_state) { + /* Nothing to weaken. We certainly don't want to 'extend' the length... */ + if (!ntlmssp_state->session_key.length < 8) { + return; + } + /* Key weakening not performed on the master key for NTLM2 and does not occour for NTLM1. Therefore we only need to do this for the LM_KEY. |