1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-23 17:34:34 +03:00
Commit Graph

48 Commits

Author SHA1 Message Date
Stefan Metzmacher
ee2574ae56 s4:libcli/smb2: fix smb2_getinfo_send() marshalling
BUG: https://bugzilla.samba.org/show_bug.cgi?id=13863

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2019-03-28 23:09:36 +00:00
Stefan Metzmacher
aef96af916 s4:libcli/smb2: move SMB2_GETINFO_* flags into smb2_constants.h
metze
2009-08-07 14:56:23 +02:00
Stefan Metzmacher
acbb9da530 s4:libcli/smb2: remove unused and redundant SMB2 security flags
metze
2009-08-07 14:56:23 +02:00
Stefan Metzmacher
183c379fe5 s4:lib/tevent: rename structs
list=""
list="$list event_context:tevent_context"
list="$list fd_event:tevent_fd"
list="$list timed_event:tevent_timer"

for s in $list; do
	o=`echo $s | cut -d ':' -f1`
	n=`echo $s | cut -d ':' -f2`
	r=`git grep "struct $o" |cut -d ':' -f1 |sort -u`
	files=`echo "$r" | grep -v source3 | grep -v nsswitch | grep -v packaging4`
	for f in $files; do
		cat $f | sed -e "s/struct $o/struct $n/g" > $f.tmp
		mv $f.tmp $f
	done
done

metze
2008-12-29 20:46:40 +01:00
Jelmer Vernooij
b034c519f5 Add gensec_settings structure. This wraps loadparm_context for now, but
should in the future only contain some settings required for gensec.
2008-11-02 02:05:48 +01:00
Andrew Tridgell
b640f475be updated SMB2 code for getinfo according to WSPP docs
- Updated getinfo structures and field names
- also updated the protocol revision number handling to reflect
  new docs
(This used to be commit 3aaa2e86d9)
2008-02-14 17:11:36 +11:00
Andrew Tridgell
e94d710b0b updated SMB2 tcon as per WSPP docs
(This used to be commit 5913e3e549)
2008-02-13 10:13:28 +11:00
Andrew Tridgell
8fdb9504dc converted the out side of SMB2 negprot handling
This follows the SMB2 PFIF docs. Current versions of Vista can now connect to Samba4 as a SMB2 server
and do basic operations
(This used to be commit 9dc284770d)
2008-02-12 16:20:13 +11:00
Andrew Tridgell
ccc27e681c fixed up the .in side of SMB2 negprot
fixed the input side of the SMB2 negprot structure and parsers according to the documentation
(This used to be commit 55af8acc7b)
2008-02-12 12:54:44 +11:00
Jelmer Vernooij
5f4842cf65 r26376: Add context for libcli_resolve.
(This used to be commit 459e1466a4)
2007-12-21 05:49:12 +01:00
Andrew Tridgell
0479a2f1cb r23792: convert Samba4 to GPLv3
There are still a few tidyups of old FSF addresses to come (in both s3
and s4). More commits soon.
(This used to be commit fcf38a38ac)
2007-10-10 14:59:12 -05:00
Stefan Metzmacher
a8958391e8 r16980: - make struct smb_notify a union and add levels RAW_NOTIFY_NTTRANS,RAW_NOTIFY_SMB2
- parse SMB2 Notify reponse

metze
(This used to be commit de50e0ccdd)
2007-10-10 14:10:06 -05:00
Stefan Metzmacher
86c3e628e0 r16975: implement SMB2 Notify call in the client lib
metze
(This used to be commit a455dc7a83)
2007-10-10 14:10:04 -05:00
Stefan Metzmacher
a3797ff66a r16875: implement SMB2 Find in the frontend
metze
(This used to be commit 58bed7322c)
2007-10-10 14:09:56 -05:00
Stefan Metzmacher
d3b3436ce1 r16406: use the generic smb_handle in smb2_getinfo/smb2_setinfo
metze
(This used to be commit dcc02df829)
2007-10-10 14:09:13 -05:00
Stefan Metzmacher
e306c5bf12 r15741: move smb2 request structures into the main smb request structs
as new levels

metze
(This used to be commit 9180635317)
2007-10-10 14:08:11 -05:00
Jelmer Vernooij
35349a58df r14542: Remove librpc, libndr and libnbt from includes.h
(This used to be commit 51b4270513)
2007-10-10 13:58:42 -05:00
Jelmer Vernooij
5b0051e032 r14511: Install more headers
(This used to be commit e1f896948f)
2007-10-10 13:57:35 -05:00
Jelmer Vernooij
63d718e243 r12696: Reduce the size of include/structs.h
(This used to be commit 6391761601)
2007-10-10 13:49:40 -05:00
Andrew Tridgell
6615907b94 r11980: ronnie worked out that opcode 0xb in SMB2 is in fact ioctl, and that
it only appeared to be like a SMBtrans request as it was being called
with function 0x11c017 which is "named pipe read write"

I wonder if this means we could do DCE/RPC over SMB using ntioctl
calls as well?
(This used to be commit f2b8857797)
2007-10-10 13:46:53 -05:00
Andrew Tridgell
1e3583475f r11905: added SMB2_FLUSH as opcode 7. Thanks to metze and volker for help
brainstorming this one.
(This used to be commit a969ad592a)
2007-10-10 13:46:47 -05:00
Stefan Metzmacher
d90914dda8 r11895: - reorder some code to make it easier to follow, how the fields appear on the wire
- add some comments to the header file, to represent the wire format

metze
(This used to be commit fa98f09f8b)
2007-10-10 13:46:43 -05:00
Andrew Tridgell
2f74901802 r11891: - added pipe_flags field in smb2_trans
- while running dcerpc over SMB2, the server will occasionally send us
  a oh-so-useful STATUS_PENDING result meaning "I don't have a result
  for you yet, but I'm working on it". These can be discarded :-)
(This used to be commit 24588a9c49)
2007-10-10 13:46:42 -05:00
Andrew Tridgell
310fa87509 r11888: - added SMB2 trans support
- added session key to SMB2

- renamed 'unknown2' in create to 'impersonation'
(This used to be commit aef915f312)
2007-10-10 13:46:41 -05:00
Andrew Tridgell
f7c03b2abe r11849: added mapping between SMB2 and SMB find/search levels
(This used to be commit 77e0cb999c)
2007-10-10 13:46:38 -05:00
Andrew Tridgell
fc04e3e795 r11801: - added basic SMB2 find support
- added SMB2-SCANFIND test

- cleaned up continue flags in EAs and find requests
(This used to be commit 8792bc07d9)
2007-10-10 13:46:29 -05:00
Andrew Tridgell
7d6f36682e r11800: - filled in unknown fields in SMB2 all_info level
- allow setting of the ALL_EAS flags bits in SMB2 getinfo
(This used to be commit 8c7c54a46d)
2007-10-10 13:46:29 -05:00
Andrew Tridgell
d5f37ecf94 r11780: it turns out that the MxAc tag isn't a security descriptor, its a
request that the server return its own MxAc blob which contains the
maximum allowed access_mask for the returned file handle
(This used to be commit c0288aa8cd)
2007-10-10 13:46:26 -05:00
Andrew Tridgell
c8c7fb2492 r11775: added support for creating files on SMB2 with initial EA lists and an ACL
(This used to be commit ff19709298)
2007-10-10 13:46:25 -05:00
Andrew Tridgell
2ff21db535 r11771: - split out the setinfo blob construction in the libcli/raw code
- added a smb2_setinfo call

- added smb2_setinfo_file*() calls
(This used to be commit da0b6fb936)
2007-10-10 13:46:24 -05:00
Andrew Tridgell
eedb92ce72 r11758: unified the parse code for the SMB and SMB2 qfsinfo and qfileinfo calls
(This used to be commit ba897e537b)
2007-10-10 13:46:23 -05:00
Andrew Tridgell
7a43b32c3b r11755: added names for all of the SMB2 qfs info levels (they all map exactly
to equivalent SMB qfs levels)
(This used to be commit 4ce48d02aa)
2007-10-10 13:46:23 -05:00
Stefan Metzmacher
e9eb560685 r11741: - the buffer code (first 2 bytes in the SMB2 body) seem to be the length
of the fixed body part, and +1 if there's a dynamic part
- there're 3 types of dynamic blobs
  with uint16_t offset/uint16_t size
  with uint16_t offset/uint32_t size
  with uint32_t offset/uint32_t size /* aligned to 8 bytes */
- strings are transmitted in UTF-16 with no termination and
  packet into a uint16/uint16 blob

metze
(This used to be commit 79103c51e5)
2007-10-10 13:46:20 -05:00
Andrew Tridgell
ab0d0f0623 r11735: fixed the ALL_EAS smb2 level parsing
(This used to be commit dd24c0e80c)
2007-10-10 13:46:19 -05:00
Andrew Tridgell
b51703baf1 r11730: added parsing and tests for a bunch more SMB2 getinfo levels
(This used to be commit ca65bf0235)
2007-10-10 13:46:18 -05:00
Andrew Tridgell
c6395a30b0 r11715: added SMB2 read and write requests
(This used to be commit d3556cbfa3)
2007-10-10 13:46:17 -05:00
Andrew Tridgell
72565088bc r11700: added structure definitions for many of the getinfo structures
(This used to be commit 2919d42286)
2007-10-10 13:46:15 -05:00
Andrew Tridgell
36e4374b1d r11698: added some more level names
(This used to be commit 845bbef803)
2007-10-10 13:46:15 -05:00
Andrew Tridgell
67a85b3f1b r11697: - added a generic SMB2 getinfo call
- added a SMB2-SCANGETINFO test for scanning for available info levels

- added names for the info levels I recognise to smb2.h
(This used to be commit fe5986067e)
2007-10-10 13:46:15 -05:00
Andrew Tridgell
91e1893741 r11691: added reply buffer code checks and oplock flags for create request/reply
(This used to be commit 26ed781375)
2007-10-10 13:46:13 -05:00
Andrew Tridgell
222e197b84 r11687: filled in 3 more fields in the close reply
(This used to be commit 3a0abb3ff0)
2007-10-10 13:46:13 -05:00
Andrew Tridgell
b034156bd5 r11682: filled in access_mask in tcon reply
(This used to be commit 173a213f91)
2007-10-10 13:46:13 -05:00
Andrew Tridgell
461ccc557b r11681: filled in a few more smb2_create() fields
(This used to be commit a95413568f)
2007-10-10 13:46:13 -05:00
Andrew Tridgell
1b2e8caad3 r11680: added smb2_close(). This also demonstrates that file handles are 16
bytes, not 20 bytes (metze, you were right!)
(This used to be commit d3bcc6628c)
2007-10-10 13:46:12 -05:00
Andrew Tridgell
2e753f8518 r11679: opening/creating files in SMB2 now works. Lots of unknown parameters
in the call tho.
(This used to be commit 548fbd86b3)
2007-10-10 13:46:12 -05:00
Andrew Tridgell
3e54c36fa4 r11674: SMB2 tree connect now works. We do 2 session setups and 2 tree
connects, giving the following output:

Running SMB2-CONNECT
Negprot reply:
current_time  = Fri Nov 11 20:10:42 2005 EST
boot_time     = Sat Nov 12 10:34:33 2005 EST
Session setup gave UID 0x40000000071
Session setup gave UID 0x140000000075
Tree connect gave tid = 0x7500000001
Tree connect gave tid = 0x7500000005
SMB2-CONNECT took 0.049024 secs
(This used to be commit a24a4c3110)
2007-10-10 13:46:11 -05:00
Andrew Tridgell
7a78d2d6b0 r11668: yay! we get a successful session setup with SMB2, and get back a 64bit uid
(This used to be commit 72b34a7c1b)
2007-10-10 13:46:10 -05:00
Andrew Tridgell
555b45e12c r11665: started to put some meat on the structure used for the SMB2 library
the call definitions will be in smb2_calls.h, which will play a
similar role that smb_interfaces.h plays for the old SMB protocol
(This used to be commit 4ef3902a8a)
2007-10-10 13:46:09 -05:00