RFR: 8253176: Signature.getParameters should specify that it can throw UnsupportedOperationException [v4]

Sean Mullan mullan at openjdk.java.net
Tue May 10 20:47:12 UTC 2022


On Mon, 9 May 2022 18:45:05 GMT, Valerie Peng <valeriep at openjdk.org> wrote:

>> This is to update the method javadoc of java.security.Signature.getParameters() with the missing `@throws UnsupportedOperationException`. In addition, the wording on the returned parameters are updated to match those in Cipher and CipherSpi classes. 
>> 
>> CSR will be filed later.
>> 
>> Thanks,
>> Valerie
>
> Valerie Peng has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains four additional commits since the last revision:
> 
>  - Merge branch 'master' of https://github.com/openjdk/jdk into JDK-8253176
>  - Sync'ed w/ the wording in the other Cipher.getParameters() PR.
>  - Undo un-intentional changes.
>  - 8253176: Signature.getParameters should specify that it can throw UnsupportedOperationException

src/java.base/share/classes/java/security/SignatureSpi.java line 399:

> 397:      * values used by the underlying signature scheme. If the required
> 398:      * parameters were not supplied and can be generated by the signature,
> 399:      * the generated parameters will be returned. Otherwise, {@code null}

Minor wording nit - change "will be" to "are" to be consistent with other wording which uses the present tense. Same comment applies to `Signature.getParameters`.

Also, do we no longer need to mention the part "and the underlying signature implementation supports returning the parameters as {@code AlgorithmParameters}"?

-------------

PR: https://git.openjdk.java.net/jdk/pull/8396



More information about the security-dev mailing list