mbedtls@3 for Mac
Cryptographic & SSL/TLS library
mbedtls@3 — overview
README for Mbed TLS
Mbed TLS is a C library that implements X.509 certificate manipulation and the TLS and DTLS protocols. Its small code footprint makes it suitable for embedded systems. Mbed TLS includes the TF-PSA-Crypto repository that provides an implementation of the PSA Cryptography API.
Configuration
Configuration options related to X.509 and TLS are available in include/mbedtls/mbedtls_config.h, while cryptography and platform options are located in the TF-PSA-Crypto configuration file tf-psa-crypto/include/psa/crypto_config.h.
With the default platform options, Mbed TLS should build out of the box on most systems.
These configuration files can be edited manually, or programmatically using the Python script scripts/config.py (run with --help for usage instructions).
We provide some non-standard configurations focused on specific use cases in the configs/ directory. You can read more about those in configs/README.txt.
Documentation
The main Mbed TLS documentation is available via ReadTheDocs.
To generate a local copy of the library documentation in HTML format, tailored to your compile-time configuration: Make sure that Doxygen is installed. Run cmake -B /path/to/build_dir /path/to/mbedtls/source Run cmake --build /path/to/build_dir --target mbedtls-apidoc Open one of the main generated HTML files: apidoc/index.html apidoc/modules.html or apidoc/topics.html
For other sources of documentation, see the SUPPORT document.
Compiling
We use CMake to configure and drive our build process. Three libraries are built: libtfpsacrypto, libmbedx509, and libmbedtls. Note that libmbedtls depends on libmbedx509 and libtfpsacrypto, and libmbedx509 depends on libtfpsacrypto. As a result, some linkers will expect flags to be in a specific order, for example the GNU linker wants -lmbedtls -lmbedx509 -ltfpsacrypto. The cryptographic library libtfpsacrypto is also provided under its legacy name, libmbedcrypto.
Tool versions
You need the following tools to build the library from the main branch with the provided CMake files. Mbed TLS minimum tool version requirements are set based on the versions shipped in the latest or penultimate (depending on the release cadence) long-term support releases of major Linux distributions, namely at time of writing: Ubuntu 22.04, RHEL 9, and SLES 15 SP4.
CMake 3.20.2 or later. A build system like Make or Ninja for which CMake can generate build files. A C99 toolchain (compiler, linker, archiver). We actively test with GCC 5.4, Clang 3.8, Arm Compiler 6, and Visual Studio 2017 Compiler. More recent versions should work. Slightly older versions may work. Python 3.8 or later to generate the test code. Python is also needed to build the development branch (see next section). Perl to run the tests, and to generate some source files in the development branch. Doxygen 1.8.14 or later (if building the documentation; slightly older versions should work).
Git usage
Details
加密与 SSL/TLS 库
How to install mbedtls@3
- Open Terminal (press ⌘ + Space and type “Terminal”).
- If Homebrew is not installed yet, run the command below first.
- Run this command:
Latest 10 releases
Last updated 2026-07-07; current version mbedtls-4.2.0, with the latest 10 releases listed.
| Version | Released | Type | Size | macOS | Windows | Linux |
|---|---|---|---|---|---|---|
| mbedtls-4.2.0 | 2026-07-07 | Stable | — | — | — | — |
| mbedtls-4.1.1 | 2026-07-07 | Stable | — | — | — | — |
| mbedtls-3.6.7 | 2026-07-07 | Stable | — | — | — | — |
| mbedtls-4.1.0 | 2026-03-31 | Stable | — | — | — | — |
| mbedtls-3.6.6 | 2026-03-31 | Stable | — | — | — | — |
| mbedtls-4.0.0 | 2025-10-15 | Stable | — | — | — | — |
| mbedtls-3.6.5 | 2025-10-15 | Stable | — | — | — | — |
| mbedtls-3.6.4 | 2025-06-30 | Stable | 4.1 MB | — | — | — |
| v3.6.3.1 | 2025-05-13 | Stable | — | — | — | — |
| mbedtls-4.0.0-beta | 2025-07-04 | Pre-release | — | — | — | — |
Data from GitHub Releases; stable releases first, each group sorted newest first.
Depended on by 6 apps
The following apps install it automatically, ranked by 30-day installs:
- gauche3,948 installs/mo
- blast157 installs/mo
- shadowsocks-libev59 installs/mo
- haxe44 installs/mo
- neko11 installs/mo
- neko11 installs/mo
Prebuilt bottle platforms
Official Homebrew bottles cover:
- Apple silicon · latest macOS
- Apple silicon · macOS 26 Tahoe
- Apple silicon · macOS 15 Sequoia
- Apple silicon · macOS 14 Sonoma
- Intel · macOS 14 Sonoma
- Linux · ARM64
- Linux · x86_64
Compared with similar apps
Only public metadata is compared, with no subjective recommendation; see the compare pages for field-by-field comparisons.
| App | Version | License | Architecture | 30-day installs |
|---|---|---|---|---|
| mbedtls@3 | mbedtls-4.2.0 | Apache-2.0 | CLI | 3,642 |
| cryptopp | CRYPTOPP_8_9_0 | LicenseRef-Homebrew-public-domain AND BSL-1.0 | CLI | 393 |
| openfortivpn | 1.24.1 | GPL-3.0-or-later WITH cryptsetup-OpenSSL-exception | CLI | 338 |
| nettle | 4.0 | GPL-2.0-or-later OR LGPL-3.0-or-later | CLI | 272 |
Similar apps: Security & Privacy
cryptopp
Crypto++: free C++ Class Library of Cryptographic Schemes Version 8.9 - October 1, 2023openfortivpn
openfortivpn is a client for PPP+TLS VPN tunnel services.nettle
Nettle is a low-level cryptographic library aimed primarily at developers who need to integrate…mbedtls
Cryptographic & SSL/TLS libraryxxhash
Extremely fast non-cryptographic hash algorithmbotan
Botan is a library of cryptographic algorithms and formats written in C, aimed at developers…Categories: Command-line Tools, Design & Graphics, Security & Privacy