summaryrefslogtreecommitdiff
path: root/source3
AgeCommit message (Collapse)AuthorFilesLines
2018-04-05wscript_build: fix c modules deps name for Python 3Joe Guo3-3/+8
In wscript_build, the lib name in deps list may have postfix for Python 3. Instead of hard coding the base name directly, need to load correct name for each Python version with `bld.pyembed_libname`. Signed-off-by: Joe Guo <joeg@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
2018-04-05python3 port for smbd moduleNoel Power2-8/+17
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
2018-04-05python samba test: enable samba.tests.libsmb_samba_internal for py3Noel Power1-1/+2
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
2018-04-05python3 port for libsmb_samba_internal moduleNoel Power1-8/+20
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
2018-04-05python3 port for passdb moduleNoel Power2-109/+120
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
2018-04-05python3 port for param moduleNoel Power2-7/+18
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
2018-04-05smbclient: Handle ENUM_DIR in "notify" commandVolker Lendecke1-2/+7
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Thu Apr 5 04:05:52 CEST 2018 on sn-devel-144
2018-04-05libsmb: Handle IO_TIMEOUT in cli_smb2_notify properlyVolker Lendecke1-0/+9
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
2018-04-04s3: lib: messages: Don't use the result of sec_init() before calling sec_init().Lutz Justen1-2/+7
Commit ad8c7171ba86e8a47d78b0c7329bb814e5a8871e accidently moved sec_init() to the point after sec_initial_uid() is called in the call to directory_create_or_exist_strict(). I missed this in the review (sorry). This works as root as initial_uid/initial_gid are static (and so initialized as zero) but doesn't work on ChromeOS as this code isn't running as root. BUG: https://bugzilla.samba.org/show_bug.cgi?id=13368 Signed-off-by: Lutz Justen <ljusten@google.com> Reviewed-by: Jeremy Allison <jra@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Wed Apr 4 23:52:02 CEST 2018 on sn-devel-144
2018-04-04net: Avoid tallocsVolker Lendecke1-2/+3
Not really performance critical, but I think it's worth establishing sample code to use more stack variables than going out to talloc. Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
2018-04-04net: Fix CID 1414752 Resource leakVolker Lendecke1-0/+3
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
2018-04-04pdb_ldap: Fix CID 1363266 Resource leakVolker Lendecke1-2/+3
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
2018-04-04utils: Fix CID 1035541 Uninitialized scalar variableVolker Lendecke1-1/+1
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
2018-04-04groupdb: Fix CID 1167984 Ignoring number of bytes readVolker Lendecke1-1/+5
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
2018-04-04smbd: Fix CID 240676 Dereference after null checkVolker Lendecke1-0/+7
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
2018-04-03s3:modules: Set -Wno-strict-overflow for getdate if supportedAndreas Schneider1-0/+5
bison generates an C89 files which does some weired things. Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
2018-04-03s3:modules: Generate new getdate.c with bisonAndreas Schneider1-977/+897
bison -o source3/modules/getdate.c source3/modules/getdate.y<Paste> Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Alexander Bokovoy <ab@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
2018-04-03s3:modules: Update getdate.y to work with newer bison versionsAndreas Schneider1-122/+121
Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Alexander Bokovoy <ab@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
2018-04-03s3:torture: Fix size types in make_nonstd_fd()Andreas Schneider1-2/+2
This fixes compilation with -Wstrict-overflow=2. Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
2018-04-03s3:client: Fix size typesAndreas Schneider1-8/+15
This fixes compilation with -Wstrict-overflow=2. Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
2018-04-03s3:spoolss: Fix size typesAndreas Schneider1-1/+1
This fixes compilation with -Wstrict-overflow=2. Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
2018-04-03s3:printing: Fix size typesAndreas Schneider2-11/+18
This fixes compilation with -Wstrict-overflow=2. Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
2018-04-03s3:smbd: Fix size types in reply_negprot()Andreas Schneider1-5/+8
This fixes compilation with -Wstrict-overflow=2. Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
2018-04-03s3:modules: fix the build of vfs_aixacl2.cStefan Metzmacher1-2/+3
BUG: https://bugzilla.samba.org/show_bug.cgi?id=13345 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Björn Jacke <bjacke@samba.org> Autobuild-User(master): Stefan Metzmacher <metze@samba.org> Autobuild-Date(master): Tue Apr 3 20:18:58 CEST 2018 on sn-devel-144
2018-04-03s3:modules: make virusfilter_io_connect_path() more portableStefan Metzmacher1-15/+16
We have existing utility functions to prepare a socket. BUG: https://bugzilla.samba.org/show_bug.cgi?id=13343 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Björn Jacke <bjacke@samba.org>
2018-04-03s3:modules: fix the picky-developer build of vfs_virusfilter.c on FreeBSD 11Stefan Metzmacher1-2/+3
BUG: https://bugzilla.samba.org/show_bug.cgi?id=13344 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Björn Jacke <bjacke@samba.org>
2018-03-30s3:smbd: don't use the directory cache for SMB2/3Ralph Boehme1-3/+29
Bug: https://bugzilla.samba.org/show_bug.cgi?id=13363 Signed-off-by: Ralph Boehme <slow@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Fri Mar 30 03:51:48 CEST 2018 on sn-devel-144
2018-03-29s3: smbd: Files or directories can't be opened DELETE_ON_CLOSE without ↵Jeremy Allison1-0/+12
delete access. BUG: https://bugzilla.samba.org/show_bug.cgi?id=13358 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Volker Lendecke <Volker.Lendecke@SerNet.DE>
2018-03-29libads: Fix CID 1349423 Resource leakVolker Lendecke1-1/+2
get_sorted_dc_list should already take care, but this way it's safer Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Thu Mar 29 03:45:00 CEST 2018 on sn-devel-144
2018-03-29net: Fix CID 1128559 Dereference null return valueVolker Lendecke1-3/+7
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
2018-03-29smbstatus: Fix CID 1128560 Dereference null return valueVolker Lendecke1-1/+9
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
2018-03-29vfs_fruit: Fix CID 1433613 Operands don't affect resultVolker Lendecke1-2/+2
Two changes: First, we can't check multiplication overflow after the operation. This has to be done before with a division. Second, there is no OFF_T_MAX, and both operands are size_t, so check for SIZE_MAX. The result is assigned to off_t, but I'm not sure where the automatic coercion from size_t to off_t would happen. Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
2018-03-29libads: Fix 1433611 Resource leakVolker Lendecke1-0/+1
Not really a memleak due to the passed-in talloc ctx, but this way it's cleaner Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
2018-03-29libads: Fix CID 1433606 Dereference before null checkVolker Lendecke1-1/+1
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
2018-03-27selftest: Do not run *.lock tests against both nt4_dc and ad_dcAndrew Bartlett1-1/+2
This part of the protocol is not changed by being an AD DC. Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Gary Lockyer <gary@catalyst.net.nz>
2018-03-27selftest: Do not run raw.notify, smb2.oplock and raw.oplock twiceAndrew Bartlett1-1/+2
These are slower tests that do not need to be run against the ad_dc configuration in particular. This saves time in the ad_dc job which needs to stay under 50mins to pass on travis-ci (and faster tests are better for everyone anyway). Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Gary Lockyer <gary@catalyst.net.nz>
2018-03-27selftest: Move slower base.deny1 and base.deny2 to fileserver environmentAndrew Bartlett1-1/+1
This avoids these running in the ad_dc environment which we need to get under 50mins for travis-ci. Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Gary Lockyer <gary@catalyst.net.nz>
2018-03-27Move smbtorture3 tests to fileserver environmentAndrew Bartlett1-1/+1
Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Gary Lockyer <gary@catalyst.net.nz>
2018-03-27selftest: Move base.delaywrite tests to fileserver environmentAndrew Bartlett1-1/+1
This aims to keep the ad_dc tests well below 50mins for travis CI and base.delaywrite is very slow. Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Gary Lockyer <gary@catalyst.net.nz>
2018-03-27selftest: Do not run smb2.notify against nt4_dc and ad_dcAndrew Bartlett1-1/+0
This is a slow test and we need to keep the time on ad_dc down to below 50mins total for travis-ci. Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Gary Lockyer <gary@catalyst.net.nz>
2018-03-24winbindd: Use talloc_zero_array for consistency with other winbindd_domain ↵Andrew Bartlett1-2/+2
allocators The other allocator for this structure uses talloc_zero() Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Ralph Boehme <slow@samba.org> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Sat Mar 24 07:21:37 CET 2018 on sn-devel-144
2018-03-24winbindd: Do re-connect if the RPC call fails in the passdb caseAndrew Bartlett1-0/+128
This is very, very unlikely but possible as in the AD case the RPC server is in another process that may eventually be able to restart. Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Ralph Boehme <slow@samba.org>
2018-03-24winbindd: Add a cache of the samr and lsa handles for the passdb domainAndrew Bartlett1-108/+159
This domain is very close, in AD DC configurations over a internal ncacn_np pipe and otherwise in the same process via C linking. It is however very expensive to re-create the binding handle per SID->name lookup, so keep a cache. Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Ralph Boehme <slow@samba.org>
2018-03-23s3/script/tests: convert print func to be py2/py3 compatibleNoel Power1-3/+4
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
2018-03-23s3:lib: Fix probably a copy&paste error in namemap_cache_set_sid2name()Andreas Schneider1-1/+0
BUG: https://bugzilla.samba.org/show_bug.cgi?id=13350 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Fri Mar 23 01:59:08 CET 2018 on sn-devel-144
2018-03-22s3: smbd: always set vuid in check_user_ok()Ralph Boehme1-0/+2
A SMB session reauth will have invalidated conn->vuid via conn_clear_vuid_caches(). Ensure conn->vuid always has the vuid of the current user in check_user_ok(). Bug: https://bugzilla.samba.org/show_bug.cgi?id=13351 Signed-off-by: Ralph Boehme <slow@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Autobuild-User(master): Ralph Böhme <slow@samba.org> Autobuild-Date(master): Thu Mar 22 18:26:04 CET 2018 on sn-devel-144
2018-03-22s3-libnet: move rpc_join label into HAVE_ADS block with only callerAndrew Bartlett1-1/+2
Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
2018-03-22libsmb: Use the same #ifdef for is_our_primary_domain() as the only callerAndrew Bartlett1-1/+1
Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
2018-03-22s3: smbd: SMB2: Add DBGC_SMB2_CREDITS class to specifically debug credit issues.Jeremy Allison1-18/+30
https://bugzilla.samba.org/show_bug.cgi?id=13347 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
2018-03-22s3: debug: smb2: Create a new DBGC_SMB2 debug class and mark all ↵Jeremy Allison22-0/+66
smbd/smb2_*.c files with it. Will allow easier smb2-specific debugging. https://bugzilla.samba.org/show_bug.cgi?id=13347 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>