Skip to content

Commit 6eb335d

Browse files
authored
Merge pull request #9919 from davidhorstmann-arm/clarify-x509-security-md-3.6
[Backport 3.6] Add X.509 formatting validation to SECURITY.md
2 parents c811fb7 + 910273c commit 6eb335d

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

SECURITY.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -144,3 +144,22 @@ Policy](https://github.com/hacl-star/hacl-star/blob/main/SECURITY.md).)
144144

145145
The Everest variant is only used when `MBEDTLS_ECDH_VARIANT_EVEREST_ENABLED`
146146
configuration option is defined. This option is off by default.
147+
148+
#### Formatting of X.509 certificates and certificate signing requests
149+
150+
When parsing X.509 certificates and certificate signing requests (CSRs),
151+
Mbed TLS does not check that they are strictly compliant with X.509 and other
152+
relevant standards. In the case of signed certificates, the signing party is
153+
assumed to have performed this validation (and the certificate is trusted to
154+
be correctly formatted as long as the signature is correct).
155+
Similarly, CSRs are implicitly trusted by Mbed TLS to be standards-compliant.
156+
157+
**Warning!** Mbed TLS must not be used to sign untrusted CSRs unless extra
158+
validation is performed separately to ensure that they are compliant to the
159+
relevant specifications. This makes Mbed TLS on its own unsuitable for use in
160+
a Certificate Authority (CA).
161+
162+
However, Mbed TLS aims to protect against memory corruption and other
163+
undefined behavior when parsing certificates and CSRs. If a CSR or signed
164+
certificate causes undefined behavior when it is parsed by Mbed TLS, that
165+
is considered a security vulnerability.

0 commit comments

Comments
 (0)