bbaumbach/samba-autobuild/.git
3 years agos3/smbd: modify estimate_ea_size fn signature to take fsp only
Noel Power [Mon, 1 Feb 2021 21:09:08 +0000 (21:09 +0000)]
s3/smbd: modify estimate_ea_size fn signature to take fsp only

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agos3/smbd: use smb_fname->fsp for get_ea_list_from_file_path in estimate_ea_size()
Noel Power [Fri, 29 Jan 2021 14:54:47 +0000 (14:54 +0000)]
s3/smbd: use smb_fname->fsp for get_ea_list_from_file_path in estimate_ea_size()

Additionally ensure get_ea_list_from_file_path is called with base file.

Previously fsp was set to NULL if fsp pointed to a ntfs stream which in
turn ensured that 'base_path' from the smb_fname was used (which points
to the base file). Now we get a pathref fsp (pointing to the base file)
instead

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agos3/smbd: modify get_ea_names_from_file signature fn to take fsp alone
Noel Power [Sun, 31 Jan 2021 19:18:03 +0000 (19:18 +0000)]
s3/smbd: modify get_ea_names_from_file signature fn to take fsp alone

Removes the smb_filename function parameter

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agos3/smbd: use SMB_VFS_FLISTXATTR() alone (also added assert fsp is not NULL)
Noel Power [Fri, 29 Jan 2021 14:53:43 +0000 (14:53 +0000)]
s3/smbd: use SMB_VFS_FLISTXATTR() alone (also added assert fsp is not NULL)

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agos3/modules: Ensure vfs_streaminfo gets passed valid pathref smb_filename
Noel Power [Mon, 8 Feb 2021 10:42:22 +0000 (10:42 +0000)]
s3/modules: Ensure vfs_streaminfo gets passed valid pathref smb_filename

the smb_filename/smb_filename->fsp passed to vfs_streaminfo
eventually is passed to SMB_VFS_FLISTXATTR, we need to ensure this is
properly setup and not NULL

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agos3/smbd: call get_ea_list_from_file with smb_fname->fsp
Noel Power [Fri, 29 Jan 2021 18:54:20 +0000 (18:54 +0000)]
s3/smbd: call get_ea_list_from_file with smb_fname->fsp

A step to transition away from using smb_fname & fsp
paramater combination with this function.

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agos3: VFS: nfs4_acls. Add missing TALLOC_FREE(frame) in error path.
Peter Eriksson [Tue, 23 Feb 2021 20:13:37 +0000 (12:13 -0800)]
s3: VFS: nfs4_acls. Add missing TALLOC_FREE(frame) in error path.

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

Signed-off-by: Peter Eriksson <pen@lysator.liu.se>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: David Mulder <dmulder@samba.org>
Autobuild-User(master): David Mulder <dmulder@samba.org>
Autobuild-Date(master): Thu Feb 25 20:46:02 UTC 2021 on sn-devel-184

3 years agosamba-tool: Add a gpo command for removing VGP Startup Scripts Group Policy
David Mulder [Tue, 16 Feb 2021 21:12:02 +0000 (14:12 -0700)]
samba-tool: Add a gpo command for removing VGP Startup Scripts Group Policy

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Wed Feb 24 22:01:08 UTC 2021 on sn-devel-184

3 years agosamba-tool: Test gpo manage script startup remove command
David Mulder [Fri, 12 Feb 2021 21:49:16 +0000 (14:49 -0700)]
samba-tool: Test gpo manage script startup remove command

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosamba-tool: Add a gpo command for adding VGP Startup Scripts Group Policy
David Mulder [Fri, 12 Feb 2021 21:13:51 +0000 (14:13 -0700)]
samba-tool: Add a gpo command for adding VGP Startup Scripts Group Policy

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosamba-tool: Test gpo manage script startup add command
David Mulder [Fri, 12 Feb 2021 15:04:30 +0000 (08:04 -0700)]
samba-tool: Test gpo manage script startup add command

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosamba-tool: Add a gpo command for listing VGP Startup Scripts Group Policy
David Mulder [Tue, 9 Feb 2021 13:16:32 +0000 (06:16 -0700)]
samba-tool: Add a gpo command for listing VGP Startup Scripts Group Policy

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosamba-tool: Test gpo manage script startup list command
David Mulder [Mon, 8 Feb 2021 20:08:02 +0000 (13:08 -0700)]
samba-tool: Test gpo manage script startup list command

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agogpo: Apply Group Policy Startup Scripts from VGP
David Mulder [Tue, 2 Feb 2021 19:33:11 +0000 (12:33 -0700)]
gpo: Apply Group Policy Startup Scripts from VGP

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agogpo: Test Group Policy VGP Startup Script Policy
David Mulder [Fri, 29 Jan 2021 20:34:50 +0000 (13:34 -0700)]
gpo: Test Group Policy VGP Startup Script Policy

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agoldb: remove some 'if PY3's in tests
Douglas Bagnall [Thu, 11 Feb 2021 02:50:53 +0000 (15:50 +1300)]
ldb: remove some 'if PY3's in tests

Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: David Mulder <dmulder@suse.com>
Autobuild-User(master): David Mulder <dmulder@samba.org>
Autobuild-Date(master): Mon Feb 22 15:50:55 UTC 2021 on sn-devel-184

3 years agopytest/segfault: fix the rpc.echo test
Douglas Bagnall [Thu, 11 Feb 2021 04:35:59 +0000 (17:35 +1300)]
pytest/segfault: fix the rpc.echo test

Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: David Mulder <dmulder@suse.com>
3 years agopytest/segfaults: drop a useless line
Douglas Bagnall [Thu, 11 Feb 2021 04:35:32 +0000 (17:35 +1300)]
pytest/segfaults: drop a useless line

Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: David Mulder <dmulder@suse.com>
3 years agoselftest: preforkrestartdc doesn't need gdb-backtraces
Douglas Bagnall [Thu, 11 Feb 2021 09:19:31 +0000 (22:19 +1300)]
selftest: preforkrestartdc doesn't need gdb-backtraces

There are tests in this environment that kill processes with SEGV
signals, which causes a backtrace that is entirely spurious from a
debugging point of view.

We can turn that off, saving processor time and moments of developer
confusion.

Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: David Mulder <dmulder@suse.com>
3 years agopytest:segfault: avoid gdb_backtrace on knownfail
Douglas Bagnall [Thu, 11 Feb 2021 09:16:33 +0000 (22:16 +1300)]
pytest:segfault: avoid gdb_backtrace on knownfail

We know that test_net_replicate_init__3() segfaults. It is a knownfail
and we don't need to see the gdb backtrace every time.

This saves nearly two minutes on `make test TESTS=segfault`.

Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: David Mulder <dmulder@suse.com>
3 years agoselftest/gdb_backtrace: add an off switch
Douglas Bagnall [Thu, 11 Feb 2021 04:39:18 +0000 (17:39 +1300)]
selftest/gdb_backtrace: add an off switch

Sometime you know a test is going to crash and produce a LOT of
backtrace, and you already know what it will look like. For those
times you can set

PLEASE_NO_GDB_BACKTRACE=1

and there will be no backtrace, which can save quite a bit of time and
thousands of lines of log file. (In particular, backtraces of Python
programs can take over a minute to complete).

Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: David Mulder <dmulder@suse.com>
3 years agoprinting: use correct error out in get_correct_cversion() when openat_pathref_fsp...
Ralph Boehme [Tue, 16 Feb 2021 13:24:05 +0000 (14:24 +0100)]
printing: use correct error out in get_correct_cversion() when openat_pathref_fsp() fails

Fixes a regression introduced by a74f0af1a91fe0bbc68e4d41d65f43ec383ae8bf: if
there's no existing file, openat_pathref_fsp() will fail with
NT_STATUS_OBJECT_NAME_NOT_FOUND which must be handled the same way it is done by
the SMB_VFS_CREATE_FILE() call below.

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

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
Autobuild-User(master): Günther Deschner <gd@samba.org>
Autobuild-Date(master): Wed Feb 17 19:53:00 UTC 2021 on sn-devel-184

3 years agoprinting: use correct error out in file_version_is_newer() when openat_pathref_fsp...
Ralph Boehme [Tue, 16 Feb 2021 13:23:02 +0000 (14:23 +0100)]
printing: use correct error out in file_version_is_newer() when openat_pathref_fsp() fails

Fixes a regression introduced by ef5e913bca584f0232d5bfff14df4ccba2dda35c: if
there's no existing file, openat_pathref_fsp() will fail with
NT_STATUS_OBJECT_NAME_NOT_FOUND which must be handled the same way it is done by
the SMB_VFS_CREATE_FILE() call below.

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

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
3 years agoprinting: use correct error out in file_version_is_newer() when openat_pathref_fsp...
Ralph Boehme [Tue, 16 Feb 2021 13:19:51 +0000 (14:19 +0100)]
printing: use correct error out in file_version_is_newer() when openat_pathref_fsp() fails

Fixes a regression introduced by cbe25e1777d0c43c21e8acc2cea79fd03fdaf2ea: if
there's no existing file, openat_pathref_fsp() will fail with
NT_STATUS_OBJECT_NAME_NOT_FOUND which must be handled the same way it is done by
the SMB_VFS_CREATE_FILE() call below.

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

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
3 years agosamba-tool: Replace gpo command for removing Sudoers Group Policy
David Mulder [Wed, 23 Dec 2020 15:09:32 +0000 (08:09 -0700)]
samba-tool: Replace gpo command for removing Sudoers Group Policy

Replace it with the VGP command for removing
sudoers entries from an xml file.

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Sun Feb 14 00:53:41 UTC 2021 on sn-devel-184

3 years agosamba-tool: Test gpo manage vgp sudoers remove command
David Mulder [Tue, 22 Dec 2020 22:36:59 +0000 (15:36 -0700)]
samba-tool: Test gpo manage vgp sudoers remove command

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosamba-tool: Replace gpo command for adding Sudoers Group Policy
David Mulder [Tue, 22 Dec 2020 20:34:19 +0000 (13:34 -0700)]
samba-tool: Replace gpo command for adding Sudoers Group Policy

Replace it with the VGP command for adding
sudoers entries in an xml file.

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosamba-tool: Test VGP sudoers add command
David Mulder [Tue, 22 Dec 2020 18:23:34 +0000 (11:23 -0700)]
samba-tool: Test VGP sudoers add command

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosamba-tool: Replace gpo command for listing Sudoers Group Policy
David Mulder [Mon, 21 Dec 2020 21:57:27 +0000 (14:57 -0700)]
samba-tool: Replace gpo command for listing Sudoers Group Policy

Replace it with the VGP command for listing
sudoers entries in an xml file.

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosamba-tool: Test gpo manage vgp sudoers list command
David Mulder [Mon, 21 Dec 2020 20:14:41 +0000 (13:14 -0700)]
samba-tool: Test gpo manage vgp sudoers list command

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agogpo: VGP Sudoers policy must handle group principals
David Mulder [Mon, 21 Dec 2020 23:48:55 +0000 (16:48 -0700)]
gpo: VGP Sudoers policy must handle group principals

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agogpo: Test that VGP Sudoers policy handles group principals
David Mulder [Mon, 21 Dec 2020 23:47:51 +0000 (16:47 -0700)]
gpo: Test that VGP Sudoers policy handles group principals

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agovfs: update status of SMB_VFS_READLINKAT()
Jeremy Allison [Thu, 11 Feb 2021 19:59:06 +0000 (11:59 -0800)]
vfs: update status of SMB_VFS_READLINKAT()

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Noel Power <noel.power@suse.com>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Sat Feb 13 01:19:49 UTC 2021 on sn-devel-184

3 years agos3: smbd: Change smb_unix_read_symlink() to use a real directory fsp for SMB_VFS_READ...
Jeremy Allison [Wed, 10 Feb 2021 22:50:36 +0000 (14:50 -0800)]
s3: smbd: Change smb_unix_read_symlink() to use a real directory fsp for SMB_VFS_READLINKAT().

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Noel Power <noel.power@suse.com>
3 years agos3: smbd: Factor out the SMB1 UNIX extensions read symlink code into a function.
Jeremy Allison [Wed, 10 Feb 2021 21:34:42 +0000 (13:34 -0800)]
s3: smbd: Factor out the SMB1 UNIX extensions read symlink code into a function.

Will make it much easier to convert to a dirfsp later.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Noel Power <noel.power@suse.com>
3 years agos3: VFS: unityed_media: Fix um_readlinkat() to cope with real directory fsps.
Jeremy Allison [Thu, 11 Feb 2021 19:55:16 +0000 (11:55 -0800)]
s3: VFS: unityed_media: Fix um_readlinkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Noel Power <noel.power@suse.com>
3 years agos3: VFS: time_audit: Fix smb_time_audit_readlinkat() to cope with real directory...
Jeremy Allison [Thu, 11 Feb 2021 19:49:24 +0000 (11:49 -0800)]
s3: VFS: time_audit: Fix smb_time_audit_readlinkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Noel Power <noel.power@suse.com>
3 years ago3: VFS: snapper: Fix snapper_gmt_readlinkat() to cope with real directory fsps.
Jeremy Allison [Thu, 11 Feb 2021 19:43:50 +0000 (11:43 -0800)]
3: VFS: snapper: Fix snapper_gmt_readlinkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Noel Power <noel.power@suse.com>
3 years agos3: VFS: shadow_copy2: Fix shadow_copy2_readlinkat() to cope with real directory...
Jeremy Allison [Thu, 11 Feb 2021 19:36:22 +0000 (11:36 -0800)]
s3: VFS: shadow_copy2: Fix shadow_copy2_readlinkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Noel Power <noel.power@suse.com>
3 years agos3: VFS: media_harmony: Fix mh_readlinkat() to cope with real directory fsps.
Jeremy Allison [Thu, 11 Feb 2021 19:05:28 +0000 (11:05 -0800)]
s3: VFS: media_harmony: Fix mh_readlinkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Noel Power <noel.power@suse.com>
3 years agos3: VFS: glusterfs: Fix vfs_gluster_readlinkat() to cope with real directory fsps.
Jeremy Allison [Thu, 11 Feb 2021 19:02:28 +0000 (11:02 -0800)]
s3: VFS: glusterfs: Fix vfs_gluster_readlinkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Noel Power <noel.power@suse.com>
3 years agos3: VFS: full_audit: Fix smb_full_audit_readlinkat() to cope with real directory...
Jeremy Allison [Thu, 11 Feb 2021 18:59:18 +0000 (10:59 -0800)]
s3: VFS: full_audit: Fix smb_full_audit_readlinkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Noel Power <noel.power@suse.com>
3 years agos3: VFS: ceph_snapshots: Fix ceph_snap_gmt_readlinkat() to cope with real directory...
Jeremy Allison [Thu, 11 Feb 2021 17:54:52 +0000 (09:54 -0800)]
s3: VFS: ceph_snapshots: Fix ceph_snap_gmt_readlinkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Noel Power <noel.power@suse.com>
3 years agos3: VFS: ceph: Fix cephwrap_readlinkat() to cope with real directory fsps.
Jeremy Allison [Thu, 11 Feb 2021 17:26:15 +0000 (09:26 -0800)]
s3: VFS: ceph: Fix cephwrap_readlinkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Noel Power <noel.power@suse.com>
3 years agos3: VFS: cap: Fix cap_readlinkat() to cope with real directory fsps.
Jeremy Allison [Thu, 11 Feb 2021 17:21:41 +0000 (09:21 -0800)]
s3: VFS: cap: Fix cap_readlinkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Noel Power <noel.power@suse.com>
3 years agos3: VFS: expand_msdfs: Since we moved to SMB_VFS_READ_DFS_PATHAT() this module has...
Jeremy Allison [Thu, 11 Feb 2021 18:52:47 +0000 (10:52 -0800)]
s3: VFS: expand_msdfs: Since we moved to SMB_VFS_READ_DFS_PATHAT() this module has looked at the wrong function.

Fix it to work as a redirection of SMB_VFS_READ_DFS_PATHAT()
instead of SMB_VFS_READLINKAT().

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Noel Power <noel.power@suse.com>
3 years agonsswitch pam_winbind: Fix clang compilation error
Gary Lockyer [Wed, 10 Feb 2021 19:59:55 +0000 (08:59 +1300)]
nsswitch pam_winbind: Fix clang compilation error

Fix clang compilation error:
   error: format string is not a string literal [-Werror,-Wformat-nonliteral]

Signed-off-by: Gary Lockyer <gary@catalyst.net.nz>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Fri Feb 12 00:10:50 UTC 2021 on sn-devel-184

3 years agogpo: Security gpext rsop list only own policies
David Mulder [Tue, 15 Dec 2020 19:48:30 +0000 (12:48 -0700)]
gpo: Security gpext rsop list only own policies

The rsop should only list the policies from
that extension, not from all policies in the
same file.

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Thu Feb 11 18:28:09 UTC 2021 on sn-devel-184

3 years agogpo: Test that Security gpext rsop lists only own policies
David Mulder [Tue, 9 Feb 2021 19:58:49 +0000 (12:58 -0700)]
gpo: Test that Security gpext rsop lists only own policies

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agogpo: Ensure empty Security sections are removed
David Mulder [Fri, 11 Dec 2020 17:38:32 +0000 (10:38 -0700)]
gpo: Ensure empty Security sections are removed

Failing to remove the empty section causes tests
to fail, and is also just bad practice.

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agogpo: Test that empty Security sections are removed
David Mulder [Tue, 9 Feb 2021 18:06:40 +0000 (11:06 -0700)]
gpo: Test that empty Security sections are removed

Ensure that empty sections are removed when
calling samba-tool gpo manage security set.

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agos3:registry Renaming get_charset() to smbreg_get_charset()
xzhao9 [Sun, 3 Jan 2021 18:02:18 +0000 (13:02 -0500)]
s3:registry Renaming get_charset() to smbreg_get_charset()

Rename to smbreg_get_charset() function to avoid naming conflict
with MariaDB.

Signed-off-by: xzhao9 <i@xuzhao.net>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: David Mulder <dmulder@suse.com>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Wed Feb 10 21:00:28 UTC 2021 on sn-devel-184

3 years agoclassicupgrade: treat old never expires value right
Björn Jacke [Fri, 5 Feb 2021 11:47:01 +0000 (12:47 +0100)]
classicupgrade: treat old never expires value right

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

Signed-off-by: Bjoern Jacke <bjacke@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Wed Feb 10 15:06:49 UTC 2021 on sn-devel-184

3 years agos3:pysmbd: fix fd leak in py_smbd_create_file()
Stefan Metzmacher [Tue, 9 Feb 2021 12:48:36 +0000 (13:48 +0100)]
s3:pysmbd: fix fd leak in py_smbd_create_file()

Various 'samba-tool domain backup' commands use this and will
fail if there's over ~1000 files in the sysvol folder.

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

Signed-off-by: Stefan Metzmacher <metze@samba.org>
3 years agothird_party: Update socket_wrapper to version 1.3.2
Stefan Metzmacher [Tue, 9 Feb 2021 07:56:42 +0000 (08:56 +0100)]
third_party: Update socket_wrapper to version 1.3.2

This brings support for fd-passing of INET sockets.

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

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
3 years agoselftest/gdb_backtrace: use 'unset LD_PRELOAD'
Stefan Metzmacher [Tue, 9 Feb 2021 15:22:37 +0000 (16:22 +0100)]
selftest/gdb_backtrace: use 'unset LD_PRELOAD'

We may have bugs in socket_wrapper and others, we don't want
to inject these bugs into the debugger.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
3 years agoexamples/fuse/smb2mount: fix compiler warning on ubuntu20.04 with -O3
Stefan Metzmacher [Wed, 3 Feb 2021 16:55:14 +0000 (17:55 +0100)]
examples/fuse/smb2mount: fix compiler warning on ubuntu20.04 with -O3

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
3 years agosamba-tool: Add a gpo command for setting VGP OpenSSH Group Policy
David Mulder [Wed, 23 Dec 2020 21:52:35 +0000 (14:52 -0700)]
samba-tool: Add a gpo command for setting VGP OpenSSH Group Policy

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Tue Feb  9 21:24:14 UTC 2021 on sn-devel-184

3 years agosamba-tool: Test gpo manage openssh set command
David Mulder [Wed, 23 Dec 2020 21:29:58 +0000 (14:29 -0700)]
samba-tool: Test gpo manage openssh set command

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosamba-tool: Add a gpo command for listing VGP OpenSSH Group Policy
David Mulder [Wed, 23 Dec 2020 21:14:49 +0000 (14:14 -0700)]
samba-tool: Add a gpo command for listing VGP OpenSSH Group Policy

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosamba-tool: Test gpo manage openssh list command
David Mulder [Wed, 23 Dec 2020 19:25:11 +0000 (12:25 -0700)]
samba-tool: Test gpo manage openssh list command

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agogpo: Apply Group Policy OpenSSH settings from VGP
David Mulder [Thu, 5 Nov 2020 16:08:26 +0000 (09:08 -0700)]
gpo: Apply Group Policy OpenSSH settings from VGP

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agogpo: Test Group Policy OpenSSH for VGP
David Mulder [Wed, 4 Nov 2020 17:24:26 +0000 (10:24 -0700)]
gpo: Test Group Policy OpenSSH for VGP

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agos3 lib system: Change signature of sys_proc_fd_path
Gary Lockyer [Tue, 9 Feb 2021 01:07:53 +0000 (14:07 +1300)]
s3 lib system: Change signature of sys_proc_fd_path

It's always called with sizeof(buf)

Signed-off-by: Gary Lockyer <gary@catalyst.net.nz>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Tue Feb  9 04:16:43 UTC 2021 on sn-devel-184

3 years agos3 lib system: Fix clang compilation error
Gary Lockyer [Mon, 8 Feb 2021 20:06:12 +0000 (09:06 +1300)]
s3 lib system: Fix clang compilation error

Fix clang compilation error:
   error: format string is not a string literal [-Werror,-Wformat-nonliteral]

Signed-off-by: Gary Lockyer <gary@catalyst.net.nz>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agoHEIMDAL: krb5_storage_free(NULL) should work
Paul Wise [Mon, 29 Feb 2016 17:58:45 +0000 (11:58 -0600)]
HEIMDAL: krb5_storage_free(NULL) should work

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

Signed-off-by: Paul Wise <pabs3@bonedaddy.net>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Original-author: Nicolas Williams <nico@twosigma.com>
(cherry-picked from heimdal commit b3db07d5f0e03f6a1a0a392e70f9675e19a6d6af)

3 years agos3:testparm: Warn about 'server schannel = no'
Andreas Schneider [Mon, 8 Feb 2021 08:48:16 +0000 (09:48 +0100)]
s3:testparm: Warn about 'server schannel = no'

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Tue Feb  9 03:08:42 UTC 2021 on sn-devel-184

3 years agopam_winbind: improve pam message if minimum password age strikes
Björn Jacke [Wed, 27 Jan 2021 20:14:43 +0000 (21:14 +0100)]
pam_winbind: improve pam message if minimum password age strikes

if minimum password age strikes we should output the next possible password
change time and not other password restriction policies.

Signed-off-by: Bjoern Jacke <bjacke@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
3 years agovfs: update status of SMB_VFS_LINKAT()
Jeremy Allison [Tue, 19 Jan 2021 20:58:09 +0000 (12:58 -0800)]
vfs: update status of SMB_VFS_LINKAT()

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Böhme <slow@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Tue Feb  9 01:15:58 UTC 2021 on sn-devel-184

3 years agos3: smbd: Change hardlink_internals() to use a real directory fsp for SMB_VFS_LINKAT().
Jeremy Allison [Tue, 19 Jan 2021 20:57:51 +0000 (12:57 -0800)]
s3: smbd: Change hardlink_internals() to use a real directory fsp for SMB_VFS_LINKAT().

New VFS change.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Böhme <slow@samba.org>
3 years agos3: smbd: Centralize error exits to an 'out' label in hardlink_internals().
Jeremy Allison [Tue, 19 Jan 2021 20:49:40 +0000 (12:49 -0800)]
s3: smbd: Centralize error exits to an 'out' label in hardlink_internals().

Makes it easier to add TALLOC_FREE's that are always called.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Böhme <slow@samba.org>
3 years agos3: VFS: syncops: Fix syncops_linkat() to cope with real directory fsps.
Jeremy Allison [Fri, 5 Feb 2021 22:19:21 +0000 (14:19 -0800)]
s3: VFS: syncops: Fix syncops_linkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Böhme <slow@samba.org>
3 years agos3: VFS: unityed_media: Fix um_linkat() to cope with real directory fsps.
Jeremy Allison [Wed, 3 Feb 2021 22:45:36 +0000 (14:45 -0800)]
s3: VFS: unityed_media: Fix um_linkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Böhme <slow@samba.org>
3 years agos3: VFS: time_audit: Fix smb_time_audit_linkat() to cope with real directory fsps.
Jeremy Allison [Wed, 3 Feb 2021 21:59:00 +0000 (13:59 -0800)]
s3: VFS: time_audit: Fix smb_time_audit_linkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Böhme <slow@samba.org>
3 years agos3: VFS: media_harmony: Fix mh_linkat() to cope with real directory fsps.
Jeremy Allison [Wed, 3 Feb 2021 20:36:27 +0000 (12:36 -0800)]
s3: VFS: media_harmony: Fix mh_linkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Böhme <slow@samba.org>
3 years agos3: VFS: full_audit: Fix smb_full_audit_linkat() to cope with real directory fsps.
Jeremy Allison [Mon, 1 Feb 2021 21:08:46 +0000 (13:08 -0800)]
s3: VFS: full_audit: Fix smb_full_audit_linkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Böhme <slow@samba.org>
3 years agos3: VFS: gluster: Fix vfs_gluster_linkat() to cope with real directory fsps.
Jeremy Allison [Tue, 19 Jan 2021 19:54:51 +0000 (11:54 -0800)]
s3: VFS: gluster: Fix vfs_gluster_linkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Böhme <slow@samba.org>
3 years agos3: VFS: ceph: Fix cephwrap_linkat() to cope with real directory fsps.
Jeremy Allison [Tue, 19 Jan 2021 19:04:12 +0000 (11:04 -0800)]
s3: VFS: ceph: Fix cephwrap_linkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Böhme <slow@samba.org>
3 years agos3: VFS: cap: Fix cap_linkat() to cope with real directory fsps.
Jeremy Allison [Mon, 1 Feb 2021 21:04:34 +0000 (13:04 -0800)]
s3: VFS: cap: Fix cap_linkat() to cope with real directory fsps.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Böhme <slow@samba.org>
3 years agoRevert "VFS: shadow_copy2: Fixup shadow_copy2_mknodat() to correctly use the dirfsp...
Jeremy Allison [Wed, 3 Feb 2021 21:55:12 +0000 (13:55 -0800)]
Revert "VFS: shadow_copy2: Fixup shadow_copy2_mknodat() to correctly use the dirfsp path."

This isn't needed as the existing code will refuse a new name with
a non-zero twp in the target name.

This reverts commit 2f74056a916aef9925cae76016378b993560e22b.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Böhme <slow@samba.org>
3 years agoRevert "VFS: shadow_copy2: Fixup shadow_copy2_symlinkat() to correctly use the dirfsp...
Jeremy Allison [Wed, 3 Feb 2021 21:52:33 +0000 (13:52 -0800)]
Revert "VFS: shadow_copy2: Fixup shadow_copy2_symlinkat() to correctly use the dirfsp path."

This isn't needed as the existing code will refuse a new name with
a non-zero twp in the target name.

This reverts commit ec27c4c44d1e9035639e033689fa739518f17132.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Böhme <slow@samba.org>
3 years agosamba-tool: Add a gpo command for removing VGP Files Group Policy
David Mulder [Thu, 28 Jan 2021 16:21:42 +0000 (09:21 -0700)]
samba-tool: Add a gpo command for removing VGP Files Group Policy

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Mon Feb  8 23:36:57 UTC 2021 on sn-devel-184

3 years agosamba-tool: Test gpo manage files remove command
David Mulder [Wed, 27 Jan 2021 21:05:29 +0000 (14:05 -0700)]
samba-tool: Test gpo manage files remove command

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosamba-tool: Add a gpo command for adding VGP Files Group Policy
David Mulder [Wed, 27 Jan 2021 20:21:32 +0000 (13:21 -0700)]
samba-tool: Add a gpo command for adding VGP Files Group Policy

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosamba-tool: Test gpo manage files add command
David Mulder [Tue, 26 Jan 2021 20:43:43 +0000 (13:43 -0700)]
samba-tool: Test gpo manage files add command

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosamba-tool: Add a gpo command for listing VGP Files Group Policy
David Mulder [Tue, 26 Jan 2021 17:46:27 +0000 (10:46 -0700)]
samba-tool: Add a gpo command for listing VGP Files Group Policy

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosamba-tool: Test gpo manage files list command
David Mulder [Tue, 26 Jan 2021 17:07:18 +0000 (10:07 -0700)]
samba-tool: Test gpo manage files list command

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agogpo: Apply Group Policy Files Policy from VGP
David Mulder [Mon, 25 Jan 2021 15:13:18 +0000 (08:13 -0700)]
gpo: Apply Group Policy Files Policy from VGP

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agogpo: Test Group Policy VGP Files Policy
David Mulder [Fri, 22 Jan 2021 17:09:55 +0000 (10:09 -0700)]
gpo: Test Group Policy VGP Files Policy

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agoctdb-tests: Actually wait for record to migrate to lmaster node
Martin Schwenke [Tue, 2 Feb 2021 01:45:04 +0000 (12:45 +1100)]
ctdb-tests: Actually wait for record to migrate to lmaster node

This test has been failing with:

  Wait until record is migrated to lmaster node 0
  <30|BAD: node 0 is not dmaster
  dmaster: 1
  rsn: 8
  flags: 0x00010000 MIGRATED_WITH_DATA
  data(6) = "value1"
  *** TEST COMPLETED (RC=1) AT 2021-02-02 06:18:48, CLEANING UP...

This should never happen.  If this really fails then the wait should
time out.

The problem is that wait_until() does:

  "$@" || _rc=$?

and vacuum_test_key_dmaster() currently calls ctdb_test_fail() on
failure, which causes the shell to exit.  Instead, pass a variant to
wait_until() that simply returns the correct status instead of
exiting.

An alternative would be to change the statement in wait_until() to do:

  ("$@") || _rc=$?

so it captures the exit.  However, this is a global change and
requires more thought.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosmbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from call_trans2findfirst()
Ralph Boehme [Tue, 2 Feb 2021 15:01:19 +0000 (16:01 +0100)]
smbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from call_trans2findfirst()

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Ralph Böhme <slow@samba.org>
Autobuild-Date(master): Fri Feb  5 07:26:44 UTC 2021 on sn-devel-184

3 years agosmbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from copy_file()
Ralph Boehme [Tue, 2 Feb 2021 15:00:32 +0000 (16:00 +0100)]
smbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from copy_file()

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosmbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from copy_file()
Ralph Boehme [Tue, 2 Feb 2021 14:58:57 +0000 (15:58 +0100)]
smbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from copy_file()

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosmbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from rename_internals()
Ralph Boehme [Tue, 2 Feb 2021 14:58:42 +0000 (15:58 +0100)]
smbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from rename_internals()

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosmbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from rename_internals()
Ralph Boehme [Tue, 2 Feb 2021 14:58:30 +0000 (15:58 +0100)]
smbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from rename_internals()

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosmbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from reply_search()
Ralph Boehme [Tue, 2 Feb 2021 14:57:26 +0000 (15:57 +0100)]
smbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from reply_search()

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosmbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from create_file_unixpath()
Ralph Boehme [Tue, 2 Feb 2021 14:57:09 +0000 (15:57 +0100)]
smbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from create_file_unixpath()

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosmbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from open_streams_for_del...
Ralph Boehme [Tue, 2 Feb 2021 14:56:44 +0000 (15:56 +0100)]
smbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from open_streams_for_delete()

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosmbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from parent_pathref()
Ralph Boehme [Tue, 2 Feb 2021 14:56:26 +0000 (15:56 +0100)]
smbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from parent_pathref()

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
3 years agosmbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from synthetic_pathref()
Ralph Boehme [Tue, 2 Feb 2021 14:56:16 +0000 (15:56 +0100)]
smbd: remove NT_STATUS_STOPPED_ON_SYMLINK status code check from synthetic_pathref()

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>