{"id":"CVE-2026-11526","state":"PUBLISHED","title":"GD versions before 2.86 for Perl allow OS command injection and file overwrite via a 2-arg open() of filename arguments in _make_filehandle","description":"GD versions before 2.86 for Perl allow OS command injection and file overwrite via a 2-arg open() of filename arguments in _make_filehandle.\n\nGD::Image::_make_filehandle opens a filename argument with Perl's 2-arg open(), so a filename that begins or ends with a pipe (\"| cmd\", \"cmd |\") or begins with a redirect (\"> path\", \">> path\") is run as a command or redirect rather than opened as a file. _make_filehandle is the single open path behind every filename-accepting constructor (new, newFromPng, newFromJpeg, and the rest); the in-memory *Data variants do not open a path and are unaffected.\n\nAny caller that forwards untrusted input to one of these constructors as a pathname can run an arbitrary command or truncate a file under the process UID.","publishedAt":"2026-06-14T11:39:21.122Z","updatedAt":"2026-06-21T13:34:16.065Z","severity":{"score":9.8,"label":"Critical","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","source":"CISA-ADP"},"assigner":"CPANSec","products":["RURBAN GD"],"affected":[{"vendor":"RURBAN","product":"GD","packageName":"GD","defaultStatus":"unaffected","versions":[{"version":"0","status":"affected","lessThan":"2.86","versionType":"custom"}],"collectionURL":"https://cpan.org/modules","programFiles":["lib/GD/Image.pm","lib/GD/Image_pm.PL"],"programRoutines":[{"name":"GD::Image::_make_filehandle"}],"repo":"https://github.com/lstein/Perl-GD"}],"references":["https://github.com/lstein/Perl-GD/commit/67b163713c6c78dfeb693da0978ae934e5cd8210.patch","https://metacpan.org/release/RURBAN/GD-2.86/changes","http://www.openwall.com/lists/oss-security/2026/06/14/4","https://lists.debian.org/debian-lts-announce/2026/06/msg00027.html"],"weaknesses":["CWE-78","CWE-73"],"ingestedAt":"2026-10-29T20:10:52.580Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/11xxx/CVE-2026-11526.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-11526","state":"PUBLISHED","datePublished":"2026-06-14T11:39:21.122Z","dateUpdated":"2026-06-21T13:34:16.065Z","assignerShortName":"CPANSec","assignerOrgId":"9b29abf9-4ab0-4765-b253-1875cd9b441e","dateReserved":"2026-06-07T19:26:46.259Z"},"containers":{"cna":{"title":"GD versions before 2.86 for Perl allow OS command injection and file overwrite via a 2-arg open() of filename arguments in _make_filehandle","descriptions":[{"lang":"en","value":"GD versions before 2.86 for Perl allow OS command injection and file overwrite via a 2-arg open() of filename arguments in _make_filehandle.\n\nGD::Image::_make_filehandle opens a filename argument with Perl's 2-arg open(), so a filename that begins or ends with a pipe (\"| cmd\", \"cmd |\") or begins with a redirect (\"> path\", \">> path\") is run as a command or redirect rather than opened as a file. _make_filehandle is the single open path behind every filename-accepting constructor (new, newFromPng, newFromJpeg, and the rest); the in-memory *Data variants do not open a path and are unaffected.\n\nAny caller that forwards untrusted input to one of these constructors as a pathname can run an arbitrary command or truncate a file under the process UID."}],"affected":[{"vendor":"RURBAN","product":"GD","packageName":"GD","defaultStatus":"unaffected","versions":[{"version":"0","status":"affected","lessThan":"2.86","versionType":"custom"}],"collectionURL":"https://cpan.org/modules","programFiles":["lib/GD/Image.pm","lib/GD/Image_pm.PL"],"programRoutines":[{"name":"GD::Image::_make_filehandle"}],"repo":"https://github.com/lstein/Perl-GD"}],"references":[{"url":"https://github.com/lstein/Perl-GD/commit/67b163713c6c78dfeb693da0978ae934e5cd8210.patch","tags":["patch"]},{"url":"https://metacpan.org/release/RURBAN/GD-2.86/changes","tags":["release-notes"]}],"problemTypes":[{"descriptions":[{"cweId":"CWE-78","description":"CWE-78 Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')","lang":"en","type":"CWE"}]},{"descriptions":[{"cweId":"CWE-73","description":"CWE-73 External Control of File Name or Path","lang":"en","type":"CWE"}]}],"providerMetadata":{"shortName":"CPANSec","orgId":"9b29abf9-4ab0-4765-b253-1875cd9b441e","dateUpdated":"2026-06-14T11:39:21.122Z"},"solutions":[{"lang":"en","value":"Upgrade to GD 2.86 or later, which opens filename arguments with a 3-arg read open so the filename is never interpreted as a command or redirect."}],"source":{"discovery":"UNKNOWN"},"workarounds":[{"lang":"en","value":"For deployments that cannot upgrade to 2.86, do not pass untrusted input as a pathname to GD::Image constructors. Callers can open the file themselves and pass the resulting filehandle, which bypasses the affected string path."}],"x_generator":{"engine":"cpansec-cna-tool 0.1"}},"adp":[{"title":"CVE Program Container","references":[{"url":"http://www.openwall.com/lists/oss-security/2026/06/14/4"},{"url":"https://lists.debian.org/debian-lts-announce/2026/06/msg00027.html"}],"providerMetadata":{"shortName":"CVE","orgId":"af854a3a-2127-422b-91ae-364da2661108","dateUpdated":"2026-06-21T13:34:16.065Z"}},{"title":"CISA ADP Vulnrichment","metrics":[{"cvssV3_1":{"scope":"UNCHANGED","version":"3.1","baseScore":9.8,"attackVector":"NETWORK","baseSeverity":"CRITICAL","vectorString":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","integrityImpact":"HIGH","userInteraction":"NONE","attackComplexity":"LOW","availabilityImpact":"HIGH","privilegesRequired":"NONE","confidentialityImpact":"HIGH"}},{"other":{"type":"ssvc","content":{"timestamp":"2026-06-15T16:17:04.865826Z","id":"CVE-2026-11526","options":[{"Exploitation":"none"},{"Automatable":"yes"},{"Technical Impact":"total"}],"role":"CISA Coordinator","version":"2.0.3"}}}],"providerMetadata":{"shortName":"CISA-ADP","orgId":"134c704f-9b21-4f2e-91b3-4a467353bcc0","dateUpdated":"2026-06-15T16:17:32.599Z"}}]}}}