Releases: jborean93/smbprotocol
Releases · jborean93/smbprotocol
Release list
v1.17.0
What's Changed
- Bump version post PyPI release by @jborean93 in #342
- Bump minimum Python to 3.10 and dev deps by @jborean93 in #343
- Add target_ip parameter to connection to avoid relying on internal DNS resolution by @laxa in #345
- Handle DFS path resolution during directory listing by @sunilkata-lb in #344
- Fix the str value for flag fields by @jborean93 in #350
- Improve recv-path diagnostics by @henrik-nil-acc in #351
- Add missing structure flags by @jborean93 in #355
- Fix signing requirement against signing required by @laxa in #356
- Stop OSError leaks past rmtree's ignore_errors by @henrik-nil-acc in #357
- Stop wire close from SMBRawIO finalizer by @henrik-nil-acc in #353
- Make codecov project status non-blocking on PRs by @henrik-nil-acc in #360
- Clear Open client state on close-response error by @henrik-nil-acc in #359
- Treat STATUS_NO_SUCH_FILE as end of enumeration by @henrik-nil-acc in #358
- Move dev dependencies into pyproject.toml by @henrik-nil-acc in #362
- Return context-manager iterator from scandir() by @henrik-nil-acc in #363
- Surface SMB tree setup errors as OSError by @henrik-nil-acc in #361
- Prepare for v1.17.0 release by @jborean93 in #365
New Contributors
- @sunilkata-lb made their first contribution in #344
- @henrik-nil-acc made their first contribution in #351
1.17.0 - 2026-07-07
- Drop support for Python 3.9, minimum verison if now 3.10
- Added the
hostname_overridekwarg tosmbprotocol.Sessionthat can override the hostname used in the SPN for authentication - Correctly perform a DFS referral lookup in the
query_directoryon a directory - Fix the
FlagFieldstr representation when theflag_typecontains a dunder attribute with anintvalue - Added some extra flags from MS-SMB2 that have been added recently
- Fix
Connection.client_security_modeto beSMB2_NEGOTIATE_SIGNING_REQUIREDwhen server reports signing is required - Solve numerous issues with
smbclient.rmtreeandignore_errorsnot working with various exceptions - Make
smbclient.scandirreturn a context manager that can close SMB resources. This method should now be called like- The return value is still an iterable and will continue to work as it did before but code should still be updated to use the context manager to ensure resources are released
with smbclient.scandir(...) as scan_gen:
for entry in scan_gen:
...- Handle
STATUS_NO_SUCH_FILEduringsmbclient.scandirwhen using a pattern that matches no file in the specified path - Improve various threading race conditions and deadlocks in the underlying client handler
Full Changelog: v1.16.1...v1.17.0
v1.16.1
1.16.1 - 2026-04-02
- Fix memory leaks in
Structureand subclasses by converting lambda default values to static methods and usingweakref.proxyto prevent circular references - Fix
smbclient.shutil.copyfileto fallback to client-side copy when server-side SMB copy is not supported (STATUS_NOT_SUPPORTED) - Fix create context offset calculation when opening a file or directory
- Fix potential deadlock when worker thread attempts to disconnect and join itself
- Handle
ECONNABORTEDsocket error during connection teardown
What's Changed
- Fix create_context offset when opening a dir/file by @laxa in #338
- Fix Memory Leaks in Structure and Structure Subclasses by @PyWoody in #340
- Fix copyfile fallback when server-side SMB copy is unsupported by @K3N44N in #337
- Handle ECONNABORTED and avoid joining the current thread by @avivbrg in #323
New Contributors
- @laxa made their first contribution in #338
- @PyWoody made their first contribution in #340
- @K3N44N made their first contribution in #337
- @avivbrg made their first contribution in #323
Full Changelog: v1.16.0...v1.16.1
v1.16.0
What's Changed
- Bump version by @jborean93 in #310
- Implement SMB2 LOCK operation by @xhernandez in #309
- Allow floating point times for smbclient.utime by @mon in #317
- Update CI and build information by @jborean93 in #328
- Generalize to Callables Instead of Strictly Lambdas by @Jayson-Fong in #327
- Propagate missing session params by @SuperBuker in #332
- Fix no symlink buffer on symlink open by @jborean93 in #334
- Fix copy/copy2 kwargs handling by @jborean93 in #331
New Contributors
- @xhernandez made their first contribution in #309
- @Jayson-Fong made their first contribution in #327
- @SuperBuker made their first contribution in #332
Full Changelog: v1.15.0...v1.16.0
v1.15.0
What's Changed
- Fix Impacket logoff session id check by @jborean93 in #291
- Update session id logic by @jborean93 in #293
- Add
smbclient.liststreamsto enumerate ADS streams by @mon in #294 - Add some type annotations, most notably to
smbclient.open_fileby @mon in #295 - Add Python 3.13 support and prepare for release by @jborean93 in #299
1.15.0 - 2024-11-12
- Update session id lookup logic to comply with MS-SMB2 spec
- Remove connection from global connection cache even if failing to close it
- Added smbclient.liststreams as a way to list the Alternate Data Streams in a file/directory
- Added official support for Python 3.13
New Contributors
Full Changelog: v1.14.0...v1.15.0
v1.14.0
What's Changed
- Bump version and update dev deps by @jborean93 in #276
- type information of SMBDirEntryInformation.last_write_time set to datetime by @christianknoepfle in #280
- Customizable receive timeout for SMB Connection by @leonnis12 in #285
1.14.0 - 2024-08-26
- Dropped support for Python 3.7
SMBDirEntryInformation.last_write_timeis now annotated asdatetime.datetime. Previously, it wasdatetime.date. #279
New Contributors
- @christianknoepfle made their first contribution in #280
- @leonnis12 made their first contribution in #285
Full Changelog: v1.13.0...v1.14.0
v1.13.0
What's Changed
- Bump new version after release by @jborean93 in #247
- Add smb_info to a scandir result by @jborean93 in #251
- Use UTC tzinfo datetime values by @jborean93 in #252
- Added default timeout on connection.receive() by @Robbert-Brand in #257
- Show low-level OS error on TCP connection errors. by @adiroiban in #264
- Wait for message thread to stop on disconnect. by @adiroiban in #262
- Fix up compound request session and tree ids by @jborean93 in #266
- Shutil.copyfile will open source with read share by @jborean93 in #265
- Fix up endless auth loop by @jborean93 in #267
- Prepare for v1.13.0 release by @jborean93 in #275
New Contributors
- @Robbert-Brand made their first contribution in #257
1.13.0 - 2024-03-21
- Added the property
smb_infoonSMBDirEntrywhich returns a named tupleSMBDirEntryInformationcontaining metadata already retrieved in thescandiroperation.- This avoid having to call
stat()to retrieve data like the file attributes or datetime fields that is already available
- This avoid having to call
- Ensure
DateTimeFieldvalues are set toUTCtimezones as FILETIME values are in UTC - Stop using
datetime.datetime.utcfromtimestamp()as it has been deprecated - Added default timeout for disconnect operations for 60 seconds to ensure the process doesn't hang forever when closing a broken connection
smbprotocol.connection.Connection.disconnect()now waits (with a timeout) for the message processing threads to be stopped before returning.- Do not set the SMB SessionId and TreeId in the headers to
0xFFFFFFFFfor related compound requests
- Ensures the source file for
shutil.copyfileis opened withshare_access="r"for better compatibility with files already opened by something else - Remove endless authentication loop when the context is complete and no more input messages are needed
Full Changelog: v1.12.0...v1.13.0
v1.12.0
What's Changed
- Bump version by @jborean93 in #241
- Add 0xc000007f to mapping by @rsdoherty in #245
- Prepare for v1.12.0 release by @jborean93 in #246
1.12.0 - 2023-11-09
- Added the
DiskFullerror and message for the NTSTATUS code0xC000007F- #245
New Contributors
- @rsdoherty made their first contribution in #245
Full Changelog: v1.11.0...v1.12.0
v1.11.0
What's Changed
- Fix up CI problems due to new black rules by @jborean93 in #210
- Python3 style updates by @tik-stbuehler in #212
- Use OIDC for PyPI releases by @jborean93 in #214
- typo fix in docstring for copyfile by @brno32 in #222
- correct requirements file name in README by @brno32 in #223
- Update CI code by @jborean93 in #225
- Fix up session id lookup issues with ksmbd by @jborean93 in #224
- adding support for remote to local operations in shutil.py::copytree by @brno32 in #226
- adding support for local to remote operations in shutil.py::copytree by @brno32 in #227
- Do not setup logging in libraries by @dolfinus in #233
- Upgrade to Python 3.7+ syntax by @dolfinus in #234
- Update changelog and added Python 3.12 to testing by @jborean93 in #238
- Fix DFS recurision for missing files by @jborean93 in #239
- Prepare for v1.11.0 release by @jborean93 in #240
1.11.0 - 2023-09-06
- Fix up pre authenticated session id lookups that were failing with Linux ksmbd
- Removes
logging.NullHandler()being set in the rootsmbprotocolnamespace - Adds basic support for remote to local and vice versa file operations with
smbclient.shutil.copytree - Fixes DFS infinite recursion error when dealing with a file that does not exist on a DFS namespace
New Contributors
- @tik-stbuehler made their first contribution in #212
- @brno32 made their first contribution in #222
- @dolfinus made their first contribution in #233
Full Changelog: v1.10.1...v1.11.0
v1.10.1
1.10.1 - 2022-11-14
- Raise the original
BadNetworkNameerror if the server doesn't indicate it supports DFS orFSDriverRequiredwas raised trying to lookup the DFS information - #196 - Fix pre auth session id tracking if the intermediate token messages return 0 as the session id - #203
Full Changelog: v1.10.0...v1.10.1
v1.10.0
What's Changed
- Fix copy2 docstring. by @mikekokuba in #180
- Allow server side copy across different shares on the same server by @coreyleavitt in #184
- Document recent copyfile change and bump version by @jborean93 in #187
- Update Project Structure by @jborean93 in #188
- Improve DFS file opens by @jborean93 in #190
- Fix rename operations for a DFS path by @jborean93 in #191
- Fix negotiate request context padding by @jborean93 in #201
New Contributors
- @mikekokuba made their first contribution in #180
- @coreyleavitt made their first contribution in #184
Full Changelog: v1.9.0...v1.10.0