1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-05 09:18:06 +03:00
Commit Graph

102773 Commits

Author SHA1 Message Date
Karolin Seeger
89edb76883 VERSION: Disable GIT_SNAPSHOTS for the 4.4.16 release.
Signed-off-by: Karolin Seeger <kseeger@samba.org>
2017-09-13 09:35:53 -07:00
Karolin Seeger
2ef4251057 WHATSNEW: Add release notes for Samba 4.4.16.
Signed-off-by: Karolin Seeger <kseeger@samba.org>
2017-09-13 09:35:47 -07:00
Jeremy Allison
bf85c3d4ed CVE-2017-12163: s3:smbd: Prevent client short SMB1 write from writing server memory to file.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=13020

Signed-off-by: Jeremy Allison <jra@samba.org>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
2017-09-13 09:19:49 -07:00
Stefan Metzmacher
50f649e7d0 CVE-2017-12151: s3:libsmb: make use of cli_state_is_encryption_on()
This will keep enforced encryption across dfs referrals.

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

Signed-off-by: Stefan Metzmacher <metze@samba.org>
2017-09-13 09:19:49 -07:00
Stefan Metzmacher
17019aa27f CVE-2017-12151: s3:libsmb: add cli_state_is_encryption_on() helper function
This allows to check if the current cli_state uses encryption
(either via unix extentions or via SMB3).

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

Signed-off-by: Stefan Metzmacher <metze@samba.org>
2017-09-13 09:19:49 -07:00
Stefan Metzmacher
81f1804d45 CVE-2017-12150: s3:libsmb: only fallback to anonymous if authentication was not requested
With forced encryption or required signing we should also don't fallback.

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

Signed-off-by: Stefan Metzmacher <metze@samba.org>
2017-09-13 09:19:49 -07:00
Stefan Metzmacher
4a91f4ab82 CVE-2017-12150: libcli/smb: add smbXcli_conn_signing_mandatory()
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12997

Signed-off-by: Stefan Metzmacher <metze@samba.org>
2017-09-13 09:19:48 -07:00
Stefan Metzmacher
b063223097 CVE-2017-12150: auth/credentials: cli_credentials_authentication_requested() should check for NTLM_CCACHE/SIGN/SEAL
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12997

Signed-off-by: Stefan Metzmacher <metze@samba.org>
2017-09-13 09:19:48 -07:00
Stefan Metzmacher
95f6e5b574 CVE-2017-12150: libgpo: make use of SMB_SIGNING_REQUIRED in gpo_connect_server()
It's important that we use a signed connection to get the GPOs!

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

Signed-off-by: Stefan Metzmacher <metze@samba.org>
2017-09-13 09:19:48 -07:00
Stefan Metzmacher
26b87d01b0 CVE-2017-12150: s3:pylibsmb: make use of SMB_SIGNING_DEFAULT for 'samba.samba3.libsmb_samba_internal'
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12997

Signed-off-by: Stefan Metzmacher <metze@samba.org>
2017-09-13 09:19:48 -07:00
Stefan Metzmacher
428ede3dd3 CVE-2017-12150: s3:lib: get_cmdline_auth_info_signing_state smb_encrypt SMB_SIGNING_REQUIRED
This is an addition to the fixes for CVE-2015-5296.

It applies to smb2mount -e, smbcacls -e and smbcquotas -e.

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

Signed-off-by: Stefan Metzmacher <metze@samba.org>
2017-09-13 09:19:48 -07:00
Karolin Seeger
084bf9870b VERSION: Bump version up to 4.5.16...
and re-enable GIT_SNAPSHOTS.

Signed-off-by: Karolin Seeger <kseeger@samba.org>
2017-09-13 09:19:48 -07:00
Jeremy Allison
189a71748c s3: smbd: Fix a read after free if a chained SMB1 call goes async.
Reported to the Samba Team by Yihan Lian <lianyihan@360.cn>, a security
researcher of Qihoo 360 GearTeam. Thanks a lot!

smb1_parse_chain() incorrectly used talloc_tos() for the memory
context of the chained smb1 requests. This gets freed between
requests so if a chained request goes async, the saved request
array also is freed, which causes a crash on resume.

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

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
(cherry picked from commit 5fe76a5474)

Autobuild-User(v4-4-test): Karolin Seeger <kseeger@samba.org>
Autobuild-Date(v4-4-test): Tue Jul 25 01:31:58 CEST 2017 on sn-devel-144
2017-07-25 01:31:58 +02:00
Ralph Boehme
9ff57c8760 s3/smbd: let non_widelink_open() chdir() to directories directly
If the caller passes O_DIRECTORY we just try to chdir() to smb_fname
directly, not to the parent directory.

The security check in check_reduced_name() will continue to work, but
this fixes the case of an open() for a previous version of a
subdirectory that contains snapshopt.

Eg:

[share]
    path = /shares/test
    vfs objects = shadow_copy2
    shadow:snapdir = .snapshots
    shadow:snapdirseverywhere = yes

Directory tree with fake snapshots:

$ tree -a /shares/test/
/shares/test/
├── dir
│   ├── file
│   └── .snapshots
│       └── @GMT-2017.07.04-04.30.12
│           └── file
├── dir2
│   └── file
├── file
├── .snapshots
│   └── @GMT-2001.01.01-00.00.00
│       ├── dir2
│       │   └── file
│       └── file
└── testfsctl.dat

./bin/smbclient -U slow%x //localhost/share -c 'ls @GMT-2017.07.04-04.30.12/dir/*'
NT_STATUS_OBJECT_NAME_NOT_FOUND listing \@GMT-2017.07.04-04.30.12\dir\*

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

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit b886a9443d)

Autobuild-User(v4-4-test): Karolin Seeger <kseeger@samba.org>
Autobuild-Date(v4-4-test): Mon Jul 24 04:25:45 CEST 2017 on sn-devel-144
2017-07-24 04:25:45 +02:00
Bob Campbell
9fb0aa56ba VERSION: Release Samba 4.4.15 for CVE-2017-11103
Signed-off-by: Bob Campbell <bobcampbell@catalyst.net.nz>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
2017-07-12 11:03:39 +02:00
Bob Campbell
d80bf4429b WHATSNEW: Add release notes for Samba 4.4.15
Signed-off-by: Bob Campbell <bobcampbell@catalyst.net.nz>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
2017-07-12 10:59:31 +02:00
Jeffrey Altman
fd4c30bf52 CVE-2017-11103: Orpheus' Lyre KDC-REP service name validation
In _krb5_extract_ticket() the KDC-REP service name must be obtained from
encrypted version stored in 'enc_part' instead of the unencrypted version
stored in 'ticket'.  Use of the unecrypted version provides an
opportunity for successful server impersonation and other attacks.

Identified by Jeffrey Altman, Viktor Duchovni and Nico Williams.

Change-Id: I45ef61e8a46e0f6588d64b5bd572a24c7432547c

BUG: https://bugzilla.samba.org/show_bug.cgi?id=12894
(based on heimdal commit 6dd3eb836bbb80a00ffced4ad57077a1cdf227ea)

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2017-07-12 10:58:11 +02:00
Stefan Metzmacher
c8dea6522d Revert "s3: locking: Move two leases functions into a new file."
This reverts commit 419f5cca88.

This should not have been in 4-4-test, see
https://bugzilla.samba.org/show_bug.cgi?id=12628#c6
v4-4-test is in the security fixes only mode.

This also introduces a regression that's fixed in v4-5 and higer only,
see https://bugzilla.samba.org/show_bug.cgi?id=12798

Signed-off-by: Stefan Metzmacher <metze@samba.org>
2017-07-12 08:50:47 +02:00
Stefan Metzmacher
8d23e3321d Revert "s3: locking: Update oplock optimization for the leases era !"
This reverts commit 2e00feb278.

This should not have been in 4-4-test, see
https://bugzilla.samba.org/show_bug.cgi?id=12628#c6
v4-4-test is in the security fixes only mode.

This also introduces a regression that's fixed in v4-5 and higer only,
see https://bugzilla.samba.org/show_bug.cgi?id=12798

Signed-off-by: Stefan Metzmacher <metze@samba.org>
2017-07-12 08:50:24 +02:00
Karolin Seeger
a709729657 VERSION: Bump version up to 4.4.15.
Signed-off-by: Karolin Seeger <kseeger@samba.org>
2017-05-24 10:05:04 +02:00
Karolin Seeger
63684f6760 samba: tag release samba-4.4.14
-----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iD8DBQBZI+8lbzORW2Vot+oRAo6qAKC1lCFeHpKBrlX2WwmehlJJXShW8gCdF0k3
 ztiU59sAVXnDmdna97ULwRM=
 =Inff
 -----END PGP SIGNATURE-----

Merge tag 'samba-4.4.14' into v4-4-test

samba: tag release samba-4.4.14
2017-05-24 10:04:01 +02:00
Karolin Seeger
f0ec0c2c00 VERSION: Disable GIT_SNAPSHOT for the 4.4.14 release.
Signed-off-by: Karolin Seeger <kseeger@samba.org>
2017-05-23 10:11:18 +02:00
Karolin Seeger
75ec364ad9 WHATSNEW: Add release notes for Samba 4.4.14.
Signed-off-by: Karolin Seeger <kseeger@samba.org>
2017-05-23 10:11:14 +02:00
Volker Lendecke
279f4afc4a CVE-2017-7494: rpc_server3: Refuse to open pipe names with / inside
Bug: https://bugzilla.samba.org/show_bug.cgi?id=12780

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2017-05-19 10:24:25 +02:00
Karolin Seeger
59b2ef18cb VERSION: Re-enable GIT_SNAPSHOTS.
Signed-off-by: Karolin Seeger <kseeger@samba.org>
2017-05-19 10:24:24 +02:00
Karolin Seeger
3b6576da6b VERSION: Bump version up to 4.4.14.
Signed-off-by: Karolin Seeger <kseeger@samba.org>
(cherry picked from commit dea3200714)
2017-05-19 09:47:52 +02:00
Karolin Seeger
dea3200714 VERSION: Bump version up to 4.4.14.
Signed-off-by: Karolin Seeger <kseeger@samba.org>
2017-03-31 10:14:38 +02:00
Karolin Seeger
4a63ccda03 samba: tag release samba-4.4.13
-----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iD8DBQBY3fUrbzORW2Vot+oRAiBMAKCps2eH4Uq8bVlHYvx4vT3oZ+khagCffBtx
 jR3RIdqs+LrckT4z6f3DJQE=
 =AZ0w
 -----END PGP SIGNATURE-----

Merge tag 'samba-4.4.13' into v4-4-test

samba: tag release samba-4.4.13
2017-03-31 10:12:52 +02:00
Karolin Seeger
f4f7952b70 VERSION: Disable GIT_SNAPSHOTS for the 4.4.13 release.
Signed-off-by: Karolin Seeger <kseeger@samba.org>
2017-03-31 08:18:52 +02:00
Karolin Seeger
cc9aec72f5 WHATSNEW: Add release notes for Samba 4.4.13.
Signed-off-by: Karolin Seeger <kseeger@samba.org>
2017-03-31 08:18:30 +02:00
Jeremy Allison
818fb1a39c s3: Test for CVE-2017-2619 regression with "follow symlinks = no" - part 2
Add tests for regular access.

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

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

Autobuild-User(master): Ralph Böhme <slow@samba.org>
Autobuild-Date(master): Tue Mar 28 17:05:27 CEST 2017 on sn-devel-144

(cherry picked from commit 4e734fcd1b)
2017-03-31 08:18:30 +02:00
Jeremy Allison
80b8fa0220 s3: smbd: Fix "follow symlink = no" regression part 2.
Use the cwd_name parameter to reconstruct the original
client name for symlink testing.

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

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
(cherry picked from commit e182a4d39e)
2017-03-31 08:18:30 +02:00
Jeremy Allison
de57712c46 s3: smbd: Fix "follow symlink = no" regression part 2.
Add an extra paramter to cwd_name to check_reduced_name().

If cwd_name == NULL then fname is a client given path relative
to the root path of the share.

If cwd_name != NULL then fname is a client given path relative
to cwd_name. cwd_name is relative to the root path of the share.

Not yet used, logic added in the next commit.

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

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
(cherry picked from commit 83e30cb488)
2017-03-31 08:18:29 +02:00
Jeremy Allison
ed50b9f43a s3: Fixup test for CVE-2017-2619 regression with "follow symlinks = no"
Use correct bash operators (not string operators).
Add missing "return".

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

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
(cherry picked from commit 037297a1c5)
2017-03-31 08:18:29 +02:00
Jeremy Allison
75df72a0b6 s3: Test for CVE-2017-2619 regression with "follow symlinks = no".
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12721

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

Back-ported from commit 782172a9be
2017-03-31 08:18:29 +02:00
Jeremy Allison
aff09ec04e s3: smbd: Fix incorrect logic exposed by fix for the security bug 12496 (CVE-2017-2619).
In a UNIX filesystem, the names "." and ".." by definition can *never*
be symlinks - they are already reserved names.

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

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Uri Simchoni <uri@samba.org>
(cherry picked from commit ae17bebd25)
2017-03-31 08:18:29 +02:00
Karolin Seeger
452d0dd843 VERSION: Re-enable GIT_SNAPSHOTS.
Signed-off-by: Karolin Seeger <kseeger@samba.org>
2017-03-31 08:18:29 +02:00
Jeremy Allison
0839f6c6f4 s3: Test for CVE-2017-2619 regression with "follow symlinks = no" - part 2
Add tests for regular access.

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

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

Autobuild-User(master): Ralph Böhme <slow@samba.org>
Autobuild-Date(master): Tue Mar 28 17:05:27 CEST 2017 on sn-devel-144

(cherry picked from commit 4e734fcd1b)

Autobuild-User(v4-4-test): Karolin Seeger <kseeger@samba.org>
Autobuild-Date(v4-4-test): Wed Mar 29 13:57:56 CEST 2017 on sn-devel-144
2017-03-29 13:57:56 +02:00
Karolin Seeger
e2df6aa8ba VERSION: Bump version up to 4.4.13.
Signed-off-by: Karolin Seeger <kseeger@samba.org>
(cherry picked from commit 7086fb6a4d)
2017-03-29 11:01:56 +02:00
Jeremy Allison
ed694d0680 s3: smbd: Fix "follow symlink = no" regression part 2.
Use the cwd_name parameter to reconstruct the original
client name for symlink testing.

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

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
(cherry picked from commit e182a4d39e)
2017-03-29 10:24:14 +02:00
Jeremy Allison
8e3e969eed s3: smbd: Fix "follow symlink = no" regression part 2.
Add an extra paramter to cwd_name to check_reduced_name().

If cwd_name == NULL then fname is a client given path relative
to the root path of the share.

If cwd_name != NULL then fname is a client given path relative
to cwd_name. cwd_name is relative to the root path of the share.

Not yet used, logic added in the next commit.

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

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
(cherry picked from commit 83e30cb488)
2017-03-29 10:24:14 +02:00
Jeremy Allison
9a5be8b68b s3: Fixup test for CVE-2017-2619 regression with "follow symlinks = no"
Use correct bash operators (not string operators).
Add missing "return".

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

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
(cherry picked from commit 037297a1c5)
2017-03-29 10:24:14 +02:00
Jeremy Allison
161a078f55 s3: Test for CVE-2017-2619 regression with "follow symlinks = no".
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12721

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

Back-ported from commit 782172a9be
2017-03-29 10:24:14 +02:00
Jeremy Allison
4a6d828e8f s3: smbd: Fix incorrect logic exposed by fix for the security bug 12496 (CVE-2017-2619).
In a UNIX filesystem, the names "." and ".." by definition can *never*
be symlinks - they are already reserved names.

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

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Uri Simchoni <uri@samba.org>
(cherry picked from commit ae17bebd25)
2017-03-29 10:24:14 +02:00
Jeremy Allison
2e00feb278 s3: locking: Update oplock optimization for the leases era !
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12628

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

Autobuild-User(master): Ralph Böhme <slow@samba.org>
Autobuild-Date(master): Wed Mar 15 20:04:32 CET 2017 on sn-devel-144

(cherry picked from commit 1c4b15aa5f)

Autobuild-User(v4-4-test): Karolin Seeger <kseeger@samba.org>
Autobuild-Date(v4-4-test): Fri Mar 24 12:35:06 CET 2017 on sn-devel-144
2017-03-24 12:35:06 +01:00
Jeremy Allison
419f5cca88 s3: locking: Move two leases functions into a new file.
map_oplock_to_lease_type(), fsp_lease_type().

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

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
(back ported from commit 125c78ad0b)
2017-03-24 08:54:23 +01:00
Karolin Seeger
7086fb6a4d VERSION: Bump version up to 4.4.13.
Signed-off-by: Karolin Seeger <kseeger@samba.org>
2017-03-23 10:19:07 +01:00
Karolin Seeger
f2ae4c7984 samba: tag release samba-4.4.12
-----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iD8DBQBY04N8bzORW2Vot+oRAtYcAJ0fK71YTWsyyBXyM/dWJ6lQi8XQnACeOZum
 JRlcRLhXCnNXZ47zSDHwTMU=
 =ag2T
 -----END PGP SIGNATURE-----

Merge tag 'samba-4.4.12' into v4-4-test

samba: tag release samba-4.4.12
2017-03-23 10:18:52 +01:00
Karolin Seeger
3f2864eb85 VERSION: Disable GIT_SNAPSHOTS for the 4.4.12 release
CVE-2017-2619: Symlink race allows access outside share definition.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12496

Signed-off-by: Karolin Seeger <kseeger@samba.org>
2017-03-23 09:11:40 +01:00
Karolin Seeger
df1ea2b051 WHATSNEW: Add release notes for Samba 4.4.12.
CVE-2017-2619: Symlink race allows access outside share definition.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12496

Signed-off-by: Karolin Seeger <kseeger@samba.org>
2017-03-23 09:11:34 +01:00