You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "nick allen (Jira)" <ji...@apache.org> on 2022/03/01 08:10:00 UTC
[jira] [Commented] (COMPRESS-605) Failed to parse Non-zip64 signed apk with data descriptor
[ https://issues.apache.org/jira/browse/COMPRESS-605?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17499380#comment-17499380 ]
nick allen commented on COMPRESS-605:
-------------------------------------
Turns out my client recompress the apk. I will try to fix this in my own project. Should I submit a PR for that(normal apk won't have data descriptor)?
> Failed to parse Non-zip64 signed apk with data descriptor
> ---------------------------------------------------------
>
> Key: COMPRESS-605
> URL: https://issues.apache.org/jira/browse/COMPRESS-605
> Project: Commons Compress
> Issue Type: Bug
> Components: Archivers
> Affects Versions: 1.21
> Reporter: nick allen
> Priority: Major
>
> I can't upload my apk due to security policy of my company, but I do find where the problem lies.
> In org.apache.commons.compress.archivers.zip.ZipArchiveInputStream#readDataDescriptor we check whether following bytes are signaures to determine whethere size is 8 bytes or 4 bytes. Because what following is apk signing block so it will always thought "size" takes 8 bytes.
> So (4 + 4 = 8) extra bytes were read. Which leading to org.apache.commons.compress.archivers.zip.ZipArchiveInputStream#isApkSigningBlock also return false.
--
This message was sent by Atlassian Jira
(v8.20.1#820001)