On Mon, 11 Dec 2023 15:38:28 GMT, Eirik Bjorsnos <d...@openjdk.org> wrote:

> Please review this PR which adds validation of incorrect LOC signatures in 
> `ZipFileSystem`.
> 
> `ZipFile` already rejects the case where the  offset pointed to from the CEN 
> header does not start with the expected LOC signature. It makes sense to add 
> this check to `ZipFileSystem` as well.

src/jdk.zipfs/share/classes/jdk/nio/zipfs/ZipFileSystem.java line 2579:

> 2577:                 }
> 2578:                 if (LOCSIG(buf) != LOCSIG) {
> 2579:                     throw new ZipException("invalid loc header (bad 
> signature)");

Please change loc -> LOC

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

PR Review Comment: https://git.openjdk.org/jdk/pull/17059#discussion_r1423879142

Reply via email to