The branch, master has been updated via aef1d45 samba-tool: Remove --use-xattrs support without --use-ntvfs from 7c84cb5 wafsamba: add -Werror=format-security to the developer build
https://git.samba.org/?p=samba.git;a=shortlog;h=master - Log ----------------------------------------------------------------- commit aef1d45c9a3af5ac9a5f262604d1f364c397875c Author: Andrew Bartlett <abart...@samba.org> Date: Sun Sep 4 21:33:30 2016 +1200 samba-tool: Remove --use-xattrs support without --use-ntvfs The only reasonable use --use-xattrs=no should be used is in selftest, and there is no need for that or --use-xattrs=auto without --use-ntvfs, all systems we support in production for the AD DC have xattrs, as using smbd needs posix ACLs. This also removes the option entirely if NTVFS support is omitted from the build. I would prefer to get rid of the option, but currently selftest relies on the default of --use-xattrs=auto, and we first should get rid of that auto-detection, which will then mean we need --use-xattrs=no specified wherever we specify --use-ntvfs. Signed-off-by: Andrew Bartlett <abart...@samba.org> Reviewed-by: Garming Sam <garm...@catalyst.net.nz> Autobuild-User(master): Garming Sam <garm...@samba.org> Autobuild-Date(master): Tue Sep 6 04:21:42 CEST 2016 on sn-devel-144 ----------------------------------------------------------------------- Summary of changes: python/samba/netcmd/domain.py | 30 ++++++++++++++++++++++++------ 1 file changed, 24 insertions(+), 6 deletions(-) Changeset truncated at 500 lines: diff --git a/python/samba/netcmd/domain.py b/python/samba/netcmd/domain.py index 928caa3..9661828 100644 --- a/python/samba/netcmd/domain.py +++ b/python/samba/netcmd/domain.py @@ -236,8 +236,6 @@ class cmd_domain_provision(Command): help="Set target directory"), Option("--ol-mmr-urls", type="string", metavar="LDAPSERVER", help="List of LDAP-URLS [ ldap://<FQHN>:<PORT>/ (where <PORT> has to be different than 389!) ] separated with comma (\",\") for use with OpenLDAP-MMR (Multi-Master-Replication), e.g.: \"ldap://s4dc1:9000,ldap://s4dc2:9000\""), - Option("--use-xattrs", type="choice", choices=["yes", "no", "auto"], help="Define if we should use the native fs capabilities or a tdb file for storing attributes likes ntacl, auto tries to make an inteligent guess based on the user rights and system capabilities", default="auto"), - Option("--use-rfc2307", action="store_true", help="Use AD to store posix attributes (default = no)"), ] @@ -253,7 +251,13 @@ class cmd_domain_provision(Command): ] ntvfs_options = [ - Option("--use-ntvfs", action="store_true", help="Use NTVFS for the fileserver (default = no)"), + Option("--use-ntvfs", action="store_true", help="Use NTVFS for the fileserver (default = no)"), + Option("--use-xattrs", type="choice", choices=["yes","no","auto"], + metavar="[yes|no|auto]", + help="Define if we should use the native fs capabilities or a tdb file for " + "storing attributes likes ntacl when --use-ntvfs is set. " + "auto tries to make an inteligent guess based on the user rights and system capabilities", + default="auto") ] if os.getenv('TEST_LDAP', "no") == "yes": @@ -409,6 +413,11 @@ class cmd_domain_provision(Command): if use_xattrs == "yes": eadb = False + elif use_xattrs == "auto" and use_ntvfs == False or use_ntvfs == None: + eadb = False + elif use_ntvfs == False or use_ntvfs == None: + raise CommandError("--use-xattrs=no requires --use-ntvfs (not supported for production use). " + "Please re-run with --use-xattrs omitted.") elif use_xattrs == "auto" and not lp.get("posix:eadb"): if targetdir: file = tempfile.NamedTemporaryFile(dir=os.path.abspath(targetdir)) @@ -1457,8 +1466,6 @@ class cmd_domain_classicupgrade(Command): help="Path prefix where the new Samba 4.0 AD domain should be initialised"), Option("--quiet", help="Be quiet", action="store_true"), Option("--verbose", help="Be verbose", action="store_true"), - Option("--use-xattrs", type="choice", choices=["yes","no","auto"], metavar="[yes|no|auto]", - help="Define if we should use the native fs capabilities or a tdb file for storing attributes likes ntacl, auto tries to make an inteligent guess based on the user rights and system capabilities", default="auto"), Option("--dns-backend", type="choice", metavar="NAMESERVER-BACKEND", choices=["SAMBA_INTERNAL", "BIND9_FLATFILE", "BIND9_DLZ", "NONE"], help="The DNS server backend. SAMBA_INTERNAL is the builtin name server (default), " @@ -1470,7 +1477,13 @@ class cmd_domain_classicupgrade(Command): ntvfs_options = [ Option("--use-ntvfs", help="Use NTVFS for the fileserver (default = no)", - action="store_true") + action="store_true"), + Option("--use-xattrs", type="choice", choices=["yes","no","auto"], + metavar="[yes|no|auto]", + help="Define if we should use the native fs capabilities or a tdb file for " + "storing attributes likes ntacl when --use-ntvfs is set. " + "auto tries to make an inteligent guess based on the user rights and system capabilities", + default="auto") ] if samba.is_ntvfs_fileserver_built(): takes_options.extend(ntvfs_options) @@ -1519,6 +1532,11 @@ class cmd_domain_classicupgrade(Command): eadb = True if use_xattrs == "yes": eadb = False + elif use_xattrs == "auto" and use_ntvfs == False or use_ntvfs == None: + eadb = False + elif use_ntvfs == False or use_ntvfs == None: + raise CommandError("--use-xattrs=no requires --use-ntvfs (not supported for production use). " + "Please re-run with --use-xattrs omitted.") elif use_xattrs == "auto" and not s3conf.get("posix:eadb"): if targetdir: tmpfile = tempfile.NamedTemporaryFile(dir=os.path.abspath(targetdir)) -- Samba Shared Repository