Skip to content

Upgrade zip to 9.x in elastos-server and remove the cargo-audit exception (RUSTSEC-2026-0367/0368/0369) #414

Open

Description

@andersalm

zip 2.4.2, a dependency of elastos-server, has three advisories. RustSec lists them as fixed in 9.0.0, but upstream GHSA-4684-h2q9-2vcp (RUSTSEC-2026-0369) names 9.0.1 as the first fixed release:

  • RUSTSEC-2026-0367: SUID and SGID bits are kept during extraction.
  • RUSTSEC-2026-0368: ZipArchive::extract creates symlinks that point outside the destination.
  • RUSTSEC-2026-0369: ZipArchive::extract and ZipStreamReader::extract apply permissions through symlinks.

develop CI 39011766190 on the 0.8.0-alpha.23 candidate 63f57e341 failed cargo-audit on elastos/Cargo.lock and capsules/object-provider/Cargo.lock because of them (17 Oct).

Why 0.8.0 ships with an exception: ElastOS never calls the affected functions. library.rs reads ZIP entries with ZipArchive::by_index. Its own extraction (extract_zip_archive, write_selected_archive_file) refuses symlink entries and writes bytes without archive permission bits. ZipWriter builds archives in memory. No code calls extract, ZipStreamReader or unix_mode. The three IDs are therefore listed in elastos/.cargo/audit.toml with that reason. Upgrading the Library's archive parser inside the release candidate would change how users' ZIP files preview, after review and installed checks.

Done means:

  • elastos-server uses zip 9.0.4 or later. ZipFile::name() returns a Result there; the Library preview and listing code and its tests handle it (library.rs around lines 4242, 4460 and 4942, and gateway_tests/library.rs:895).
  • The three IDs are removed from elastos/.cargo/audit.toml, and the file is deleted if they are its only entries.
  • cargo-audit is green on every lockfile, and the Library ZIP preview, listing and download tests pass.
  • Mac smoke: preview and download a ZIP in Library.

Activity

  1. added this to the After 0.8.0 milestone on Oct 17, 2026
  2. andersalm commented on Oct 17, 2026

    @andersalm
    ContributorAuthor

    Sasha's draft #417 (zip 9.x) is the change this issue needs, after 0.8.0. Upstream's first fixed release is 9.0.1. When #417 lands, also delete elastos/.cargo/audit.toml; the three IDs are its only entries.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions