{"id":"CVE-2021-32841","details":"SharpZipLib (or #ziplib) is a Zip, GZip, Tar and BZip2 library. Starting version 1.3.0 and prior to version 1.3.3, a check was added if the destination file is under destination directory. However, it is not enforced that `destDir` ends with slash. If the `destDir` is not slash terminated like `/home/user/dir` it is possible to create a file with a name thats begins with the destination 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 contains a patch for this vulnerability.","aliases":["GHSA-2x7h-96h5-rq84"],"modified":"2026-07-08T21:27:01.068301Z","published":"2022-01-26T22:15:07.837Z","references":[{"type":"ADVISORY","url":"https://github.com/icsharpcode/SharpZipLib/releases/tag/v1.3.3"},{"type":"FIX","url":"https://github.com/icsharpcode/SharpZipLib/commit/5c3b293de5d65b108e7f2cd0ea8f81c1b8273f78"},{"type":"EVIDENCE","url":"https://securitylab.github.com/advisories/GHSL-2021-125-sharpziplib/"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://github.com/icsharpcode/sharpziplib","events":[{"introduced":"8f7d89201afa13c814f9b3d1813884ffe0ec7025"},{"fixed":"1b1ab013ce1df02d8f27cf582197759c614d9126"},{"fixed":"5c3b293de5d65b108e7f2cd0ea8f81c1b8273f78"}],"database_specific":{"cpe":"cpe:2.3:a:sharpziplib_project:sharpziplib:*:*:*:*:*:*:*:*","extracted_events":[{"introduced":"1.3.0"},{"fixed":"1.3.3"}],"source":["CPE_RANGE","REFERENCES"]}}],"versions":["v1.3.2","v1.3.1","v1.3.0"],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2021-32841.json"}}],"schema_version":"1.7.5","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N"}]}