Jeremy Allison
d7fb237810
Remove an unncessary FTRUNCATE call in the open path. We can rely on O_TRUC.
...
Suggested by Volker.
2012-09-05 20:43:31 +02:00
Stefan Metzmacher
92bd7b0db8
s3:smb2_create: check for SMB2_CREATE_TAG_DHNC first
...
metze
Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Wed Sep 5 12:27:25 CEST 2012 on sn-devel-104
2012-09-05 12:27:25 +02:00
Volker Lendecke
084978f3d0
s3: Slightly simplify fd_open_atomic
...
Replace an if-statement by a direct assignment
Signed-off-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Wed Sep 5 01:56:46 CEST 2012 on sn-devel-104
2012-09-05 01:56:46 +02:00
Volker Lendecke
d95d32606b
s3: Put a comment into the right place
...
Signed-off-by: Jeremy Allison <jra@samba.org>
2012-09-04 15:15:00 -07:00
Volker Lendecke
63279e374a
s3: Factor out disposition_to_open_flags
...
Signed-off-by: Jeremy Allison <jra@samba.org>
2012-09-04 15:15:00 -07:00
Volker Lendecke
f67a6c463c
s3: Factor out calculation of clear_ads
...
Signed-off-by: Jeremy Allison <jra@samba.org>
2012-09-04 15:15:00 -07:00
Volker Lendecke
0d869327ed
s3: Slightly simplify open_file_ntcreate
...
We have not set flags2 before, so do direct assignment and not |=
Signed-off-by: Jeremy Allison <jra@samba.org>
2012-09-04 15:15:00 -07:00
Volker Lendecke
93e10db3dd
s3: Make "open_match_attributes" static
...
Signed-off-by: Jeremy Allison <jra@samba.org>
2012-09-04 15:15:00 -07:00
Michael Adam
b1966f3118
s3:smbd: in sys_disk_free(), improve a debug message
2012-09-04 20:39:20 +02:00
Michael Adam
cc99189de1
s3:smbd: in sys_disk_free(), improve a debug message
2012-09-04 20:39:20 +02:00
Michael Adam
04ac781626
s3:smbd: in sys_disk_free(), fix line length and indentation of debug statement
2012-09-04 20:39:20 +02:00
Michael Adam
a56d2dea06
s3:smbd: in sys_disk_free(), fix a debug message
2012-09-04 20:39:20 +02:00
Björn Jacke
9dd0e1608e
s3: remove some duplicate quota code
2012-09-02 21:44:54 +02:00
Volker Lendecke
d5f845c0d3
s3: Make an if statement a bit easier to read
...
Fix indentation a bit
Signed-off-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Sat Sep 1 07:07:12 CEST 2012 on sn-devel-104
2012-09-01 07:07:12 +02:00
Jeremy Allison
46455642a7
Change the S3 fileserver over to se_file_access_check().
...
Don't set the priv_open_requested yet until the open-for-backup
request is correctly passed in.
2012-08-31 20:29:13 -07:00
Jeremy Allison
3d34406c7b
Windows does canonicalization of inheritance bits. Do the same.
...
We need to filter out the
SEC_DESC_DACL_AUTO_INHERITED|SEC_DESC_DACL_AUTO_INHERIT_REQ
bits. If both are set we store SEC_DESC_DACL_AUTO_INHERITED
as this alters whether SEC_ACE_FLAG_INHERITED_ACE is set
when an ACE is inherited. Otherwise we zero these bits out.
See:
http://social.msdn.microsoft.com/Forums/eu/os_fileservices/thread/11f77b68-731e-407d-b1b3-064750716531
for details.
2012-08-30 10:08:50 -07:00
Jeremy Allison
795920cf4a
Change the other two places where we set a security descriptor given by the client to got through set_sd(),
...
the canonicalize sd function.
2012-08-30 10:08:50 -07:00
Jeremy Allison
70ebf1da67
Re-add set_sd(), called from set_sd_blob(). Allows us to centralize all ACL canonicalization.
2012-08-30 10:08:50 -07:00
Jeremy Allison
8c84ecef89
Rename set_sd() to set_sd_blob() - this describes what it does.
2012-08-30 10:08:50 -07:00
Andreas Schneider
ba862f47d7
s3-smbd: Fix flooding the logs with records we don't find in pcap.
...
Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Tue Aug 28 16:38:55 CEST 2012 on sn-devel-104
2012-08-28 16:38:55 +02:00
Andrew Bartlett
dc8d29cdae
s3-vfs: Indicate the symlink destination when failing check_reduced_name
2012-08-28 15:47:37 +10:00
Andrew Bartlett
0aed29105e
s3-smbd: Add security_info_wanted argument to get_nt_acl_no_snum
...
I need to get at the owner, group, DACL and SACL when testing correct
ACL storage.
Andrew Bartlett
2012-08-23 15:02:26 +02:00
Andrew Bartlett
e058dfb3b0
s3-pysmbd: Fix return type of smbd.get_nt_acl
...
The security_ prefix is stripped off in the python bindings.
Andrew Bartlett
2012-08-23 15:02:26 +02:00
Andrew Bartlett
e8e24a251b
s3-smbd: Add talloc_stackframe() to get_nt_acl_no_snum()
...
This is required because the functions it calls use talloc_tos().
Andrew Bartlett
2012-08-23 15:02:26 +02:00
Andrew Bartlett
8c71dc3505
param: Add startup checks for valid server role/binary combinations
...
This should eliminate confusion from our users about what they can
expect to successfully run.
Andrew Bartlett
2012-08-23 15:02:26 +02:00
Andrew Bartlett
332efe1539
s3-pysmbd: Fix error message
2012-08-23 15:02:26 +02:00
Andrew Bartlett
51e3547426
s3-pysmbd: Allow a mode to be specified for the simple ACL
...
The additional group for the ACL is now optional.
Andrew Bartlett
2012-08-23 15:02:26 +02:00
Stefan Metzmacher
069db9b630
s3:smb2_break: encrypt OPLOCK BREAK notifications
...
metze
Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Thu Aug 23 10:01:14 CEST 2012 on sn-devel-104
2012-08-23 10:01:14 +02:00
Stefan Metzmacher
54dfd08cb2
s3:smb2_server: use smbXsrv_session->nonce_*
...
metze
2012-08-23 08:23:07 +02:00
Stefan Metzmacher
6c7ffa9092
s3:smb2_server: remove dump_data() from smbd_smb2_request_pending_timer()
...
This was just for debugging...
metze
2012-08-23 08:23:07 +02:00
Andrew Bartlett
125e93cdde
s3-pysmbd: Correct the python type for smb_acl_t
...
The t is weird, but the python bindings trim the traditional IDL name
prefix of each element, as it is usually rudundent.
Andrew Bartlett
2012-08-22 01:31:57 +02:00
Andrew Bartlett
dc063bf3bd
s3-pysmbd: Add get/set functions for the posix ACL layer
...
These will be used to verify that an ACL set as an NT ACL creates
the correct posix ACL.
Andrew Bartlett
2012-08-21 15:25:50 +10:00
Andrew Bartlett
4df2c65ea6
s3-pysmbd: Correct comments in python VFS bindings
2012-08-21 15:25:50 +10:00
Andrew Bartlett
d963aaf73b
s3-pysmbd: Add hook for a VFS chown()
2012-08-21 15:25:49 +10:00
Andrew Bartlett
0f2d288f76
s3-smbd: ensure we give appropriate errors for EA requests on streams
2012-08-20 21:57:47 +10:00
Andrew Bartlett
6ce084f092
s3-smbd: Do not look for EA information on a stream
...
The estimated EA size needs to be of the main file. However, the fsp
may point to the stream, so we need to ignore it if this is the case.
This may mean we estimate wrong if there has been a rename.
Andrew Bartlett
2012-08-20 21:57:46 +10:00
Andrew Bartlett
f9f8a8c3d8
s3-smbd: Push smb_fname into estimate_ea_size
...
This ensures that we return the ea size of the stream, not the overall file.
This is important as if there is an EA on the main file, the raw.streams
test was failing.
Andrew Bartlett
2012-08-20 21:57:46 +10:00
Stefan Metzmacher
45471f4d8f
s3:smb2_negprot: annouce/negotiate SMB3 encryption support
...
metze
2012-08-17 14:51:57 +02:00
Stefan Metzmacher
9397d6709f
s3:smb2_server: add SMB3 encryption support
...
metze
2012-08-17 14:51:57 +02:00
Stefan Metzmacher
9f1dfd8fac
s3:smbd: don't disconnect the client when a share has "smb encrypt = required"
...
It's not the client fault, if he doesn't know that encryption is required.
We should just return ACCESS_DENIED and let the client work on other
shares and open files on the current SMB connection.
metze
2012-08-17 14:51:57 +02:00
Stefan Metzmacher
e5d4e8df6b
s3:smbd: lp_smb_encrypt() returns SMB_SIGNING_* values
...
metze
2012-08-17 14:51:57 +02:00
Stefan Metzmacher
8b3da9a1f4
s3:smbd: make use of ENCRYPTION_REQUIRED()
...
metze
2012-08-17 14:51:57 +02:00
Stefan Metzmacher
16edb6eb7b
s3:smb2_server: try to sign an error response if we have a signing key
...
metze
Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Fri Aug 17 00:54:01 CEST 2012 on sn-devel-104
2012-08-17 00:54:01 +02:00
Stefan Metzmacher
19ca98a162
s3:smb2_server: verify the signature before the session_status
...
metze
2012-08-16 23:13:07 +02:00
Stefan Metzmacher
f4432fea6a
s3:smb2_server: add some const to print_req_vectors()
...
metze
2012-08-16 23:13:07 +02:00
Volker Lendecke
fbebd7530e
s3-libsmb: Add a python wrapper
...
Please note that this is not finished and only for internal use.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
2012-08-16 21:10:32 +02:00
Andrew Bartlett
1157db293f
s3-smbd: Do not check no_acl_syscall_error(errno) after sys_acl_init()
...
This is no longer a VFS call, so will no longer fail in this way.
Andrew Bartlett
2012-08-16 15:25:39 +10:00
Stefan Metzmacher
b596a116fd
s3:smb2_server: do calculations based on SMBD_SMB2_NUM_IOV_PER_REQ in smbd_smb2_request_validate()
...
metze
2012-08-15 14:45:04 +02:00
Andrew Bartlett
24b1143068
s3-sysacls: Remove sys_acl_free_qualifier() as it is a no-op
...
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Wed Aug 15 05:23:18 CEST 2012 on sn-devel-104
2012-08-15 05:23:18 +02:00
Andrew Bartlett
6ccfd05e72
s3-sysacls: Remove sys_acl_free_acl() and replace with TALLOC_FREE()
2012-08-15 11:44:50 +10:00