Documented the per-session CertificateVerify scratch buffers - #49
Open
fdesbiens wants to merge 1 commit into
Open
Documented the per-session CertificateVerify scratch buffers#49fdesbiens wants to merge 1 commit into
fdesbiens wants to merge 1 commit into
Conversation
netxduo now reserves the CertificateVerify signature working buffers per TLS session, out of the crypto metadata area, so that concurrent sessions do not corrupt each other's handshake hash and signature block (eclipse-threadx/netxduo#430). Two consequences need documenting. The metadata buffer requirement grows, so an application that hard-codes the size instead of calling nx_secure_tls_metadata_size_calculate will start getting NX_INVALID_PARAMETERS from nx_secure_tls_session_create. And the buffer sizes are now configurable through NX_SECURE_TLS_CERTIFICATE_VERIFY_SIGNATURE_SIZE and NX_SECURE_TLS_CERTIFICATE_VERIFY_PSS_SCRATCH_SIZE, which an application can lower to recover memory when its largest certificate key is smaller than the 4096-bit default. Assisted-by: Claude Code (Opus 5)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Documentation for eclipse-threadx/netxduo#431, which fixes eclipse-threadx/netxduo#430.
netxduo now reserves the CertificateVerify signature working buffers per TLS session, out of the crypto metadata area, so that two sessions authenticating with a certificate at the same time no longer corrupt each other's handshake hash and signature block.
Two consequences need documenting:
nx_secure_tls_metadata_size_calculatewill start gettingNX_INVALID_PARAMETERSfromnx_secure_tls_session_create. Covered by a new paragraph in the TLS guide's "Cryptographic Metadata" section (chapter 3), which also explains why the buffers are per-session.NX_SECURE_TLS_CERTIFICATE_VERIFY_SIGNATURE_SIZEandNX_SECURE_TLS_CERTIFICATE_VERIFY_PSS_SCRATCH_SIZElet an application recover memory when its largest certificate key is smaller than the 4096-bit default ofNX_CRYPTO_MAX_RSA_MODULUS_SIZE. Added to the option tables in both the TLS and the DTLS guides (chapter 2), next to the existingNX_CRYPTO_MAX_RSA_MODULUS_SIZEentry.Should be merged together with, or just after, eclipse-threadx/netxduo#431.