[jdk8u-dev] RFR: 8186464: ZipFile cannot read some InfoZip ZIP64 zip files

fitzsim duke at openjdk.org
Fri Apr 5 16:57:10 UTC 2024


On Tue, 20 Feb 2024 20:40:13 GMT, Andrew John Hughes <andrew at openjdk.org> wrote:

> This is a re-do of #445 as we reached a deadlock where I could not make myself commit author, as I was not the PR author, and Thomas could not make me the author as he was not a Committer (see [SKARA-2173](https://bugs.openjdk.org/browse/SKARA-2173)). The content remains the same.
> 
> What follows is Thomas' introduction from the original PR:
> 
> This patch was applied to the Red Hat 1.8.0 RPMs in June 2020, so it has been deployed to Red Hat customers for over three years.
> 
> I verified that the patch applies cleanly to jdk8u-dev master. I confirmed that with the fix portion of the patch reverted, the ReadZip.java test portion of the patch produces this exception:
> 
> ~~~
> java.lang.RuntimeException: zipfile: zip64 end failed
> 	at ReadZip.main(ReadZip.java:209)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> 	at java.lang.reflect.Method.invoke(Method.java:498)
> 	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
> 	at java.lang.Thread.run(Thread.java:750)
> ~~~
> 
> With the fix applied the test passes:
> 
> ~~~
> Passed: java/util/zip/ZipFile/ReadZip.java
> ~~~
> 
> With the patch applied on top of jdk8u-dev master tip, 3dc011b7ff955f6c1334058f300708412b21a3ad, `make test` on Fedora 38 x86-64 passes, with:
> ~~~
> Test results: passed: 3,122
> ~~~
> I also retested the test cases in [JDK-8186464](https://bugs.openjdk.org/browse/JDK-8186464) and confirmed that without this backport, they fail, and with the backport they succeed.
> 
> Thank you,
> Thomas

I will also investigate whether the `zip_util.c` changes in @gnu-andrew's commit, https://github.com/openjdk/jdk8u-dev/pull/452/commits/462cd916c26f9745abca2cfd78ed8d1107db9f0c, should be a separate backport.

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

PR Comment: https://git.openjdk.org/jdk8u-dev/pull/452#issuecomment-2040259310


More information about the jdk8u-dev mailing list