{"id":"UBUNTU-CVE-2026-85396","details":"rubyzip versions before 3.4.0 contain a path traversal vulnerability in Zip::Entry#extract that fails to properly validate extraction paths using prefix comparison without trailing separators. Attackers can craft archive entries with names like ../upload_backup/owned.sh to write files outside the intended extraction directory into sibling paths sharing the destination prefix.","modified":"2026-09-16T11:43:10Z","published":"2026-09-03T19:17:00Z","upstream":["CVE-2026-85396"],"references":[{"type":"REPORT","url":"https://ubuntu.com/security/CVE-2026-85396"},{"type":"REPORT","url":"https://www.cve.org/CVERecord?id=CVE-2026-85396"},{"type":"REPORT","url":"https://github.com/rubyzip/rubyzip/issues/664"},{"type":"REPORT","url":"https://github.com/geo-chen/oss/blob/main/rubyzip.md"},{"type":"REPORT","url":"https://github.com/rubyzip/rubyzip"},{"type":"REPORT","url":"https://github.com/rubyzip/rubyzip/blob/v3.3.1/lib/zip/entry.rb"},{"type":"REPORT","url":"https://github.com/rubyzip/rubyzip/commit/17edfbf4423b83211b075acc23a7d8640da63449"},{"type":"REPORT","url":"https://github.com/rubyzip/rubyzip/releases/tag/v3.4.0"},{"type":"REPORT","url":"https://www.vulncheck.com/advisories/rubyzip-before-3.4.0-path-traversal-in-zip-entry-extract-via-sibling-directory-prefix"}],"affected":[{"package":{"name":"ruby-zip","ecosystem":"Ubuntu:16.04:LTS","purl":"pkg:deb/ubuntu/ruby-zip?arch=source&distro=xenial"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.1.7-1"],"ecosystem_specific":{"binaries":[{"binary_name":"ruby-zip","binary_version":"1.1.7-1"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-85396.json"}},{"package":{"name":"ruby-zip","ecosystem":"Ubuntu:18.04:LTS","purl":"pkg:deb/ubuntu/ruby-zip?arch=source&distro=bionic"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.2.1-1","1.2.1-1.1~build0.18.04.1"],"ecosystem_specific":{"binaries":[{"binary_name":"ruby-zip","binary_version":"1.2.1-1.1~build0.18.04.1"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-85396.json"}},{"package":{"name":"ruby-zip","ecosystem":"Ubuntu:20.04:LTS","purl":"pkg:deb/ubuntu/ruby-zip?arch=source&distro=focal"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.2.2-1","2.0.0-2"],"ecosystem_specific":{"binaries":[{"binary_version":"2.0.0-2","binary_name":"ruby-zip"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-85396.json"}},{"package":{"name":"ruby-zip","ecosystem":"Ubuntu:22.04:LTS","purl":"pkg:deb/ubuntu/ruby-zip?arch=source&distro=jammy"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["2.0.0-2","2.3.0-2"],"ecosystem_specific":{"binaries":[{"binary_name":"ruby-zip","binary_version":"2.3.0-2"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-85396.json"}},{"package":{"name":"ruby-zip","ecosystem":"Ubuntu:24.04:LTS","purl":"pkg:deb/ubuntu/ruby-zip?arch=source&distro=noble"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["2.3.2-1"],"ecosystem_specific":{"binaries":[{"binary_name":"ruby-zip","binary_version":"2.3.2-1"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-85396.json"}},{"package":{"name":"ruby-zip","ecosystem":"Ubuntu:26.04:LTS","purl":"pkg:deb/ubuntu/ruby-zip?arch=source&distro=resolute"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["2.3.2-1","3.2.2-1","3.2.2-2"],"ecosystem_specific":{"binaries":[{"binary_name":"ruby-zip","binary_version":"3.2.2-2"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-85396.json"}}],"schema_version":"1.9.0","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N"},{"type":"CVSS_V4","score":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N"},{"type":"Ubuntu","score":"medium"}]}