April 15, 2025
The full version string for this update release is 21.0.7+8 (where "+" means "build"). The version number is 21.0.7. This JDK conforms to version 21 of the Java SE Specification (JSR 396 2023-09-19).
JDK 21.0.7 contains IANA time zone data 2025a which contains the following changes:
For more information, refer to Timezone Data Versions in the JRE Software.
The security baselines for the Java Runtime Environment (JRE) at the time of the release of JDK 21.0.7 are specified in the following table:
Java Family Version | Security Baseline (Full Version String) |
---|---|
21 | 21.0.7+8 |
17 | 17.0.15+9 |
11 | 11.0.27+8 |
8 | 1.8.0_451-b10 |
Oracle recommends that the JDK is updated with each Critical Patch Update. In order to determine if a release is the latest, the Security Baseline page can be used to determine which is the latest version for each release family.
Critical patch updates, which contain security vulnerability fixes, are announced one year in advance on Critical Patch Updates, Security Alerts and Bulletins. It is not recommended that this JDK (version 21.0.7) be used after the next critical patch update scheduled for July 15, 2025.
Java Management Service, available to all users, can help you find vulnerable Java versions in your systems. Java SE Subscribers and customers running in Oracle Cloud can use Java Management Service to update Java Runtimes and to do further security reviews like identifying potentially vulnerable third party libraries used by your Java programs. Existing Java Management Service user click here to log in to your dashboard. The Java Management Service Documentation provides a list of features available to everyone and those available only to customers. Learn more about using Java Management Service to monitor and secure your Java Installations.
Native PKCS11 mechanisms which support decryption but not encryption, or signature verification but not signing, are considered legacy and are disabled by default. The legacy mechanism check in SunPKCS11 provider is enhanced with the service type. For example, prior to this fix, a mechanism supporting encryption, decryption, and verification but not signing, is considered legacy and can't be used at all. After this fix, the corresponding Cipher service using this mechanism is available since both encryption and decryption are supported. However, the corresponding Signature service is not since only verification is supported. To bypass the legacy mechanism check, set the PKCS11 provider configuration attribute "allowLegacy" to true. The default value is false. Note that it is the caller's responsibility to make sure the legacy mechanism is not used for the unsupported functionality.
The JDK will stop trusting TLS server certificates issued after April 15, 2025 and anchored by Camerfirma root certificates, in line with similar plans announced by Google, Mozilla, Apple, and Microsoft.
TLS server certificates issued on or before April 15, 2025 will continue to be trusted until they expire. Certificates issued after that date, and anchored by any of the Certificate Authorities in the table below, will be rejected.
The restrictions are enforced in the JDK implementation (the SunJSSE
Provider) of the Java Secure Socket Extension (JSSE) API. A TLS session will not be negotiated if the server's certificate chain is anchored by any of the Certificate Authorities in the table below and the certificate has been issued after April 15, 2025.
An application will receive an exception with a message indicating the trust anchor is not trusted, for example:
"TLS Server certificate issued after 2025-04-15 and anchored by a distrusted legacy Camerfirma root CA: CN=Chambers of Commerce Root - 2008, O=AC Camerfirma S.A.,
SERIALNUMBER=A82743287, L=Madrid (see current address at www.camerfirma.com/address), C=EU"
The JDK can be configured to trust these certificates again by removing "CAMERFIRMA_TLS" from the jdk.security.caDistrustPolicies
security property in the java.security
configuration file.
The restrictions are imposed on the following Camerfirma Root certificates included in the JDK:
Distinguished Name | SHA-256 Fingerprint |
---|---|
CN=Chambers of Commerce Root, OU=http://www.chambersign.org, O=AC Camerfirma SA CIF A82743287, C=EU |
0C:25:8A:12:A5:67:4A:EF:25:F2:8B:A7:DC:FA:EC:EE:A3:48:E5:41:E6:F5:CC:4E:E6:3B:71:B3:61:60:6A:C3 |
CN=Chambers of Commerce Root - 2008, O=AC Camerfirma S.A., SERIALNUMBER=A82743287, L=Madrid (see current address at www.camerfirma.com/address), C=EU |
06:3E:4A:FA:C4:91:DF:D3:32:F3:08:9B:85:42:E9:46:17:D8:93:D7:FE:94:4E:10:A7:93:7E:E2:9D:96:93:C0 |
CN=Global Chambersign Root - 2008, O=AC Camerfirma S.A., SERIALNUMBER=A82743287, L=Madrid (see current address at www.camerfirma.com/address), C=EU |
13:63:35:43:93:34:A7:69:80:16:A0:D3:24:DE:72:28:4E:07:9D:7B:52:20:BB:8F:BD:74:78:16:EE:BE:BA:CA |
You can also use the keytool
utility from the JDK to print out details of the certificate chain, as follows:
keytool -v -list -alias <your_server_alias> -keystore <your_keystore_filename>
If any of the certificates in the chain are issued by one of the root CAs in the table above are listed in the output you will need to update the certificate or contact the organization that manages the server.
The JarInputStream
class now treats a signed JAR as unsigned if it detects a second manifest within the first two entries in the JAR file. A warning message "WARNING: Multiple MANIFEST.MF found. Treat JAR file as unsigned."
is logged if the system property, -Djava.security.debug=jar
, is set.
An existing bug may have prevented the full usage of the Java heap allotted with the command line flag -Xmx
. That bug has been fixed with JDK-8328744. As a side effect of this fix, installations may experience an increased heap usage when using Parallel GC. Customers should, if necessary, adjust the maximum heap size.
JDK 17 introduced a performance improvement that made OCSP clients unconditionally use GET requests for small requests, while doing POST requests for everything else. This is explicitly allowed and recommended by RFC 5019 and RFC 6960. However, we have seen OCSP responders that, despite RFC requirements, are not working well with GET requests.
This release introduces a new JDK system property to allow clients to fallback to POST-only behavior. This unblocks interactions with those OCSP responders through the use of -Dcom.sun.security.ocsp.useget={false,true}
. This amends the original change that introduced GET OCSP requests (JDK-8179503). The default behavior is not changed; the option defaults to true
. Set the option to false
to disable GET OCSP requests. Any value other than false
(case-insensitive) defaults to true
.
This option is non-standard, and might go away once problematic OCSP responders get upgraded.
This release also contains fixes for security vulnerabilities described in the Oracle Critical Patch Update.
➜ Issues fixed in 21.0.7:# | JBS | Component/Subcomponent | Summary |
---|---|---|---|
1 | JDK-8312518 | client-libs/java.awt | [macos13] setFullScreenWindow() shows black screen on macOS 13 & above |
2 | JDK-8335468 | client-libs/java.awt | [XWayland] JavaFX hangs when calling java.awt.Robot.getPixelColor |
3 | JDK-8283214 | client-libs/javax.accessibility | [macos] Screen magnifier does not show the magnified text for JComboBox |
4 | JDK-8339728 | client-libs/javax.accessibility | [Accessibility,Windows,JAWS] Bug in the getKeyChar method of the AccessBridge class |
5 | JDK-8332866 | client-libs/javax.imageio | Crash in ImageIO JPEG decoding when MEM_STATS in enabled |
6 | JDK-8347911 | client-libs/javax.imageio | Limit the length of inflated text chunks |
7 | JDK-8332431 | client-libs/javax.swing | NullPointerException in JTable of SwingSet2 |
8 | JDK-8340824 | hotspot/compiler | C2: Memory for TypeInterfaces not reclaimed by hashcons() |
9 | JDK-8337660 | hotspot/compiler | C2: basic blocks with only BoxLock nodes are wrongly treated as empty |
10 | JDK-8340313 | hotspot/compiler | Crash due to invalid oop in nmethod after C1 patching |
11 | JDK-8331090 | hotspot/compiler | Run Ideal_minmax before de-canonicalizing CMoves |
12 | JDK-8324655 | hotspot/compiler | Identify integer minimum and maximum patterns created with if statements |
13 | JDK-8338100 | hotspot/compiler | C2: assert(!n_loop->is_member(get_loop(lca))) failed: control must not be back in the loop |
14 | JDK-8322957 | hotspot/gc | Generational ZGC: Relocation selection must join the STS |
15 | JDK-8170817 | hotspot/gc | G1: Returning MinTLABSize from unsafe_max_tlab_alloc causes TLAB flapping |
16 | JDK-8328168 | hotspot/gc | Epsilon: Premature OOM when allocating object larger than uncommitted heap size |
17 | JDK-8328166 | hotspot/gc | Epsilon: 'EpsilonHeap::allocate_work' misuses the parameter 'size' as size in bytes |
18 | JDK-8315031 | hotspot/gc | YoungPLABSize and OldPLABSize not aligned by ObjectAlignmentInBytes |
19 | JDK-8329570 | hotspot/gc | G1: Excessive is_obj_dead_cond calls in verification |
20 | JDK-8329223 | hotspot/gc | Parallel: Parallel GC resizes heap even if -Xms = -Xmx |
21 | JDK-8330981 | hotspot/gc | ZGC: Should not dedup strings in the finalizer graph |
22 | JDK-8330275 | hotspot/gc | Crash in XMark::follow_array |
23 | JDK-8329088 | hotspot/gc | Stack chunk thawing races with concurrent GC stack iteration |
24 | JDK-8329109 | hotspot/gc | Threads::print_on() tries to print CPU time for terminated GC threads |
25 | JDK-8325937 | hotspot/runtime | runtime/handshake/HandshakeDirectTest.java causes "monitor end should be strictly below the frame pointer" assertion failure on AArch64 |
26 | JDK-8344145 | hotspot/test | Remove windows_x64_1803_or_later and it's usages in task definitions |
27 | JDK-8335288 | security-libs/javax.crypto:pkcs11 | SunPKCS11 initialization will call C_GetMechanismInfo on unsupported mechanisms |
28 | JDK-8331959 | security-libs/javax.crypto:pkcs11 | Update PKCS#11 Cryptographic Token Interface to v3.1 |
29 | JDK-8331958 | security-libs/javax.smartcardio | Update PC/SC Lite for Suse Linux to 2.3.0 |