1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-27 03:21:53 +03:00
Commit Graph

756 Commits

Author SHA1 Message Date
Stefan Metzmacher
8cb6557d22 libcli/smb: add basic session->smb2.channel_sequence handling
metze
2012-07-26 10:02:07 +02:00
Stefan Metzmacher
fdd98675ac libcli/smb: add SMB2_HDR_CHANNEL_SEQUENCE
metze
2012-07-26 10:02:07 +02:00
Stefan Metzmacher
ba14bc52da libcli/smb: introduce a smb2cli_session
This maintains the shared state between multiple session
channels.

metze
2012-07-26 10:02:07 +02:00
Stefan Metzmacher
46e08eb75f s3:libcli/smb: add SMB2_SESSION_FLAG_BINDING
metze
2012-07-26 00:12:17 +02:00
Stefan Metzmacher
5c3a0cbae0 libcli/smb: setup tcon->smb2.should_encrypt in smb2cli_tcon_set_values()
metze

Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Wed Jul 25 16:44:22 CEST 2012 on sn-devel-104
2012-07-25 16:44:22 +02:00
Stefan Metzmacher
0aac3c09f1 libcli/smb: pass smbXcli_session to smb2cli_tcon_set_values()
metze
2012-07-25 14:48:50 +02:00
Stefan Metzmacher
56aa419d87 libcli/smb: there's no PID field in the SMB2/3 header anymore
It's a reserved field...

metze
2012-07-25 12:15:05 +02:00
Stefan Metzmacher
7de4ae7f9f libcli/smb: pass smbXcli_tcon to smb2cli_req_create/send()
metze
2012-07-25 12:15:04 +02:00
Stefan Metzmacher
a10fe7b252 libcli/smb: add smb2cli_tcon_capabilities()
metze
2012-07-25 12:15:03 +02:00
Stefan Metzmacher
20d43a1d30 libcli/smb: pass smbXcli_tcon to smb2cli_ioctl*()
metze
2012-07-24 22:20:06 +02:00
Stefan Metzmacher
51af8b9600 libcli/smb: pass smbXcli_tcon to smb2cli_query_directory*()
metze
2012-07-24 22:20:06 +02:00
Stefan Metzmacher
370e7140bb libcli/smb: pass smbXcli_tcon to smb2cli_query_info*()
metze
2012-07-24 22:20:06 +02:00
Stefan Metzmacher
6dc701c958 libcli/smb: pass smbXcli_tcon to smb2cli_set_info*()
metze
2012-07-24 22:20:06 +02:00
Stefan Metzmacher
6612c831a3 libcli/smb: pass smbXcli_tcon to smb2cli_flush*()
metze
2012-07-24 22:20:06 +02:00
Stefan Metzmacher
86a5ab731b libcli/smb: pass smbXcli_tcon to smb2cli_write*()
metze
2012-07-24 22:20:06 +02:00
Stefan Metzmacher
697b82a619 libcli/smb: pass smbXcli_tcon to smb2cli_read*()
metze
2012-07-24 22:20:06 +02:00
Stefan Metzmacher
74f9b52e65 libcli/smb: pass smbXcli_tcon to smb2cli_close*()
metze
2012-07-24 22:20:06 +02:00
Stefan Metzmacher
32b33999db libcli/smb: pass smbXcli_tcon to smb2cli_create*()
metze
2012-07-24 22:20:06 +02:00
Stefan Metzmacher
b9100a7ac4 libcli/smb: pass down smbXcli_tcon to smb1cli_req_create/send() and smb1cli_trans*
metze

Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Tue Jul 24 21:22:44 CEST 2012 on sn-devel-104
2012-07-24 21:22:44 +02:00
Luk Claes
552dda970c libcli/smb: add smbXcli_tcon structure
Signed-off-by: Luk Claes <luk@debian.org>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
2012-07-24 18:44:04 +02:00
Stefan Metzmacher
43b070d8dd libcli/smb: pass down smbXcli_session to smb1cli_req_create/send() and smb1cli_trans*
metze

Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Tue Jul 24 00:08:58 CEST 2012 on sn-devel-104
2012-07-24 00:08:58 +02:00
Luk Claes
6bff589e33 libcli/smb: introduce smb1.session for uid use
Signed-off-by: Luk Claes <luk@debian.org>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
2012-07-23 22:13:29 +02:00
Stefan Metzmacher
4b64ec546f libcli/smb: set should_encrypt = true if we got SMB2_SESSION_FLAG_ENCRYPT_DATA
metze

Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Mon Jul 23 20:14:07 CEST 2012 on sn-devel-104
2012-07-23 20:14:07 +02:00
Stefan Metzmacher
6b9321071c libcli/smb: encrypt SMB2 traffic if nedded/desired.
metze
2012-07-23 18:19:36 +02:00
Stefan Metzmacher
6e651dfdc0 libcli/smb: increment nbt_len, when we have the fully created the SMB2 PDU
metze
2012-07-23 18:19:36 +02:00
Stefan Metzmacher
f08adbb4d6 libcli/smb: maintain smb2.should_sign on smbXcli_req_state
metze
2012-07-23 18:19:36 +02:00
Stefan Metzmacher
92811c6f5f libcli/smb: make use of SMB2_HDR_BODY as header size
metze
2012-07-23 18:19:36 +02:00
Stefan Metzmacher
be8e33ec54 libcli/smb: parse the SMB2_TRANSFORM header and decrypt the SMB2 pdu
metze
2012-07-23 18:19:36 +02:00
Stefan Metzmacher
c2b0a48513 libcli/smb: create 4 iovecs per request in smb2cli_inbuf_parse_compound()
The first one might hold the SMB2_TRANSFORM Header later.

metze
2012-07-23 18:19:36 +02:00
Stefan Metzmacher
5863107cd3 libcli/smb: prepare [en|de]cryption_key for SMB3
metze
2012-07-23 18:19:36 +02:00
Stefan Metzmacher
d333edbe14 libcli/smb: copy the application_key in smb2cli_session_create_channel()
metze
2012-07-23 18:19:36 +02:00
Stefan Metzmacher
077eb578be libcli/smb: check the buffer length in smbXcli_negprot_dispatch_incoming()
metze
2012-07-23 18:19:36 +02:00
Stefan Metzmacher
1c144b07f6 libcli/smb: only pass the smb2 buffer to smb2cli_inbuf_parse_compound()
We should hide the transport as much as possible.

metze
2012-07-23 18:19:36 +02:00
Stefan Metzmacher
fd736f7f18 libcli/smb: add smb2_signing_[en|e]crypt_pdu()
metze
2012-07-23 18:19:36 +02:00
Stefan Metzmacher
7e0982421b libcli/smb: construct the signing_key before forming the message
metze
2012-07-23 18:19:36 +02:00
Stefan Metzmacher
4628e2878f libcli/smb: add SMB2_SESSION_FLAG_ENCRYPT_DATA
metze
2012-07-23 18:19:36 +02:00
Stefan Metzmacher
d7285672b4 libcli/smb: add SMB2_TRANSFORM macros
metze
2012-07-23 18:19:36 +02:00
Stefan Metzmacher
a7208de06a libcli/auth: add support for AES/HMAC-SHA256 to the netlogon schannel sign/seal
metze

Signed-off-by: Günther Deschner <gd@samba.org>
2012-07-17 10:58:39 +02:00
Stefan Metzmacher
99e5241d36 libcli/auth: add support for AES/HMAC-SHA256 schannel session key support
metze

Signed-off-by: Günther Deschner <gd@samba.org>
2012-07-17 10:58:39 +02:00
Stefan Metzmacher
342a2e6181 s4:librpc/rpc/dcerpc_schannel: just append NETLOGON_NEG_RODC_PASSTHROUGH as rodc
The RODC stuff doesn't depend on the schannel algorithm.

metze

Signed-off-by: Günther Deschner <gd@samba.org>
2012-07-17 10:58:38 +02:00
Stefan Metzmacher
cbf44e8d2f libcli/smb: add SMB2_CAP_DIRECTORY_LEASING to SMB2_CAP_ALL
metze

Signed-off-by: Michael Adam <obnox@samba.org>
2012-06-29 15:21:12 +02:00
Jeremy Allison
9b212d8df5 Fix warning: variable ‘XX’ set but not used. 2012-06-19 10:27:23 -07:00
Rusty Russell
13ac664a6d libcli: use tdb directly, not tdb_compat.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2012-06-19 05:38:07 +02:00
Stefan Metzmacher
ba44bd353d libcli/nbt: remove unused system/network.h from libnbt.h
This is not needed and breaks the build on AIX:

[ 988/3309] Compiling source4/smb_server/smb/reply.c
"../source4/smb_server/smb/reply.c", line 1093.42: 1506-022 (S) "lseek64" is not a member of "union smb_seek".
"../source4/smb_server/smb/reply.c", line 1093.42: 1506-022 (S) "lseek64" is not a member of "union smb_seek".
"../source4/smb_server/smb/reply.c", line 1093.42: 1506-022 (S) "lseek64" is not a member of "union smb_seek".
"../source4/smb_server/smb/reply.c", line 1093.42: 1506-022 (S) "lseek64" is not a member of "union smb_seek".
"../source4/smb_server/smb/reply.c", line 1109.13: 1506-022 (S) "lseek64" is not a member of "union smb_seek".
"../source4/smb_server/smb/reply.c", line 1110.13: 1506-022 (S) "lseek64" is not a member of "union smb_seek".
"../source4/smb_server/smb/reply.c", line 1111.13: 1506-022 (S) "lseek64" is not a member of "union smb_seek".
"../source4/smb_server/smb/reply.c", line 1113.38: 1506-022 (S) "lseek64" is not a member of "union smb_seek".
Waf: Leaving directory `/opt/home/build/build_farm/samba_4_0_test/bin'
Build failed:  -> task failed (err #1):
	{task: cc reply.c -> reply_1.o}

metze

Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Mon Jun 11 10:32:51 CEST 2012 on sn-devel-104
2012-06-11 10:32:50 +02:00
Michael Adam
52e1bba861 build: rename build targets nmblookup -> nmblookup4 and nmblookup3 -> nmblookup 2012-05-31 04:46:06 +02:00
Kai Blin
aa0190825d libcli/dns: Rename UDP-based calls to reflect their use
Autobuild-User: Kai Blin <kai@samba.org>
Autobuild-Date: Wed May 30 02:35:27 CEST 2012 on sn-devel-104
2012-05-30 02:35:24 +02:00
Stefan Metzmacher
f61c24166e libcli/smb: add some more FSCTL_* defines
metze
2012-05-29 10:16:24 +02:00
Stefan Metzmacher
244cf059f0 s3:smb2cli_ioctl: fix requests without output_buffer.length > 0 against windows
This fixes DCERPC over SMB2 against windows servers.

metze
2012-05-29 10:16:23 +02:00
Alexander Bokovoy
518484af8d dns_hosts_file: move to a separate subsystem
After discussion with Kai move dns_hosts_file to a separate subsystem
and merge it into libaddns private library for s3/s4 client use.

Also remove dependency in libcli/nbt, the code from libcli/dns subsystems
is not used there at all.

Autobuild-User: Alexander Bokovoy <ab@samba.org>
Autobuild-Date: Fri May 25 22:22:44 CEST 2012 on sn-devel-104
2012-05-25 22:22:44 +02:00
Alexander Bokovoy
744f9910c8 libcli/dns: make 'clidns' private library out of DNS code in WAF build
After consolidating DNS resolver code to lib/addns, there is one piece
that still needs to be moved into a common DNS resolver library: DNS_HOSTS_FILE
subsystem. Unfortunately, direct move would require lib/addns to depend on
libcli/util/{ntstatus.h,werror.h} (provided by errors subsystem).

In addition, moving libcli/dns/* code to lib/addns/ would make conflicting
the dns_tkey_record struct. The conflict comes from source4/dns_server/ and is due
to use of IDL to define the struct. lib/addns/ library also provides its own definition
so we either need to keep them in sync (rewrite code in lib/addns/ a bit) or
depend on generated IDL headers.

Thus, making a private library and subsystem clidns is an intermediate step
that allows to buy some time fore refactoring.
2012-05-23 17:51:50 +03:00