Back to Defold

Mbed TLS 4.1.0 Feature Summary

summary_mbedtls.md

1.13.13.4 KB
Original Source

Mbed TLS 4.1.0 Feature Summary

Summary

The current Mbed TLS 4.1.0 profile is at least on par with the Mbed TLS 2.17 usage Defold exposes through sslsocket_mbedtls.cpp for common HTTPS client cases, and it adds TLS 1.3 support.

It is not strict config parity with the broad 2.17 default profile. The current profile intentionally removes unused or legacy functionality such as DTLS, server TLS, PSK-only handshakes, uncommon curves, persistent PSA storage, and X.509 write/CSR/CRL functionality.

Common Client Feature Comparison

CapabilityMbed TLS 2.17Current Mbed TLS 4.1.0
TLS clientyesyes
TLS 1.2yesyes
TLS 1.3noyes
ECDHE-RSAyesyes
ECDHE-ECDSAyesyes
TLS 1.3 ECDHEnoyes
TLS session ticketsyesyes
TLS 1.3 PSK+ECDHE resumptionnoyes
X.509 certificate parsingyesyes
X.509 certificate verificationyesyes
RSA certificate supportyesyes
ECDSA certificate supportyesyes
AES-GCMyesyes
ChaCha20-Poly1305yesyes
AES-CCMyesyes
SHA-1/SHA-256/SHA-384/SHA-512yesyes
MD5 for dmCrypt compatibilityyesyes
Base64 for dmCrypt compatibilityyesyes

Current TLS 1.3 Support

The current TLS 1.3 support is a good modern HTTPS client profile:

TLS 1.3 FeatureCurrent State
MBEDTLS_SSL_PROTO_TLS1_3enabled
MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODEenabled
MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLEDenabled
MBEDTLS_SSL_SESSION_TICKETSenabled
MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLEDenabled
MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLEDdisabled
MBEDTLS_SSL_TICKET_Cdisabled

This means TLS 1.3 supports certificate-authenticated ephemeral handshakes and ticket-based resumption with PSK+ECDHE. Pure PSK remains disabled, and the server-side ticket callback implementation remains disabled.

Curves And Algorithms

Kept for common HTTPS:

CategoryKept
Curves/groupsX25519, P-256, P-384
Key exchange/signatureECDH, ECDSA, RSA PKCS#1 v1.5 sign, RSA-PSS
AEADAES-GCM, AES-CCM, ChaCha20-Poly1305
Hash/HKDF/HMACSHA-1, SHA-224, SHA-256, SHA-384, SHA-512, HKDF, HMAC

Removed from the client profile:

Removed AreaNotes
DTLSDefold sslsocket_mbedtls.cpp uses stream TLS, not datagram TLS.
TLS serverDefold exposes a client socket backend here.
Pure PSK / ECDHE-PSK TLS 1.2No Defold API exposes PSK credentials.
Pure TLS 1.3 PSKDisabled; PSK+ECDHE resumption is enabled.
Uncommon curvesBrainpool, secp256k1, X448, P-521 are disabled.
FFDH/DHDisabled.
Persistent PSA storage/ITSDisabled; Defold does not store persistent PSA keys.
X.509 write/CSR/CRL/PKCS7Not used by the runtime TLS client path.

Compatibility Notes

The current profile should support common modern HTTPS servers and current good practice:

  • TLS 1.3 first, with TLS 1.2 fallback.
  • Ephemeral ECDHE handshakes.
  • Server certificate verification using RSA or ECDSA certificate chains.
  • Common TLS 1.3 groups and ciphers.
  • TLS 1.3 ticket resumption with PSK+ECDHE.

The main compatibility risk is very old or unusual TLS 1.2 servers requiring static RSA, DHE/FFDHE, PSK-only handshakes, uncommon curves, or legacy protocols. Those are outside the current intended Defold runtime profile.