{"id":"CVE-2026-12087","state":"PUBLISHED","title":"Socket versions before 2.041 for Perl have an out-of-bounds heap read","description":"Socket versions before 2.041 for Perl have an out-of-bounds heap read.\n\nIn Socket.xs, pack_ip_mreq_source() checks the length of its source argument before the argument is read, so the check tests the byte length carried over from the preceding multiaddr argument instead. Both addresses occupy a 4-byte field, so a valid multiaddr lets a source of any length pass the check, and the source is then copied into the 4-byte imr_sourceaddr field with a fixed-size copy. A source shorter than 4 bytes is not rejected, and the copy reads up to 3 bytes past the end of its buffer.\n\nCalling pack_ip_mreq_source() with a source value shorter than 4 bytes copies adjacent heap memory into the returned packed structure.","publishedAt":"2026-06-15T21:11:09.876Z","updatedAt":"2026-06-16T15:59:27.883Z","severity":{"score":9.1,"label":"Critical","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H","source":"CISA-ADP"},"assigner":"CPANSec","products":["PEVANS Socket"],"affected":[{"vendor":"PEVANS","product":"Socket","packageName":"Socket","defaultStatus":"unaffected","versions":[{"version":"0","status":"affected","lessThan":"2.041","versionType":"custom"}],"collectionURL":"https://cpan.org/modules","programFiles":["Socket.xs"],"programRoutines":[{"name":"pack_ip_mreq_source"}]}],"references":["https://metacpan.org/release/PEVANS/Socket-2.041/changes","https://github.com/Perl/perl5/commit/de19a0b0ad1900fef976c5c1400bd8f11ec6c6cb.patch","http://www.openwall.com/lists/oss-security/2026/06/15/10"],"weaknesses":["CWE-125","CWE-805"],"ingestedAt":"2026-10-29T20:10:52.580Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/12xxx/CVE-2026-12087.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-12087","state":"PUBLISHED","datePublished":"2026-06-15T21:11:09.876Z","dateUpdated":"2026-06-16T15:59:27.883Z","assignerShortName":"CPANSec","assignerOrgId":"9b29abf9-4ab0-4765-b253-1875cd9b441e","dateReserved":"2026-06-12T13:29:50.478Z"},"containers":{"cna":{"title":"Socket versions before 2.041 for Perl have an out-of-bounds heap read","descriptions":[{"lang":"en","value":"Socket versions before 2.041 for Perl have an out-of-bounds heap read.\n\nIn Socket.xs, pack_ip_mreq_source() checks the length of its source argument before the argument is read, so the check tests the byte length carried over from the preceding multiaddr argument instead. Both addresses occupy a 4-byte field, so a valid multiaddr lets a source of any length pass the check, and the source is then copied into the 4-byte imr_sourceaddr field with a fixed-size copy. A source shorter than 4 bytes is not rejected, and the copy reads up to 3 bytes past the end of its buffer.\n\nCalling pack_ip_mreq_source() with a source value shorter than 4 bytes copies adjacent heap memory into the returned packed structure."}],"affected":[{"vendor":"PEVANS","product":"Socket","packageName":"Socket","defaultStatus":"unaffected","versions":[{"version":"0","status":"affected","lessThan":"2.041","versionType":"custom"}],"collectionURL":"https://cpan.org/modules","programFiles":["Socket.xs"],"programRoutines":[{"name":"pack_ip_mreq_source"}]}],"references":[{"url":"https://metacpan.org/release/PEVANS/Socket-2.041/changes","tags":["release-notes"]},{"url":"https://github.com/Perl/perl5/commit/de19a0b0ad1900fef976c5c1400bd8f11ec6c6cb.patch","tags":["patch"]}],"problemTypes":[{"descriptions":[{"cweId":"CWE-125","description":"CWE-125 Out-of-bounds Read","lang":"en","type":"CWE"}]},{"descriptions":[{"cweId":"CWE-805","description":"CWE-805 Buffer Access with Incorrect Length Value","lang":"en","type":"CWE"}]}],"providerMetadata":{"shortName":"CPANSec","orgId":"9b29abf9-4ab0-4765-b253-1875cd9b441e","dateUpdated":"2026-06-15T21:11:09.876Z"},"solutions":[{"lang":"en","value":"Upgrade to version 2.041 or later."}],"source":{"discovery":"UNKNOWN"},"x_generator":{"engine":"cpansec-cna-tool 0.1"}},"adp":[{"title":"CVE Program Container","references":[{"url":"http://www.openwall.com/lists/oss-security/2026/06/15/10"}],"providerMetadata":{"shortName":"CVE","orgId":"af854a3a-2127-422b-91ae-364da2661108","dateUpdated":"2026-06-15T23:33:50.725Z"}},{"title":"CISA ADP Vulnrichment","metrics":[{"cvssV3_1":{"scope":"UNCHANGED","version":"3.1","baseScore":9.1,"attackVector":"NETWORK","baseSeverity":"CRITICAL","vectorString":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H","integrityImpact":"NONE","userInteraction":"NONE","attackComplexity":"LOW","availabilityImpact":"HIGH","privilegesRequired":"NONE","confidentialityImpact":"HIGH"}},{"other":{"type":"ssvc","content":{"timestamp":"2026-06-16T15:43:23.064154Z","id":"CVE-2026-12087","options":[{"Exploitation":"none"},{"Automatable":"yes"},{"Technical Impact":"partial"}],"role":"CISA Coordinator","version":"2.0.3"}}}],"providerMetadata":{"shortName":"CISA-ADP","orgId":"134c704f-9b21-4f2e-91b3-4a467353bcc0","dateUpdated":"2026-06-16T15:59:27.883Z"}}]}}}