Repository navigation
Important
This release breaks the libsmb2 API and ABI. The soname is now 7, so
applications have to be rebuilt, and code that uses share enumeration or
srvsvc has to be changed. libsmb2.h defines LIBSMB2_SRVSVC_V2 when the
new API is present, so an application can build against both 6.x and 7.x:
#ifdef LIBSMB2_SRVSVC_V2
/* 7.x: smb2_share_enum_async(), struct smb2_share_enum_reply */
#else
/* 6.x: struct srvsvc_NetrShareEnum_rep */
#endifexamples/smb2-share-enum.c does this, and maps the old names to the new
ones. 6.3.x stays on the libsmb2-6-branch for security fixes only.
libsmb2 7.0.0 is the first release from master since 6.2. It comes with the
first separate release of libdcerpc 1.0.0, tagged libdcerpc-1.0.0 in this
repository (git archive libdcerpc-1.0.0:libdcerpc).
Major features
- SMB2 over QUIC, client and server
- SMB2 over SMB Direct (RDMA)
- IAKerb authentication
- AES-128-GCM and AES-256-GCM with optional OpenSSL 3
- Encrypted sessions and Kerberos in the server
- libdcerpc, a separate DCE/RPC library with an IDL compiler
- Symlinks, hard links, server-side copy and change notify
- Hardened decoders throughout, including the 6.3.x CVE fixes
New features
- SMB2 over QUIC, client and server, selected with the
quicURL argument.
Linux only: the kernel QUIC module and libquic. - SMB2 over SMB Direct (RDMA), client, selected with the
rdmaURL argument.
Linux only: rdma-core. - IAKerb authentication (
sec=iakerb), client and server. - Optional OpenSSL 3 libcrypto: AES-128-GCM and AES-256-GCM for SMB 3.1.1, and
signing and AES-128-CCM sealing through OpenSSL. - AES-CMAC signing with AES-NI over the iovecs, and an optimized AES on Apple
platforms. - Server: encrypted sessions, SMB 3.1.1 cipher negotiation, Kerberos with a
keytab and mapping to local users, oplock and lease breaks, every directory
information class, deferred IOCTLs and extra fds in the serve loop. - libdcerpc is a separate library and project (own configure/CMake, soname 1,
libdcerpc-*tags). It has an IDL compiler that generates the coders, the
srvsvc, wkssvc, winreg, lsa, samr, dssetup, netlogon and epm interfaces,
NDR32 and NDR64 in both byte orders, YAML and JSON encodings, schannel, a
server runtime for named pipes, thedcerpctool,winreg-tuiand
dcerpcd. It builds on Linux and FreeBSD.
New client calls
smb2_symlink(),smb2_link(), server-side copy (FSCTL_SRV_COPYCHUNK),
setting security descriptors, change notify, SMB2 CANCEL
(smb2_cmd_cancel_async()) and unrelated compound requests.*_async_pdu()variants of open and opendir: freeing the returned pdu
cancels the call.- Getters for the application key, server GUID, session id, workstation, and
for the tree id and async ids of a server request.
API and ABI changes (soname 7)
- Share enumeration is a flat
smb2_share_enum_*()API with its own types;
libsmb2 no longer contains any of libdcerpc. smb2_set_seal()takes NONE/MAYBE/MUST, and encryption is only offered when
sealing is enabled.smb2_notify_change_filehandle_async()no longer closes the caller's handle.smb2_active_contexts()andsmb2_context_active()cover only a server's
contexts.- Server: the library frees a CANCEL itself, and the handler rules are
documented inlibsmb2.h. - Every function declared in the public headers is now exported (#473), and
smb2_get_libsmb2Version()reports the real version.
Security and robustness
- Untrusted lengths and offsets are bounded throughout the PDU, NTLMSSP,
SPNEGO, query-info, security descriptor and share enumeration decoders,
including every fix in 6.3.0 to 6.3.2 (CVE-2026-110713, CVE-2026-110714). - Clearing SMB2_FLAGS_SIGNED no longer skips signature verification, a dialect
that was never offered is refused, challenges, salts and nonces come from a
CSPRNG, and sealed replies and transform headers are checked on both sides. - Compounds, cancels and context teardown neither lose nor double a callback,
and free everything they own. - Contexts used on different threads no longer share any state.
Platforms
- Haiku, OpenBSD, GNU/Hurd and RXDK; Dreamcast, GameCube, Wii and Wii U
updates; the PS2 IOP modulesmb2man.irxand non-blocking sockets on the
PS2 EE; PS3, Amiga, MinGW, MSVC 2022, macOS, Pico and ESP-IDF fixes. - CMake and autotools install the same public headers.