Uploaded image for project: 'Commons Compress'
  1. Commons Compress
  2. COMPRESS-621

ZipFile does not support prepending additional data to the zip content

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 1.21
    • 1.23.0
    • Archivers
    • None

    Description

      In general, Zip files support placing arbitrary content before their body without affecting their compliance.

      Here is an example:

      https://github.com/huanghongxun/HMCL/releases/download/v3.5.2.218/HMCL-3.5.2.218.exe

       

      This is actually a jar file, but we prepend an exe launcher to it, so it can be used both as a jar and as an exe.

      java.util.zip.ZipFile can open and read it normally, but org.apache.commons.compress.archivers.zip.ZipFile can open it but cannot read any entries.

       

      Attachments

        Activity

          People

            Unassigned Unassigned
            Glavo Glavo
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0h
                0h
                Logged:
                Time Spent - 50m
                50m