As per upstream advisory: All versions of Samba prior to 4.6.1, 4.5.7, 4.4.11 are vulnerable to a malicious client using a symlink race to allow access to areas of the server file system not exported under the share definition. Samba uses the realpath() system call to ensure when a client requests access to a pathname that it is under the exported share path on the server file system. Clients that have write access to the exported part of the file system via SMB1 unix extensions or NFS to create symlinks can race the server by renaming a realpath() checked path and then creating a symlink. If the client wins the race it can cause the server to access the new symlink target after the exported share path check has been done. This new symlink target can point to anywhere on the server file system. This is a difficult race to win, but theoretically possible. Note that the proof of concept code supplied wins the race reliably only when the server is slowed down using the strace utility running on the server. Exploitation of this bug has not been seen in the wild. Mitigation: Add the parameter: unix extensions = no to the [global] section of your smb.conf and restart smbd. This prevents SMB1 clients from creating symlinks on the exported file system using SMB1. However, if the same region of the file system is also exported using NFS, NFS clients can create symlinks that potentially can also hit the race condition. For non-patched versions of Samba we recommend only exporting areas of the file system by either SMB or NFS, not both. Acknowledgements: Name: the Samba project Upstream: Jann Horn (Google)
Created samba tracking bugs for this issue: Affects: fedora-all [bug 1435156]
External References: https://www.samba.org/samba/security/CVE-2017-2619.html
This issue has been addressed in the following products: Red Hat Enterprise Linux 7 Via RHSA-2017:1265 https://access.redhat.com/errata/RHSA-2017:1265
This issue has been addressed in the following products: Red Hat Gluster Storage 3.2 for RHEL 7 Via RHSA-2017:2338 https://access.redhat.com/errata/RHSA-2017:2338
This issue has been addressed in the following products: Red Hat Gluster Storage 3.3 for RHEL 6 Via RHSA-2017:2778 https://access.redhat.com/errata/RHSA-2017:2778
This issue has been addressed in the following products: Red Hat Enterprise Linux 6 Via RHSA-2017:2789 https://access.redhat.com/errata/RHSA-2017:2789
This has caused two regressions: 1. When using "follow symlinks = no", all directories below the top level appear empty. https://bugzilla.redhat.com/show_bug.cgi?id=1495148 (dupe describing the issue) https://bugzilla.redhat.com/show_bug.cgi?id=1509455 (non-public) 2. Even with "follow symlinks = yes", following symlinks is no longer possible. https://bugzilla.samba.org/show_bug.cgi?id=12721 These appear to have been fixed upstream already. Can you please adopt the upstream fixes, particularly for RHEL 6? Thank you.
This has already been addressed and will be fixed in RHEL 6.10