Skip to content

trailing-zip support broken for zip64 files #151

@CosmicHorrorDev

Description

@CosmicHorrorDev

Describe the bug

an archive that's both a trailing-zip and zip64 file fails to open with rc-zip

To Reproduce

you can create a trailing-zip64 with

cat <(echo 'prepended text') testdata/zip64.zip > zip64.trailingzip

processing the archive fails with

Format(Directory64EndRecordInvalid) (format: zip64 end of central directory record not found)

Expected behavior

trailing-zip zip64 files to be supported. the same file works with Unzip 6.0 and ouch 0.6.1 (uses the zip crate)

Additional context

i noticed this while working on #148. i originally thought it was just a matter of accounting for the global-offset when applying the new offset from the zip64 extra field, but it looks like things are more involved than that. im more than happy to track down this bug later of course :)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions