RFR: 8314891: Additional Zip64 extra header validation
Andrey Turbanov
aturbanov at openjdk.org
Tue Sep 12 08:49:41 UTC 2023
On Sat, 9 Sep 2023 14:33:53 GMT, Lance Andersen <lancea at openjdk.org> wrote:
> Please review this PR which improves the Zip64 extra header validation:
>
> - Throw a ZipException If the extra len field is 0 and :
> -- size, csize, or loc offset are set to 0xFFFFFFFF
> -- disk starting number is set to 0xFFFF
>
> - We have a valid size for the Zip64 extra header but we are missing the csize or loc fields if they are expected to be part of the header
>
> Mach5 tiers 1-3 are clean
test/jdk/java/util/zip/ZipFile/MissingZIP64EntriesTest.java line 198:
> 196: * actual value is stored in the Zip64 Extra Header
> 197: */
> 198: private static final int ZIP64_MAGICCOUNT = 0xFFFF;
Suggestion:
private static final int ZIP64_MAGICCOUNT = 0xFFFF;
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/15650#discussion_r1322670868
More information about the core-libs-dev
mailing list