RFR: 8278349: JarSigner javadoc example uses SHA-1

Sean Mullan mullan at openjdk.org
Fri Jan 13 17:00:15 UTC 2023


On Fri, 13 Jan 2023 16:40:03 GMT, Weijun Wang <weijun at openjdk.org> wrote:

>> Please review this trivial PR which updates javadoc sample code in jdk.security.jarsigner.JarSigner to use SHA-256, SHA256withRSA instead of the now considered weak algorithms SHA-1, SHA1withDSA.
>> 
>> The sample code is also updated to use the new snippet syntax.
>
> src/jdk.jartool/share/classes/jdk/security/jarsigner/JarSigner.java line 88:
> 
>> 86:  *     signer.sign(in, out);
>> 87:  * }
>> 88:  * }
> 
> You can probably indent the code so that the last 2 lines do not look strange.

This might also be a good opportunity to use the new javadoc @snippet tag (see [JEP 413](url)) which I think has some features to handle the indentation in a consistent manner.

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

PR: https://git.openjdk.org/jdk/pull/11992



More information about the security-dev mailing list