summaryrefslogtreecommitdiff
path: root/source4/libcli/smb_composite
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2012-08-02 08:51:13 +0200
committerStefan Metzmacher <metze@samba.org>2012-08-04 09:10:22 +0200
commit67767de4e9e4a3a2cac1f28b590398bd587467da (patch)
tree5b62594a54335936715f9114f2271023d5e7054b /source4/libcli/smb_composite
parentc32120b4e93a565c12534b7614becdf573672586 (diff)
downloadsamba-67767de4e9e4a3a2cac1f28b590398bd587467da.tar.gz
samba-67767de4e9e4a3a2cac1f28b590398bd587467da.tar.bz2
samba-67767de4e9e4a3a2cac1f28b590398bd587467da.zip
s4:libcli: add support for SMB_EXTENDED_SIGNATURES during SMBtconX
metze
Diffstat (limited to 'source4/libcli/smb_composite')
-rw-r--r--source4/libcli/smb_composite/connect.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/source4/libcli/smb_composite/connect.c b/source4/libcli/smb_composite/connect.c
index 3453ec94cf..14b53e5d40 100644
--- a/source4/libcli/smb_composite/connect.c
+++ b/source4/libcli/smb_composite/connect.c
@@ -31,6 +31,7 @@
#include "librpc/gen_ndr/ndr_nbt.h"
#include "param/param.h"
#include "lib/util/util_net.h"
+#include "libcli/smb/smbXcli_base.h"
/* the stages of this call */
enum connect_stage {CONNECT_SOCKET,
@@ -72,6 +73,10 @@ static NTSTATUS connect_tcon(struct composite_context *c,
status = smb_raw_tcon_recv(state->req, c, state->io_tcon);
NT_STATUS_NOT_OK_RETURN(status);
+ if (state->io_tcon->tconx.out.options & SMB_EXTENDED_SIGNATURES) {
+ smb1cli_session_protect_session_key(io->out.tree->session->smbXcli);
+ }
+
io->out.tree->tid = state->io_tcon->tconx.out.tid;
if (state->io_tcon->tconx.out.dev_type) {
io->out.tree->device = talloc_strdup(io->out.tree,
@@ -196,6 +201,7 @@ static NTSTATUS connect_session_setup(struct composite_context *c,
/* connect to a share using a tree connect */
state->io_tcon->generic.level = RAW_TCON_TCONX;
state->io_tcon->tconx.in.flags = TCONX_FLAG_EXTENDED_RESPONSE;
+ state->io_tcon->tconx.in.flags |= TCONX_FLAG_EXTENDED_SIGNATURES;
state->io_tcon->tconx.in.password = data_blob(NULL, 0);
state->io_tcon->tconx.in.path = talloc_asprintf(state->io_tcon,