-
CSR
-
Resolution: Approved
-
P4
-
None
-
source
-
minimal
-
-
Java API
-
SE
Summary
Remove the final keyword from the static java.security.cert.CertStore::getDefaultType() method. Remove InvalidParameterException from the throws clause of the java.security.interfaces.DSAKeyPairGenerator::initialize() methods.
Problem
As part of JDK-8302493, two changes were made that changed the signature of public APIs:
The
finalkeyword was inadvertently removed from thestaticjava.security.cert.CertStore::getDefaultType()method as part of this change. However, this change has an extremely low compatibility risk and we have decided not to revert the change. There is no security risk to removing this keyword. The behavior of code currently calling this method will not be affected if a subclass now overrides the method.Going forward, we will do a broader analysis of other
publicfinalstaticmethods in the security libs area and determine if any changes should be made. If there is consensus that thefinalkeyword should be subsequently restored for this method, we will consider making that change and filing a CSR in the next JDK release.The signature of the two
java.security.interfaces.DSAKeyPairGenerator::initialize()methods were changed to not throwInvalidParameterException. This associated change has no behavioral impact.InvalidParameterExceptionis aRuntimeExceptionand was already specified in a javadoc@throwsclause of these methods.
Solution
Remove the final keyword from the static java.security.cert.CertStore::getDefaultType() method. Remove InvalidParameterException from the throws clause of the java.security.interfaces.DSAKeyPairGenerator::initialize() methods.
Specification
Changes for java.security.cert.CertStore:
- public static final String getDefaultType() {
- public static String getDefaultType() {
Changes for java.security.interfaces.DSAKeyPairGenerator:
- public void initialize(DSAParams params, SecureRandom random)
- throws InvalidParameterException;
+ void initialize(DSAParams params, SecureRandom random);
- public void initialize(int modlen, boolean genParams, SecureRandom random)
- throws InvalidParameterException;
+ void initialize(int modlen, boolean genParams, SecureRandom random);
- csr of
-
JDK-8285263 Minor cleanup could be done in java.security
-
- Resolved
-
- relates to
-
JDK-8302696 Revert API signature changes made in JDK-8285504 and JDK-8285263
-
- Resolved
-