Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8277087

ZipException: zip END header not found at ZipFile#Source.findEND

XMLWordPrintable

    • b26
    • generic
    • generic
    • Verified

        The ZipOutputStream class may be used to a bad zip file. The root cause is how the comment field is stored by the ZipOutputStream. According to the zip specification, the comment field should not be longer than 0xFFFF bytes, and we try to validate the length of the comment, but unfortunately, we do this after the comment was assigned already. So if the application saves the comment based on the user's input and then gets an exception from the ZipOutputStream.setComment() it may assume that the comment is too long and it will be ignored, but it will be saved as-is to the file.

              serb Sergey Bylokhov
              serb Sergey Bylokhov
              Votes:
              0 Vote for this issue
              Watchers:
              9 Start watching this issue

                Created:
                Updated:
                Resolved: