{"id":"UBUNTU-CVE-2026-13705","details":"Imager versions before 1.032 for Perl have a heap out-of-bounds read in the bundled Imager::File::SGI reader via a 16-bit RLE literal run in read_rgb_16_rle. read_rgb_16_rle guards each literal run with if (count \u003e data_left), but count is a pixel count while every 16-bit sample consumes two bytes. The copy loop reads inp[0] * 256 + inp[1] and advances two bytes per pixel, so a run with data_left / 2 \u003c count \u003c= data_left passes the guard yet consumes 2 * count bytes and reads past the end of the buffer. The 8-bit path is unaffected because there one pixel is one byte. Reading a crafted SGI image through Imager-\u003eread triggers the over-read before the parser rejects the malformed image, which can crash the process.","modified":"2026-07-09T17:15:13.588716738Z","published":"2026-07-06T13:16:00Z","upstream":["CVE-2026-13705"],"references":[{"type":"REPORT","url":"https://ubuntu.com/security/CVE-2026-13705"},{"type":"REPORT","url":"https://www.cve.org/CVERecord?id=CVE-2026-13705"},{"type":"REPORT","url":"https://lists.security.metacpan.org/cve-announce/msg/41572386/"}],"affected":[{"package":{"name":"libimager-perl","ecosystem":"Ubuntu:16.04:LTS","purl":"pkg:deb/ubuntu/libimager-perl?arch=source&distro=xenial"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.003+dfsg-1","1.004+dfsg-1","1.004+dfsg-1build1"],"ecosystem_specific":{"binaries":[{"binary_name":"libimager-perl","binary_version":"1.004+dfsg-1build1"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-13705.json"}},{"package":{"name":"libimager-perl","ecosystem":"Ubuntu:18.04:LTS","purl":"pkg:deb/ubuntu/libimager-perl?arch=source&distro=bionic"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.005+dfsg-2build1","1.006+dfsg-1"],"ecosystem_specific":{"binaries":[{"binary_name":"libimager-perl","binary_version":"1.006+dfsg-1"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-13705.json"}},{"package":{"name":"libimager-perl","ecosystem":"Ubuntu:20.04:LTS","purl":"pkg:deb/ubuntu/libimager-perl?arch=source&distro=focal"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.011+dfsg-1","1.011+dfsg-1build1"],"ecosystem_specific":{"binaries":[{"binary_version":"1.011+dfsg-1build1","binary_name":"libimager-perl"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-13705.json"}},{"package":{"name":"libimager-perl","ecosystem":"Ubuntu:22.04:LTS","purl":"pkg:deb/ubuntu/libimager-perl?arch=source&distro=jammy"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.012+dfsg-1build1","1.012+dfsg-2","1.012+dfsg-2build1"],"ecosystem_specific":{"binaries":[{"binary_version":"1.012+dfsg-2build1","binary_name":"libimager-perl"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-13705.json"}},{"package":{"name":"libimager-perl","ecosystem":"Ubuntu:24.04:LTS","purl":"pkg:deb/ubuntu/libimager-perl?arch=source&distro=noble"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.019+dfsg-2","1.020+dfsg-1","1.022+dfsg-1","1.023+dfsg-1","1.023+dfsg-1build1","1.023+dfsg-1build2"],"ecosystem_specific":{"binaries":[{"binary_name":"libimager-perl","binary_version":"1.023+dfsg-1build2"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-13705.json"}},{"package":{"name":"libimager-perl","ecosystem":"Ubuntu:25.10","purl":"pkg:deb/ubuntu/libimager-perl?arch=source&distro=questing"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.027+dfsg-1"],"ecosystem_specific":{"binaries":[{"binary_version":"1.027+dfsg-1","binary_name":"libimager-perl"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-13705.json"}},{"package":{"name":"libimager-perl","ecosystem":"Ubuntu:26.04:LTS","purl":"pkg:deb/ubuntu/libimager-perl?arch=source&distro=resolute"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.027+dfsg-1","1.029+dfsg-1"],"ecosystem_specific":{"binaries":[{"binary_name":"libimager-perl","binary_version":"1.029+dfsg-1"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-13705.json"}}],"schema_version":"1.7.5","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:H"},{"type":"Ubuntu","score":"medium"}]}