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

47520 Commits

Author SHA1 Message Date
Volker Lendecke
ad82251c23 winbind: Add some const
This makes source and destination a bit clearer to me

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2016-02-16 10:50:10 +01:00
Noel Power
d9e335872a build: Fix cluster-support option, default was 'None' now 'False'
Cluster-support had some auto-detection but no longer does.

Prior to commit id(s) e67c4b977a &
69c0c43d55 cluster support was auto
detected

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Uri Simchoni <uri@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>

Autobuild-User(master): Amitay Isaacs <amitay@samba.org>
Autobuild-Date(master): Tue Feb 16 04:03:14 CET 2016 on sn-devel-144
2016-02-16 04:03:13 +01:00
Ralph Boehme
8b765ac011 smbd: fix build with FAM support
Add missing define of HAVE_FAM when FAM is detected.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=11733

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>

Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Sun Feb 14 13:50:56 CET 2016 on sn-devel-144
2016-02-14 13:50:56 +01:00
Ralph Boehme
a6f983a17b smbd: fix build with FAM support
Rename _fam_watch() to fam_watch(). I don't see a reason why this should
be prefixed with an underscore. It's also inline with the corresponding
inotify function inotify_watch().

Bug: https://bugzilla.samba.org/show_bug.cgi?id=11733

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
2016-02-14 10:41:06 +01:00
Andreas Schneider
92afa1b165 smbd: Simplify chroot option in smbd
rpmlint has a check for this and prefers to call chdir() before
chroot(). If not it will complain with
missing-call-to-chdir-with-chroot. The old code equivalent secure. See

    http://unixwiz.net/techtips/chroot-practices.html

This removes several unneeded talloc_tos() calls.

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>

Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Sat Feb 13 03:50:54 CET 2016 on sn-devel-144
2016-02-13 03:50:54 +01:00
Andreas Schneider
b504918372 s3-waf: Install smbspool_krb5_wrapper in LIBEXECDIR
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Martin Schwenke <martin@meltin.net>

Autobuild-User(master): Martin Schwenke <martins@samba.org>
Autobuild-Date(master): Sat Feb 13 00:41:33 CET 2016 on sn-devel-144
2016-02-13 00:41:32 +01:00
Christian Ambach
feac8bfd37 s3:winbindd/idmap_autorid_tdb fix a compiler warning
about a potentially uninitialized variable

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Fri Feb 12 12:07:07 CET 2016 on sn-devel-144
2016-02-12 12:07:07 +01:00
Christian Ambach
f0a260cc1b s3:vfs_fruit fix a compiler warning
about a potentially uninitialized variable

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2016-02-12 09:01:14 +01:00
Jeremy Allison
5172bf0c5b s3: smbd: posix_acls: Fix check for setting u:g:o entry on a filesystem with no ACL support.
Since 4.0.x we add 2 additional ACE entries, one SMB_ACL_USER
and SMB_ACL_GROUP to match the existing SMB_ACL_USER_OBJ and
SMB_ACL_GROUP_OBJ entries. The two additional entries break
the simple "must have 3 entries" check done inside convert_canon_ace_to_posix_perms().
Replace this with a more complete test.

Problem and initial fix provided by <tcleamy@ucdavis.edu>

BUG: https://bugzilla.samba.org/show_bug.cgi?id=10489

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Uri Simchoni <uri@samba.org>

Autobuild-User(master): Uri Simchoni <uri@samba.org>
Autobuild-Date(master): Thu Feb 11 11:14:53 CET 2016 on sn-devel-144
2016-02-11 11:14:52 +01:00
Stefan Metzmacher
719428f587 s3:dbwrap: add dbwrap_tdb_require_mutexes:*= option
This is similar to dbwrap_tdb_mutexes:*= (which is autodetected by default),
but dbwrap_tdb_require_mutexes is off by default.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
2016-02-08 22:32:23 +01:00
Volker Lendecke
9219756a36 tldap: Add a missing TALLOC_FREE(frame)
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
2016-02-08 22:32:23 +01:00
Michael Adam
d6f5fc8c2d dlist: remove unneeded argument from DLIST_DEMOTE()
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-02-06 21:48:17 +01:00
Michael Adam
476672b647 dlist: remove unneeded type argument from DLIST_ADD_END()
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-02-06 21:48:17 +01:00
Luca Olivetti
5d759bd0d4 pdb: Fix segfault in pdb_ldap for missing gecos
Bug: https://bugzilla.samba.org/show_bug.cgi?id=11530
Signed-off-by: Luca Olivetti <luca@wetron.es>
Reviewed-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>

Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Fri Feb  5 16:47:00 CET 2016 on sn-devel-144
2016-02-05 16:47:00 +01:00
Christian Ambach
da2aae933e s3:utils/smbget set default blocksize
this got lost in the recent refactorings and causes problems
when smbget attempts to use a zero byte read buffer

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>

Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Fri Feb  5 12:10:16 CET 2016 on sn-devel-144
2016-02-05 12:10:16 +01:00
Christian Ambach
64121471f9 s3:utils/smbget add a error message on allocation error
Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
2016-02-05 09:00:20 +01:00
Jose A. Rivera
aec07b8b60 s3:smbd:open: Skip redundant call to file_set_dosmode when creating a new file.
Signed-off-by: Jose A. Rivera <jarrpa@samba.org>
Pair-programmed-with: Ira Cooper <ira@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>

Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Fri Feb  5 04:37:43 CET 2016 on sn-devel-144
2016-02-05 04:37:43 +01:00
Hemanth Thummala
8247d93701 loadparm: Fix memory leak issue.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=11708

Signed-off-by: Hemanth Thummala <hemanth.thummala@nutanix.com>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Thu Feb  4 12:39:14 CET 2016 on sn-devel-144
2016-02-04 12:39:14 +01:00
Robin Hack
e2699685ca samba3.blackbox.smbclient.forceuser_validusers: Add new test for force user option.
Test covers commit
cf0934caf2

BUG: https://bugzilla.samba.org/show_bug.cgi?id=9878
RH BUG: https://bugzilla.redhat.com/show_bug.cgi?id=1077651

How to test:
$ make -j test TESTS="samba3.blackbox.smbclient.forceuser_validusers"
RESULD: Should PASS
$ git revert cf0934caf2
$ make -j test TESTS="samba3.blackbox.smbclient.forceuser_validusers"
RESULT: Should FAIL

Signed-off-by: Robin Hack <rhack@redhat.com>
Reviewed-by: Uri Simchoni <uri@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>

Autobuild-User(master): Uri Simchoni <uri@samba.org>
Autobuild-Date(master): Thu Feb  4 03:44:42 CET 2016 on sn-devel-144
2016-02-04 03:44:42 +01:00
Christof Schmitt
68bb5e2ba2 gencache: Remove unused defines
Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
2016-02-03 21:27:08 +01:00
Volker Lendecke
7434723ecd tldap: Parse a search entry only if it is one
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>

Autobuild-User(master): Günther Deschner <gd@samba.org>
Autobuild-Date(master): Wed Feb  3 18:12:44 CET 2016 on sn-devel-144
2016-02-03 18:12:43 +01:00
Volker Lendecke
f09cebd4fc tldap: Make tldap_search use tldap_search_all
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2016-02-03 15:04:11 +01:00
Volker Lendecke
0d1165a424 tldap: Add tldap_pending_reqs()
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2016-02-03 15:04:11 +01:00
Volker Lendecke
d29c45ce41 tldap: Add tldap_search_all
Signed-off-by: Volker Lendecke <vl@samba.org>

TLDAPRC
Reviewed-by: Guenther Deschner <gd@samba.org>
2016-02-03 15:04:11 +01:00
Volker Lendecke
b6244ae257 tldap: Avoid a "ret == false"
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2016-02-03 15:04:11 +01:00
Volker Lendecke
024c619fa8 spnego: Correctly check asn1_tag_remaining retval
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2016-02-03 15:04:11 +01:00
Volker Lendecke
f3dbaaca41 libads: Factor out ldap_schema_oids.h
Make the oids accessible without having to include ADS_STRUCT&friends

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2016-02-03 15:04:11 +01:00
Volker Lendecke
465c64676b smbtorture3: Convert the tldap caller to TLDAPRC
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2016-02-03 15:04:11 +01:00
Volker Lendecke
2c3cf3ce60 lib: Introduce TLDAPRC
Make ldap return codes type safe

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2016-02-03 15:04:11 +01:00
Volker Lendecke
2bd88bff04 tldap: Parse the sasl output blob
Reviewed-by: Guenther Deschner <gd@samba.org>
2016-02-03 15:04:11 +01:00
Volker Lendecke
3673752f68 tldap: Slightly simplify tldap_search_cb
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2016-02-03 15:04:11 +01:00
Volker Lendecke
22f06c2e6f tldap: Mark server down if read failed
This matches tldap_msg_sent

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2016-02-03 15:04:11 +01:00
Volker Lendecke
59c1b1048f tldap: Add some required includes
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2016-02-03 15:04:10 +01:00
Volker Lendecke
2d80498e64 smbd: Fix CID 1351215 Improper use of negative value
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>

Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Wed Feb  3 15:03:09 CET 2016 on sn-devel-144
2016-02-03 15:03:08 +01:00
Volker Lendecke
f193361850 smbd: Fix CID 1351216 Dereference null return value
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2016-02-03 11:43:16 +01:00
Günther Deschner
943e69ca8f libsmb/pysmb: add pytalloc-util dependency to fix the build.
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>

Autobuild-User(master): Günther Deschner <gd@samba.org>
Autobuild-Date(master): Tue Feb  2 15:49:14 CET 2016 on sn-devel-144
2016-02-02 15:49:14 +01:00
Volker Lendecke
88c4687945 idl: Rename "principle" to "principal_name"
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2016-02-02 08:42:09 +01:00
Michael Adam
6831ba35b9 s3:vfs:glusterfs: fix build after quota changes.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Uri Simchoni <uri@samba.org>

Autobuild-User(master): Uri Simchoni <uri@samba.org>
Autobuild-Date(master): Mon Feb  1 22:09:18 CET 2016 on sn-devel-144
2016-02-01 22:09:18 +01:00
Stefan Metzmacher
81cf1fa9e1 s3:libads: we always have arcfour-hmac-md5 support
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>

Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Mon Feb  1 13:02:32 CET 2016 on sn-devel-144
2016-02-01 13:02:32 +01:00
Stefan Metzmacher
14f1a94b6f s3:clispnego: fix confusing warning in spnego_gen_krb5_wrap()
asn1_extract_blob() stops further asn1 processing by setting has_error.

Don't call asn1_has_error() after asn1_extract_blob() has been successful
otherwise we get an "Failed to build krb5 wrapper at" message
on success.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11702

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
2016-02-01 09:53:09 +01:00
Jeremy Allison
8024f532e6 s3: smbd: Fix timestamp rounding inside SMB2 create.
Setting "dos filetime resolution = yes" should round
to 2 second increments. Fix missing path inside smbd.

Fix confirmed by reporter Hubert Gilch <hg@sepag.de>.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11703

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>

Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Fri Jan 29 10:41:01 CET 2016 on sn-devel-144
2016-01-29 10:41:01 +01:00
Christian Ambach
cac1086ae1 s3-utils/smbget: Fix user-/name password reading from rcfile
As the password option is gone, code needs to be able to read password
from user parameter when user%password syntax is used.

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2016-01-28 09:58:26 +01:00
Christian Ambach
bf1c1ad068 s3-utils/smbget: Fix reading the rcfile
shortName in POPT_AUTOHELP is null, so the loop always stopped at this
item.

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2016-01-28 09:58:26 +01:00
Andreas Schneider
e1548c5bf7 s3-utils/smbget: Fix option parsing and apply samba defaults
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Christian Ambach <ambi@samba.org>
2016-01-28 09:58:26 +01:00
Uri Simchoni
e7a8ef4f26 selftest: fix test_dfree_quota.sh
Eliminate backslashes from smbcquotas output so that we
don't have to deal with them correctly when parsing the output.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11697

Signed-off-by: Uri Simchoni <uri@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-01-27 22:02:08 +01:00
Uri Simchoni
05a1ba8995 selftest: add test case for different quote/dfree block size
BUG: https://bugzilla.samba.org/show_bug.cgi?id=11681

Signed-off-by: Uri Simchoni <uri@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-01-27 22:02:08 +01:00
Uri Simchoni
67c89715d0 smbd: show correct disk size for different quota and dfree block sizes
When file system stats (VFS disk_free_fn) and quota (VFS get_quota_fn)
return different block sizes, normalize values before comparing.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11681

Signed-off-by: Uri Simchoni <uri@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-01-27 22:02:08 +01:00
Uri Simchoni
465c3d9a4e smbd quotas: avoid stat of foreign file systems
When determining the block device of our file system, avoid
stat'ing paths which are definitely not the mount point of
our file system. This is done to avoid stalling smbd due to
unresponsive network file systems (e.g. NFS) which are not
related to the SMB shares.

See discussion in samba-technical for vfs_fileid:
https://lists.samba.org/archive/samba-technical/2016-January/111553.html

Signed-off-by: Uri Simchoni <uri@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>

Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Wed Jan 27 03:35:48 CET 2016 on sn-devel-144
2016-01-27 03:35:47 +01:00
Uri Simchoni
c6ed45fe71 s3-lib: introduce sys_realpath()
Add sys_realpath() function that captures the OS variations
on realpath().

Signed-off-by: Uri Simchoni <uri@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-01-27 00:22:22 +01:00
Andreas Schneider
192f1516c3 waf: Only build smb_krb5_wrapper if we have CUPS
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2016-01-26 15:58:12 +01:00