CVEfocus › CVE database › CVE-2021-32842

CVE-2021-32842Path Traversal in SharpZipLib

CVSS 4.0 MediumEPSS 0.9% (higher than 59% of CVEs)Published 2022-01-26Updated 2025-04-22Assigner: GitHub_M

SharpZipLib (or #ziplib) is a Zip, GZip, Tar and BZip2 library. Starting version 1.0.0 and prior to version 1.3.3, a check was added if the destination file is under a destination directory. However, it is not enforced that `_baseDirectory` ends with slash. If the _baseDirectory is not slash terminated like `/home/user/dir` it is possible to create a file with a name thats begins as the destination directory one level up from the directory, i.e. `/home/user/dir.sh`. Because of the file name and destination directory constraints, the arbitrary file creation impact is limited and depends on the use case. Version 1.3.3 fixed this vulnerability.

CWE-22

What to do

Ubuntu has not shipped a fix for every release yet.

Is your server affected? One read-only command checks every installed package against this CVE and all others, using each vendor's fixed versions. Get started or get a free API key.

curl -sS "https://api.cvefocus.com/v1/check?format=text" -H "Authorization: Bearer $CVEFOCUS_KEY" \
  -H "Content-Type: text/plain" --data-binary @inventory.txt

Vendor status at a glance

1Fix pending
3Under investigation
5Will not fix

Status by vendor and release

From each vendor's own security data and VEX statements. "Fixed" means a fixed build is published for that release.

ReleasePackageStatusFixed versionAdvisory
Ubuntu 26.10monoFix pendingUBUNTU-CVE-2021-32842
Ubuntu 26.04monoUnder investigationUBUNTU-CVE-2021-32842
Ubuntu 25.10monoWill not fix
Ubuntu decided not to fix this in this release
UBUNTU-CVE-2021-32842
Ubuntu 24.04monoUnder investigationUBUNTU-CVE-2021-32842
Ubuntu 22.04monoUnder investigationUBUNTU-CVE-2021-32842
Ubuntu 20.04monoWill not fix
Ubuntu decided not to fix this in this release
UBUNTU-CVE-2021-32842
Ubuntu 18.04monoWill not fix
Ubuntu decided not to fix this in this release
UBUNTU-CVE-2021-32842
Ubuntu 16.04monoWill not fix
Ubuntu decided not to fix this in this release
UBUNTU-CVE-2021-32842
Ubuntu 14.04monoWill not fix
Ubuntu decided not to fix this in this release
UBUNTU-CVE-2021-32842

What the vendor says

As published in the CVE record by GitHub_M, the CVE's assigner (usually the vendor). Check the vendor's advisory before acting.

References

About this page

Compiled by CVEfocus from the CVE List, the security data and VEX statements of Ubuntu, Debian, Red Hat, AlmaLinux, Rocky Linux and Microsoft, CISA's Known Exploited Vulnerabilities catalog and FIRST EPSS, refreshed several times a day (data status). Information only; see the disclaimer. Official record: cve.org · NVD.