{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2026-6104","id":"CVE-2026-6104","title":"Global buffer over-read in mb_convert_encoding() with attacker-supplied encoding","description":"In PHP versions 8.4.* before 8.4.21 and 8.5.* before 8.5.6, when an encoding name containing an embedded NUL byte is passed to mb_convert_encoding() or related mbstring functions, the code incorrectly assumes that when strncasecmp() returns 0 it means the strings have the same length. This can lead to out-of-bounds read of global memory, potentially causing a crash or information disclosure or cra","descriptionLong":"In PHP versions 8.4.* before 8.4.21 and 8.5.* before 8.5.6, when an encoding name containing an embedded NUL byte is passed to mb_convert_encoding() or related mbstring functions, the code incorrectly assumes that when strncasecmp() returns 0 it means the strings have the same length. This can lead to out-of-bounds read of global memory, potentially causing a crash or information disclosure or crash. Affected functions include mb_convert_encoding(), mb_detect_encoding(), mb_convert_variables(), and mb_detect_order(), as well as the mbstring.detect_order and mbstring.http_output INI settings.","published":"2026-05-10T04:35:17.328Z","updated":"2026-11-11T02:55:53.626589335Z","reserved":"2026-04-11T04:15:03.938Z","status":"Modified","rejected":false,"assigner":"php","metric":{"version":"4.0","score":6.3,"vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:N/VA:L/SC:L/SI:N/SA:L/RE:M/U:Amber","rating":"medium","source":"php"},"metrics":[{"version":"4.0","score":6.3,"vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:N/VA:L/SC:L/SI:N/SA:L/RE:M/U:Amber","rating":"medium","source":"php"},{"version":"4.0","score":6.3,"vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:N/VA:L/SC:L/SI:N/SA:L/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:M/U:Amber","rating":"medium","source":"php.net"},{"version":"4.0","score":null,"vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:N/VA:L/SC:L/SI:N/SA:L/RE:M/U:Amber","rating":"unrated","source":"OSV"},{"version":"3.1","score":8.2,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:H","rating":"high","source":"0b0ca135-0b70-47e7-9f44-1890c2a1c46c"},{"version":"3.1","score":9.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H","rating":"critical","source":"NVD"},{"version":"3.1","score":8.2,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:H","rating":"high","source":"redhat-SADP"}],"rating":"medium","products":["PHP Group PHP"],"affectedProducts":[{"vendor":"PHP Group","product":"PHP","defaultStatus":"unaffected","versions":[{"status":"affected","version":"8.4.*","lessThan":"8.4.21","versionType":"semver"},{"status":"affected","version":"8.5.*","lessThan":"8.5.6","versionType":"semver"}],"platforms":[]}],"packages":[],"cwes":["CWE-125"],"aliases":["BIT-libphp-2026-6104","BIT-php-2026-6104","BIT-php-min-2026-6104","GHSA-74r9-qxhc-fx53"],"references":[{"url":"https://github.com/php/php-src/security/advisories/GHSA-74r9-qxhc-fx53","tags":["vendor-advisory","Vendor Advisory","advisory"]},{"url":"https://access.redhat.com/security/cve/CVE-2026-6104","tags":["vdb-entry","x_refsource_REDHAT","advisory"]},{"url":"https://bugzilla.redhat.com/show_bug.cgi?id=2468573","tags":["issue-tracking","x_refsource_REDHAT","report"]},{"url":"https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-6104.json","tags":["x_sadp-csaf-vex","web"]},{"url":"https://access.redhat.com/errata/RHSA-2026:22649","tags":["vendor-advisory","x_refsource_REDHAT","advisory"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/6xxx/CVE-2026-6104.json","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-6104","tags":["advisory"]}],"patchReferenced":false,"fixAvailable":false,"exploitReferenced":false,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":{"exploitation":"none","automatable":"yes","technicalImpact":"partial"},"epss":0.00469,"epssPercentile":0.4132,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2026-6104","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-6104","ok":true,"note":"Modified"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2026-6104","ok":true,"note":"0 packages"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2026-6104","ok":true,"note":"scored 2026-11-19"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}