summaryrefslogtreecommitdiff
path: root/source3/libsmb
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2007-04-19 20:50:49 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:19:30 -0500
commitdc90cd89a7fef3b0a744ef1873193cf2c9d75cad (patch)
tree33829db8298e704caba2679aa27d3ff99bf411a2 /source3/libsmb
parent20086f66cc32951da69aa357bc19c14d31a3913a (diff)
downloadsamba-dc90cd89a7fef3b0a744ef1873193cf2c9d75cad.tar.gz
samba-dc90cd89a7fef3b0a744ef1873193cf2c9d75cad.tar.bz2
samba-dc90cd89a7fef3b0a744ef1873193cf2c9d75cad.zip
r22389: Start preparing for multiple encryption contexts in the
server. Allow server to reflect back to calling client the encryption context that was sent. Jeremy. (This used to be commit b49e90335d1e589916b5ab4992e3c4a2d221ca7e)
Diffstat (limited to 'source3/libsmb')
-rw-r--r--source3/libsmb/smb_seal.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/source3/libsmb/smb_seal.c b/source3/libsmb/smb_seal.c
index 19092bd8c8..2e3e2f4ce3 100644
--- a/source3/libsmb/smb_seal.c
+++ b/source3/libsmb/smb_seal.c
@@ -93,10 +93,11 @@ NTSTATUS common_ntlm_decrypt_buffer(NTLMSSP_STATE *ntlmssp_state, char *buf)
}
memcpy(buf + 8, inbuf + 8 + NTLMSSP_SIG_SIZE, data_len);
- SAFE_FREE(inbuf);
/* Reset the length. */
- smb_setlen(buf, data_len + 4);
+ smb_setlen(buf, data_len + 4, inbuf);
+
+ SAFE_FREE(inbuf);
return NT_STATUS_OK;
}
@@ -203,7 +204,7 @@ static NTSTATUS common_gss_decrypt_buffer(struct smb_tran_enc_state_gss *gss_sta
}
memcpy(buf + 8, out_buf.value, out_buf.length);
- smb_setlen(buf, out_buf.length + 4);
+ smb_setlen(buf, out_buf.length + 4, out_buf.value);
gss_release_buffer(&minor, &out_buf);
return NT_STATUS_OK;