Samba 4.1 Features added/changed

From SambaWiki

Samba 4.1.5

Release Notes for Samba 4.1.5
February 21, 2014

This is the latest stable release of Samba 4.1.

Major enhancements in Samba 4.1.5 include:

  • bug #10358Fix 100% CPU utilization in winbindd when trying to free memory in winbindd_reinit_after_fork.
  • bug #10415smbd: Fix memory overwrites.

Changes since 4.1.4:

  • Michael Adam <obnox at>
  • bug #10259: Make shadow_copy2 module working with Windows 7.
  • Jeremy Allison <jra at>
  • bug #2662: Make revamped directory handling code 64bit clean.
  • bug #10320: s3: smbpasswd: Fix crashes on invalid input.
  • bug #10358: Fix 100% CPU utilization in winbindd when trying to free memory in winbindd_reinit_after_fork.
  • bug #10406: s3: vfs_dirsort module: Allow dirsort to work when multiple simultaneous directories are open.
  • bug #10429: s3: modules: streaminfo: As we have no VFS function SMB_VFS_LLISTXATTR we can't cope with a symlink when lp_posix_pathnames() is true.
  • Alistair Leslie-Hughes <leslie_alistair at>
  • bug #10087: ntlm_auth sometimes returns the wrong username to mod_ntlm_auth_winbind.
  • Andrew Bartlett <abartlet at>
  • bug #10418: Fix INTERNAL ERROR: Signal 11 in the kdc pid.
  • Jeffrey Clark <dude at>
  • bug #10418: Add support for Heimdal's unified krb5 and hdb plugin system.
  • Niels de Vos <ndevos at>
  • bug #10384: vfs/glusterfs: In case atime is not passed, set it to the current atime.
  • David Disseldorp <ddiss at>
  • bug #10424: vfs_btrfs: Fix incorrect zero length server-side copy request handling.
  • Volker Lendecke <vl at>
  • bug #2191: s3-winbind: Improve performance of wb_fill_pwent_sid2uid_done().
  • bug #10415: smbd: Fix memory overwrites.
  • bug #10436: smbd: Fix an ancient oplock bug.
  • Stefan Metzmacher <metze at>
  • Andreas Schneider <asn at>
  • Jelmer Vernooij <jelmer at>
  • bug #10418: Cope with first element in hdb_method having a different name in different heimdal versions.

Samba 4.1.4

Release Notes for Samba 4.1.4
January 10, 2014

This is the latest stable release of Samba 4.1.

Major enhancements in Samba 4.1.4 include:

Changes since 4.1.3:

  • Jeremy Allison <>
  • bug #9870: smbd: Allow updates on directory write times on open handles.
  • bug #10260: smbclient shows no error if deleting a directory with del failed.
  • bug #10297: smbd: Fix writing to a directory with -wx permissions on a share.
  • bug #10305: ldb: bad if test in ldb_comparison_fold().
  • Christian Ambach <>
  • bug #10276: Fix waf build error on AIX with IBM XL C/C++.
  • bug #10280: s3:winbindd fix use of uninitialized variables.
  • Michele Baldessari <>
  • Jan Brummer <>
  • bug #10285: s3-winbindd: Fix DEBUG statement in winbind_msg_offline().
  • Günther Deschner <>
  • bug #10262: s3-libnetjoin: Use upper-case realm when composing default upn.
  • bug #10281: Fix numerous typos in man pages.
  • David Disseldorp <>
  • bug #10271: Send correct job-ID in print job notifications.
  • Poornima Gurusiddaiah <>
  • bug #10337: vfs_glusterfs: Enable per client log file.
  • Volker Lendecke <>
  • bug #10250: smbd: Fix a talloc hierarchy problem in msg_channel.
  • bug #10284: smbd: Fix segfaults.
  • bug #10297: smbd: Fix writing to a directory with -wx permissions on a share.
  • bug #10311: Fix SMB2 server panic when a smb2 brlock times out.
  • Stefan Metzmacher <>
  • bug #10298: Reduce smb2_server processing overhead.
  • Arvid Requate <>
  • bug #10267: Fix printing via local printer drivers with Windows 8.
  • Christof Schmitt <>
  • Andreas Schneider <>
  • bug #2191: Fix %G/%g substitution in 'template homedir'.
  • bug #10274: Fix several issues and warnings from analyzer tools.
  • bug #10286: s3-lib: Fix %G substitution for domain users in smbd.

Samba 4.1.3

Release Notes for Samba 4.1.3
December 9, 2013

This is a security release in order to address

  • CVE-2013-4408 (DCE-RPC fragment length field is incorrectly checked) and
  • CVE-2012-6150 (pam_winbind login without require_membership_of restrictions).
Samba versions 3.4.0 and above (versions 3.4.0 - 3.4.17, 3.5.0 - 3.5.22, 3.6.0 - 3.6.21, 4.0.0 - 4.0.12 and including 4.1.2) are vulnerable to buffer overrun exploits in the client processing of DCE-RPC packets. This is due to incorrect checking of the DCE-RPC fragment length in the client code.
This is a critical vulnerability as the DCE-RPC client code is part of the winbindd authentication and identity mapping daemon, which is commonly configured as part of many server installations (when joined to an Active Directory Domain). A malicious Active Directory Domain Controller or man-in-the-middle attacker impersonating an Active Directory Domain Controller could achieve root-level access by compromising the winbindd process.
Samba server versions 3.4.0 - 3.4.17 and versions 3.5.0 - 3.5.22 are also vulnerable to a denial of service attack (server crash) due to a similar error in the server code of those versions.
Samba server versions 3.6.0 and above (including all 3.6.x versions, all 4.0.x versions and 4.1.x) are not vulnerable to this problem.
In addition range checks were missing on arguments returned from calls to the DCE-RPC functions LookupSids (lsa and samr), LookupNames (lsa and samr) and LookupRids (samr) which could also cause similar problems.
As this was found during an internal audit of the Samba code there are no currently known exploits for this problem (as of December 9th 2013).
Winbind allows for the further restriction of authenticated PAM logins using the require_membership_of parameter. System administrators may specify a list of SIDs or groups for which an authenticated user must be a member of. If an authenticated user does not belong to any of the entries, then login should fail. Invalid group name entries are ignored.
Samba versions 3.3.10, 3.4.3, 3.5.0 and later incorrectly allow login from authenticated users if the require_membership_of parameter specifies only invalid group names.
This is a vulnerability with low impact. All require_membership_of group names must be invalid for this bug to be encountered.

Changes since 4.1.2:

  • Jeremy Allison <>
  • Stefan Metzmacher <>
  • Noel Power <>

Samba 4.1.2

Release Notes for Samba 4.1.2
November 22, 2013

This is is the latest stable release of Samba 4.1.

Changes since 4.1.1

  • Jeremy Allison <>
  • bug #10187: Missing talloc_free can leak stackframe in error path.
  • bug #10196: RW Deny for a specific user is not overriding RW Allow for a group.
  • Anand Avati <>
  • bug #10224: vfs_glusterfs: Implement proper mashalling/unmarshalling of ACLs.
  • Andrew Bartlett <>
  • bug #10052: dfs_server: Use dsdb_search_one to catch 0 results as well as NO_SUCH_OBJECT errors.
  • Samuel Cabrero <>
  • bug #9091: s4-dns: dlz_bind9: Create dns-HOSTNAME account disabled.
  • Günther Deschner <>
  • bug #10264: s3-winbindd: Fix cache_traverse_validate_fn failure for NDR cache entries.
  • Christopher R. Hertel <>
  • bug #10224: vfs_glusterfs: Fix excessive debug output from vfs_gluster_open().
  • Björn Jacke <>
  • bug #10247: xattr: Fix listing EAs on *BSD for non-root users.
  • Volker Lendecke <>
  • bug #10190: Fix memset used with constant zero length parameter.
  • bug #10195: nsswitch: Fix short writes in winbind_write_sock.
  • Stefan Metzmacher <>
  • bug #10193: s4:dsdb/rootdse: report 'dnsHostName' instead of 'dNSHostName'.
  • bug #10232: libcli/smb: Fix smb2cli_ioctl*() against Windows 2008.
  • Susant Kumar Palai <>
  • bug #10224: VFS plugin was sending the actual size of the volume instead of the total number of block units because of which windows was getting the wrong volume capacity.
  • Andreas Schneider <>
  • bug #10194: Make offline logon cache updating for cross child domain group membership.
  • bug #10269: util: Remove 32bit macros breaking strict aliasing.
  • bug #10253: Fix the build of vfs_glusterfs.

Samba 4.1.1

Release Notes for Samba 4.1.1
November 11, 2013

This is a security release in order to address CVE-2013-4475 (ACLs are not checked on opening an alternate data stream on a file or directory) and CVE-2013-4476 (Private key in key.pem world readable).

Samba versions 3.2.0 and above (all versions of 3.2.x, 3.3.x, 3.4.x, 3.5.x, 3.6.x, 4.0.x and 4.1.x) do not check the underlying file or directory ACL when opening an alternate data stream.
According to the SMB1 and SMB2+ protocols the ACL on an underlying file or directory should control what access is allowed to alternate data streams that are associated with the file or directory.
By default no version of Samba supports alternate data streams on files or directories.
Samba can be configured to support alternate data streams by loading either one of two virtual file system modues (VFS) vfs_streams_depot or vfs_streams_xattr supplied with Samba, so this bug only affects Samba servers configured this way.
To determine if your server is vulnerable, check for the strings "streams_depot" or "streams_xattr" inside your smb.conf configuration file.
In setups which provide ldap(s) and/or https services, the private key for SSL/TLS encryption might be world readable. This typically happens in active directory domain controller setups.

Changes since 4.1.1:

  • Jeremy Allison <>
  • Björn Baumbach <>

Samba 4.1.0

Release Notes for Samba 4.1.0
October 11, 2013

This is is the first stable release of Samba 4.1.

Samba 4.1 will be the next version of the Samba suite and includes all the technology found in both the Samba4 series and the stable 3.x series. The primary additional features over Samba 3.6 are support for the Active Directory logon protocols used by Windows 2000 and above.

Major enhancements in Samba 4.1.0 include:

Client tools support SMB2/3

Samba 4.1.0 contains the first release of our client tools and client library that work over the new protocols SMB2 or SMB3. Note that SMB3 only works either to a Samba server version 4.0.0 or above, or to a Windows Server running Windows 2012 or Windows 8.

The default protocol for smbclient and smbcacls is still SMB1 (the NT1 protocol dialect). An SMB2 or SMB3 connection can be selected in one of two ways. The easiest way to test the new protocol connection is to add the -mMAX_PROTOCOL command line switch to either smbclient or smbcacls.

For example, to connect using SMB3 with smbclient a user would type:

smbclient //server/share -Uuser%password -mSMB3

Another example of connecting using SMB2 using smbcacls would be:

smbcacls //server/share -Uuser%password -mSMB2 filename

Note that when connecting using SMB2 or SMB3 protocols the UNIX extensions are no longer available inside the smbclient command set. This is due to UNIX extensions not yet being defined for the SMB2 or SMB3 protocols.

The second way to select SMB2 or SMB3 connections is to set the "client max protocol" parameter in the [global] section of your smb.conf.

Setting this parameter will cause all client connections from Samba and its client tools to offer the requested max protocol to a server on every connection request.

For example, to cause all client tools (including winbindd, rpcclient, and the libsmbclient library) to attempt use SMB3 by default add the line:

client max protocol = SMB3

to the [global] section of your smb.conf. This has not been as widely tested as the -mPROTOCOL options, but is intended to work correctly in the final release of 4.1.0.

Encrypted transport

Although Samba servers have supported encrypted transport connections using the UNIX extensions for many years, selecting SMB3 transport allows encrypted transport connections to Windows servers that support SMB3, as well as Samba servers.

In order to enable this, add the "-e" option to the smbclient command line.

For example, to connect to a Windows 2012 server over SMB3 and select an encrypted transport you would use the following command line:

smbclient //Win2012Server/share -Uuser%password -mSMB3 -e

Directory database replication (AD DC mode)

Directory replication has been reworked in order to improve the correctness and efficiency.

As a net effect of it, replication with other domain controllers with a heavily modified schema is now possible (ie. Windows 2012 DCs or other Windows DC with exchange installed) and replication didn't fail anymore in such environments.

Server-Side Copy Support

Samba 4.1.0 adds support for server-side copy operations via the SMB2 FSCTL_SRV_COPYCHUNK request. Clients making use of server-side copy support, such as Windows Server 2012, should experience considerable performance improvements for file copy operations, as file data need not traverse the network.

This feature is enabled by default on the smbd file server.

Btrfs Filesystem Integration

The Btrfs VFS module provided with Samba 4.1.0 further improves the performance of server-side copy operations on shares backed by a Btrfs filesystem. It does so by allowing multiple files to share the same on-disk extents, avoiding the unnecessary duplication of source and destination file data during a server-side copy operation.

This feature can be explicitly enabled on smbd shares backed by a Btrfs filesystem with the smb.conf parameter:

vfs objects = btrfs

The Samba Web Administration Tool (SWAT) has been removed. Details why SWAT has been removed can be found on the samba-technical mailing list:


smb.conf changes
  Parameter Name			Description	Default
  --------------			-----------	-------
  acl allow execute always             New		False
  password level                       Removed
  set directory                        Removed
  use ntdb                             New		No

RUNNING Samba 4.1 as an AD DC

A short guide to setting up Samba as an AD DC can be found on the wiki:



  • Jeremy Allison <>
  • Add SMB2 and SMB3 support for client tools and client library.
  • Add support for SMB3 Encrypted transport.
  • David Disseldorp <>
  • Add vfs_btrfs module.
  • Add support for server-side copy operations via the SMB2 FSCTL_SRV_COPYCHUNK request.
  • Stefan Metzmacher <>
  • Andreas Schneider <>
  • bug #10132: pam_winbindd: Support the KEYRING ccache type.
  • Michael Adam <>
  • bug #10134: Add "acl allow execute always" parameter.
  • Jeremy Allison <>
  • bug #10139: Valid utf8 filenames cause "invalid conversion error" messages.
  • bug #10145: Samba SMB2 client code reads the wrong short name length in a directory listing reply.
  • bug #10149: cli_smb2_get_ea_list_path() failed to close file on exit.
  • bug #10150: Not all OEM servers support the ALTNAME info level.
  • Andrew Bartlett <>
  • bug #8077: dsdb: Convert the full string from UTF16 to UTF8, including embedded NULLs.
  • bug #9461: python-samba-tool fsmo: Do not give an error on a successful role transfer.
  • bug #10157: Regression causes replication failure with Windows 2008R2 and deletes Deleted Objects.
  • Günther Deschner <>
  • bug #10147: Better document potential implications of a globally used "valid users".
  • Korobkin <>
  • bug #10118: Raise the level of a debug when unable to open a printer.
  • Volker Lendecke <>
  • bug #10008: dbwrap_ctdb: Treat empty records as non-existing.
  • bug #10138: smbd: Always clean up share modes after hard crash.
  • Daniel Liberman <>
  • bug #10162: Fix POSIX ACL mapping when setting DENY ACE's from Windows.
  • Stefan Metzmacher <>
  • bug #10144: libcli/smb: Use SMB1 MID=0 for the initial Negprot.
  • bug #10146: libcli/smb: Only check the SMB2 session setup signature if required and valid.
  • Matthieu Patou <>
  • bug #10158: Netbios related samba process consumes 100% CPU.
  • Christof Schmitt <>
  • bug #10137: vfs_shadow_copy2: Display previous versions correctly over SMB2.
  • Michael Adam <>
  • bug #10107: Fix Winbind crashes on DC with trusted AD domains.
  • Jeremy Allison <>
  • bug #5917: Fix working on site with Read Only Domain Controller.
  • bug #9974: Add SMB2 and SMB3 support for smbclient.
  • bug #10163: Fix memory leak in source3/lib/util.c:1493.
  • bug #10121: Masks incorrectly applied to UNIX extension permission changes.
  • Christian Ambach <>
  • bug #9911: Build Samba 4.0.x on AIX with IBM XL C/C++.
  • Andrew Bartlett <>
  • bug #9091: When replicating DNS for bind9_dlz we need to create the server-DNS account remotely.
  • Günther Deschner <>
  • bug #9615: Winbind unable to retrieve user information from AD.
  • bug #9899: winbind_lookup_names() fails because of NT_STATUS_CANT_ACCESS_DOMAIN_INFO.
  • bug #10107: Fix Winbind crashes on DC with trusted AD domains.
  • Volker Lendecke <>
  • bug #10086: smbd: Fix async echo handler forking.
  • bug #10106: Honour output buffer length set by the client for SMB2 GetInfo requests.
  • bug #10114: Handle Dropbox (write-only-directory) case correctly in pathname lookup.
  • Stefan Metzmacher <>
  • Rusty Russell <>
  • Karolin Seeger <>
  • bug #7364: Add man page for vfs_syncops.
  • bug #7490: Add man page for vfs_linux_xfs_sgid.
  • bug #10001: Add man page for samba-regedit tool.
  • bug #10076: Fix variable list in vfs_crossrename man page.
  • Andreas Schneider <>
  • bug #10073: Fix segmentation fault in 'net ads join'.
  • bug #10082: s3-winbind: Fix a segfault passing NULL to a fstring argument.
  • Richard Sharpe <>
  • bug #10097: MacOSX 10.9 will not follow path-based DFS referrals handed out by Samba.
  • Ralph Wuerthner <>
  • bug #10106: Honour output buffer length set by the client for SMB2 GetInfo requests.

  • Jeremy Allison <>
  • bug #9992: Windows error 0x800700FE when copying files with xattr names containing ":".
  • bug #10010: Missing integer wrap protection in EA list reading can cause server to loop with DOS (CVE-2013-4124).
  • bug #10064: Linux kernel oplock breaks can miss signals.
  • Andrew Bartlett <>
  • bug #9029: Fix replication with --domain-crictical-only to fill in backlinks.
  • bug #9820: Fix crash of winbind after "ls -l /usr/local/samba/var/locks/sysvol".
  • bug #10056: dsdb improvements.
  • Björn Baumbach <>
  • bug #10003: Fix segfault while reading incomplete session info.
  • Gregor Beck <>
  • Günther Deschner <>
  • bug #10043: Allow to change the default location for Kerberos credential caches.
  • Volker Lendecke <>
  • bug #10013: Fix a 100% loop at shutdown time (smbd).
  • Stefan Metzmacher <>
  • bug #9820: Fix crash of winbind after "ls -l /usr/local/samba/var/locks/sysvol".
  • bug #10015: Fix/improve debug options.
  • bug #10042: Fix crashes in socket_get_local_addr().
  • bug #10056: dsdb improvements.
  • Andreas Schneider <>
  • bug #9994: Do not delete an existing valid credential cache (s3-winbind).
  • bug #10040: Rename regedit to samba-regedit.
  • bug #10041: Remove obsolete swat manpage and references.
  • bug #10048: nsswitch: Add OPT_KRB5CCNAME to avoid an error message.
  • Alexander Werth <>
  • bug #10045: Remove a redundant inlined substitution of ACLs.
  • Ralph Wuerthner <>
  • bug #10064: Linux kernel oplock breaks can miss signals.