A Swift framework for iOS, macOS, and tvOS to connect to SMB2/3 shares and perform file operations.
AMSMB2 is a Swift framework that allows developers to connect to SMB2/3 network shares from iOS, macOS, and tvOS applications. It wraps the libsmb2 C library to provide native file operations like listing directories, moving files, and reading file metadata. The library solves the problem of accessing network file shares within Apple ecosystem apps without relying on platform-specific APIs.
iOS, macOS, and tvOS developers who need to integrate SMB file sharing capabilities into their applications, particularly those building file managers, media players, or productivity tools that work with network storage.
Developers choose AMSMB2 because it provides a pure Swift, thread-safe interface to SMB shares with support for modern SMB2/3 protocols. Its straightforward API and compatibility across Apple platforms make it easier to implement than lower-level alternatives while maintaining proper licensing compliance for App Store distribution.
Swift framework to connect SMB2/3 shares
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Supports SMB2/3 protocols for connecting to contemporary network shares, ensuring compatibility with modern servers as highlighted in the key features.
Offers a unified Swift API across iOS, macOS, and tvOS, simplifying cross-platform development for Apple ecosystems without platform-specific code.
Designed as thread-safe for multi-threaded environments, enabling safe concurrent file operations without manual synchronization, as noted in the README.
Provides comprehensive functions like listing directories, moving files, and accessing metadata, covering common tasks needed for network file management.
Manages connection queuing and offers optional explicit disconnection, improving reliability in handling network shares, as shown in the usage example.
Due to LGPL licensing of libsmb2, the library must be linked dynamically for App Store distribution, adding complexity to build and deployment processes.
The README relies on inline help with only a basic example, lacking detailed tutorials or API references, which can hinder onboarding and troubleshooting.
Wraps libsmb2, so any bugs, updates, or limitations in the underlying C library directly impact stability and require careful version management.
Disconnection is not automatic and requires explicit calls or relies on object deallocation, potentially leading to resource leaks if not handled carefully, as mentioned in the code snippet.