RFR: 8346285: Update jarsigner compatibility test for change in default digest algorithm [v2]

Matthew Donovan mdonovan at openjdk.org
Mon Dec 16 15:29:15 UTC 2024


On Mon, 16 Dec 2024 15:05:38 GMT, Weijun Wang <weijun at openjdk.org> wrote:

>> Matthew Donovan has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   updated to use JarSigner.Builder.getDefaultDigestAlgorithm()
>
> test/jdk/sun/security/tools/jarsigner/compatibility/Compatibility.java line 1442:
> 
>> 1440: 
>> 1441:         String expectedTsaDigestAlg() {
>> 1442:             return tsaDigestAlgorithm != null ? tsaDigestAlgorithm : "SHA-256";
> 
> You can actually get it from `jdk.security.jarsigner.JarSigner.Builder.getDefaultDigestAlgorithm()`.

I updated the code to use `getDefaultDigestAlgorithm` but I still need the version-check because this test invokes jarsigner in different JDKs that use different default algorithms.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/22765#discussion_r1887015650


More information about the security-dev mailing list