You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 777bcb2
Browse filesBrowse the repository at this point in the historyBrowse files
Reference github #1485 in the BCJSSE OCSP stapling release note, the client-side TLS 1.3 staple read it asked for having arrived with the server-side stapling work, relates to github #1485.
Copy file name to clipboardExpand all lines: docs/releasenotes.html
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -186,7 +186,7 @@ <h3>2.1.3 Additional Features and Functionality</h3>
186
186
<li>The new org.bouncycastle.x509.CRLDP_protocols property is an optional whitelist of the protocols a CRL Distribution Point may name, applied by the CrlCache behind both the provider's CertPath validator and X509RevocationChecker before any connection is opened, and ahead of the cache, so an entry already held for a distribution point is no way around it. It is a comma separated list matched without regard to case - "http,https,ldap" refuses a distribution point naming ftp, file, jar or anything else the JVM happens to have a URL handler registered for, with a CRLException naming the protocol. Unset or empty, the default, leaves the protocol unrestricted: RFC 5280 sec. 4.2.1.13 requires a distribution point URI to name a protocol but does not restrict which, and BouncyCastle supports http, https, ftp and ldap here, so this is a policy for deployments that want a narrower set rather than a new default. Note the fetch it governs only happens at all where org.bouncycastle.x509.enableCRLDP is set (see Defects Fixed above).</li>
187
187
<li>The Gradle build now checks Android compatibility with AnimalSniffer: each published module's base (Java 8) classes are verified against the Android API level 26 (Android 8.0) platform signature, so a reference to a java.* / javax.* API absent from that platform - the class of regression behind the org.bouncycastle.util.BigIntegers.intValueExact NoSuchMethodError seen on older Android (see Defects Fixed above, github #2369) - fails the build rather than reaching a consumer's device as a runtime error. Only the base classes are checked, not the multi-release overlays, since those are selected by JDK version at runtime and never load on Android. A small allow-list covers the references that are intentionally platform-absent: the optional JNDI-based fetchers (javax.naming - the LDAP CRL and certificate stores in bcprov and bcpkix, and the DANE fetcher), which are inert on Android as it ships no JNDI, and the legacy bcmail S/MIME content handlers' java.awt.datatransfer.DataFlavor reference, which cannot be dropped while javax.activation 1.x's ActivationDataFlavor extends it - Android consumers should use bcjmail, which carries no such reference (github #242). Based on the initial implementation in github #336.</li>
188
188
<li>Classic McEliece can now be used as a recipient KEM in CMS EnvelopedData / AuthEnvelopedData via the RFC 9629 KEMRecipientInfo structure. DefaultKemEncapsulationLengthProvider now knows the encapsulation (ciphertext) lengths for all sixteen parameter sets standardised under the ISO/IEC 18033-2 arc (mceliece460896 156, mceliece6688128 208, mceliece6960119 194, mceliece8192128 208, each of the plaintext-confirmation "pc" sets adding a 32 byte confirmation hash, and the semi-systematic key generation "f" variants leaving the ciphertext unchanged), which JceKEMRecipientInfoGenerator previously lacked - a Classic McEliece recipient failed the wrap. DefaultAlgorithmNameFinder and DefaultKemAlgorithmIdentifierFinder already carried the parameter set names. Unlike ML-KEM and FrodoKEM there is no CMS profile for Classic McEliece, so the key-wrap algorithm is the caller's choice; the round-trip tests pair mceliece460896 (level 3) with AES-Wrap-192 and the level 5 sets with AES-Wrap-256, keying the wrap with HKDF-SHA256.</li>
189
-
<li>BCJSSE: the provider now offers server-side OCSP stapling, completing for the JSSE layer what the previous entry describes for the low-level TLS API. With the boolean system property jdk.tls.server.enableStatusRequestExtension set to true - default false, as in SunJSSE, since enabling it has the server make outbound OCSP requests on behalf of whoever connects to it - a BCJSSE server answers a client's "status_request" (RFC 6066 sec. 8) and "status_request_v2" (RFC 6961 sec. 2.2) extensions. For TLS 1.2 it sends a certificate_status message, preferring an ocsp_multi list covering the end-entity and every intermediate that has an issuer in the chain, and falling back to a single ocsp response for the end-entity; per RFC 6961 sec. 2.2 that list may be shorter than the certificate list and an element may be zero-length where no response is held. For TLS 1.3 there is no such message and the response instead rides in a "status_request" extension of the CertificateEntry it belongs to, holding an RFC 6066 CertificateStatus, per RFC 8446 sec. 4.4.2.1; status_request_v2 is deprecated there and is not honoured. A status request naming particular responders in its responder_id_list is left unanswered rather than answered with what some other responder said. Responses are fetched over HTTP per RFC 6960 App. A.1 from the responder named by each certificate's Authority Information Access extension - or from jdk.tls.stapling.responderURI when jdk.tls.stapling.responderOverride is set - read subject to the existing org.bouncycastle.ocsp.max_response_size ceiling, and discarded unless they carry a response bound to the certificate asked about. They are held in a per-SSLContext cache: a response is reused only while within both its own nextUpdate and jdk.tls.stapling.cacheLifetime, one stating no nextUpdate is stapled but never cached (RFC 6960 sec. 4.2.2.1 has an absent nextUpdate mean newer information is available all the time), and one dated more than the fifteen minute clock-skew allowance ahead of local time is treated as unreliable and not stapled at all. At most one request is in flight per certificate however many handshakes are waiting on it, a failed lookup suppresses further attempts for a short interval, and a handshake's wait is bounded by jdk.tls.stapling.responseTimeout - exactly, for one waiting on another's fetch; to within a read already in flight, for the one performing it, since a read timeout bounds each read rather than the exchange - a missing staple being an optimisation forgone, never a handshake failure. The server does not verify what it relays; verifying the response is the receiving client's part. On the client side a BCJSSE client now also reads TLS 1.3 staples, which BCExtendedSSLSession.getStatusResponses() returns positionally against the certificate chain - one element per certificate, zero-length where an entry carried no response - so that ProvX509TrustManager pairs each response with the certificate it answers for when handing them to the CertPath validator. Note this makes a client stricter about what a server sends it: RFC 8446 sec. 4.4.2.1 admits only a CertificateStatus of type ocsp in a CertificateEntry's "status_request" extension, so an extension carrying anything else - trailing bytes, the ocsp_multi form of the deprecated status_request_v2, an unparseable body - now fails the handshake with a decode_error alert, where previously these extension bodies were not read at all and a server that mis-stapled went unnoticed. Clients that do not want to request staples at all can clear jdk.tls.client.enableStatusRequestExtension. The TLS 1.2 client path is unchanged. See github issue #1157.</li>
189
+
<li>BCJSSE: the provider now offers server-side OCSP stapling, completing for the JSSE layer what the previous entry describes for the low-level TLS API. With the boolean system property jdk.tls.server.enableStatusRequestExtension set to true - default false, as in SunJSSE, since enabling it has the server make outbound OCSP requests on behalf of whoever connects to it - a BCJSSE server answers a client's "status_request" (RFC 6066 sec. 8) and "status_request_v2" (RFC 6961 sec. 2.2) extensions. For TLS 1.2 it sends a certificate_status message, preferring an ocsp_multi list covering the end-entity and every intermediate that has an issuer in the chain, and falling back to a single ocsp response for the end-entity; per RFC 6961 sec. 2.2 that list may be shorter than the certificate list and an element may be zero-length where no response is held. For TLS 1.3 there is no such message and the response instead rides in a "status_request" extension of the CertificateEntry it belongs to, holding an RFC 6066 CertificateStatus, per RFC 8446 sec. 4.4.2.1; status_request_v2 is deprecated there and is not honoured. A status request naming particular responders in its responder_id_list is left unanswered rather than answered with what some other responder said. Responses are fetched over HTTP per RFC 6960 App. A.1 from the responder named by each certificate's Authority Information Access extension - or from jdk.tls.stapling.responderURI when jdk.tls.stapling.responderOverride is set - read subject to the existing org.bouncycastle.ocsp.max_response_size ceiling, and discarded unless they carry a response bound to the certificate asked about. They are held in a per-SSLContext cache: a response is reused only while within both its own nextUpdate and jdk.tls.stapling.cacheLifetime, one stating no nextUpdate is stapled but never cached (RFC 6960 sec. 4.2.2.1 has an absent nextUpdate mean newer information is available all the time), and one dated more than the fifteen minute clock-skew allowance ahead of local time is treated as unreliable and not stapled at all. At most one request is in flight per certificate however many handshakes are waiting on it, a failed lookup suppresses further attempts for a short interval, and a handshake's wait is bounded by jdk.tls.stapling.responseTimeout - exactly, for one waiting on another's fetch; to within a read already in flight, for the one performing it, since a read timeout bounds each read rather than the exchange - a missing staple being an optimisation forgone, never a handshake failure. The server does not verify what it relays; verifying the response is the receiving client's part. On the client side a BCJSSE client now also reads TLS 1.3 staples, which BCExtendedSSLSession.getStatusResponses() returns positionally against the certificate chain - one element per certificate, zero-length where an entry carried no response - so that ProvX509TrustManager pairs each response with the certificate it answers for when handing them to the CertPath validator. Note this makes a client stricter about what a server sends it: RFC 8446 sec. 4.4.2.1 admits only a CertificateStatus of type ocsp in a CertificateEntry's "status_request" extension, so an extension carrying anything else - trailing bytes, the ocsp_multi form of the deprecated status_request_v2, an unparseable body - now fails the handshake with a decode_error alert, where previously these extension bodies were not read at all and a server that mis-stapled went unnoticed. Clients that do not want to request staples at all can clear jdk.tls.client.enableStatusRequestExtension. The TLS 1.2 client path is unchanged. See github issue #1157, and #1485 for the client-side TLS 1.3 read.</li>
0 commit comments