CVE-2026-6104
Global buffer over-read in mb_convert_encoding() with attacker-supplied encoding
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.
Exposure status: unknown. This page does not establish whether an installed system is affected or corrected.
Severity and exploitation evidence
EPSS: 0.469% · score date 2026-11-19. EPSS is an estimated probability over the next 30 days, not proof of exploitation.
CISA KEV: not included in the checked catalog; exploitation may still occur. Last checked: 2026-11-19T17:59:58.648Z. Public exploit availability is not used to set this status.
CVSS 4.0 · 6.3 · published by phpCVSS: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
Assessment source · checked 2026-11-19T10:46:19.124Z
CVSS 4.0 · 6.3 · published by [email protected]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
Assessment source · checked 2026-11-19T10:05:26.094Z
CVSS 4.0 · 6.3 · published by Ubuntu SecurityCVSS: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
Assessment source · checked 2026-11-19T14:19:00.134Z
CVSS 3.1 · 9.1 · published by [email protected]CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H
Assessment source · checked 2026-11-19T10:05:26.094Z
CVSS 3.1 · 8.2 · published by 0b0ca135-0b70-47e7-9f44-1890c2a1c46cCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:H
Assessment source · checked 2026-11-19T10:05:26.094Z
CVSS 3.1 · 8.2 · published by Ubuntu SecurityCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:H
Assessment source · checked 2026-11-19T14:19:00.134Z
Verification by field
| Field | Status | Checked at (UTC) | Source |
|---|---|---|---|
| kev | verified | 2026-11-19T17:59:58.648Z | CISA KEV |
| cvss | verified | 2026-11-19T10:46:19.124Z | CVE Program |
| epss | verified | 2026-11-19T16:04:53.537Z | FIRST EPSS |
| patches | verified | 2026-11-19T14:19:09.487Z | Ubuntu Security |
| affected | verified | 2026-11-19T10:46:19.124Z | CVE Program |
| lifecycle | verified | 2026-11-19T10:46:19.124Z | CVE Program |
Affected versions and configuration
PHP Group PHP; default status: unaffected: 8.4.* to < 8.4.21 [affected; scheme: semver]; 8.5.* to < 8.5.6 [affected; scheme: semver]
Defaults, conditional configuration, package status and version schemes are retained below. A version range alone is not an exposure verdict.
Ubuntu Security · ubuntu-package · full conditions
[
{
"name": "php8.4",
"debian": "https://tracker.debian.org/pkg/php8.4",
"source": "https://ubuntu.com/security/cve?package=php8.4",
"ubuntu": "https://packages.ubuntu.com/search?suite=all§ion=all&arch=any&searchon=sourcenames&keywords=php8.4",
"statuses": [
{
"pocket": "security",
"status": "DNE",
"component": null,
"description": "",
"release_codename": "jammy"
},
{
"pocket": "security",
"status": "DNE",
"component": null,
"description": "",
"release_codename": "noble"
},
{
"pocket": "security",
"status": "DNE",
"component": null,
"description": "",
"release_codename": "resolute"
},
{
"pocket": "security",
"status": "released",
"component": null,
"description": "8.4.21",
"release_codename": "upstream"
},
{
"pocket": "security",
"status": "released",
"component": null,
"description": "8.4.11-1ubuntu1.2",
"release_codename": "questing"
}
]
}
]Archived source JSONUbuntu Security · ubuntu-package · full conditions
[
{
"name": "php8.3",
"debian": "https://tracker.debian.org/pkg/php8.3",
"source": "https://ubuntu.com/security/cve?package=php8.3",
"ubuntu": "https://packages.ubuntu.com/search?suite=all§ion=all&arch=any&searchon=sourcenames&keywords=php8.3",
"statuses": [
{
"pocket": "security",
"status": "DNE",
"component": null,
"description": "",
"release_codename": "jammy"
},
{
"pocket": "security",
"status": "DNE",
"component": null,
"description": "",
"release_codename": "questing"
},
{
"pocket": "security",
"status": "DNE",
"component": null,
"description": "",
"release_codename": "resolute"
},
{
"pocket": "security",
"status": "needs-triage",
"component": null,
"description": "",
"release_codename": "upstream"
},
{
"pocket": "security",
"status": "not-affected",
"component": null,
"description": "8.4+ only",
"release_codename": "noble"
}
]
}
]Archived source JSONCVE Program · cve-json · full conditions
{
"affected": [
{
"vendor": "PHP Group",
"product": "PHP",
"versions": [
{
"status": "affected",
"version": "8.4.*",
"lessThan": "8.4.21",
"versionType": "semver"
},
{
"status": "affected",
"version": "8.5.*",
"lessThan": "8.5.6",
"versionType": "semver"
}
],
"packageName": "mbstring",
"defaultStatus": "unaffected"
}
],
"additionalContainers": [
{
"title": "CISA ADP Vulnrichment",
"metrics": [
{
"other": {
"type": "ssvc",
"content": {
"id": "CVE-2026-6104",
"role": "CISA Coordinator",
"options": [
{
"Exploitation": "none"
},
{
"Automatable": "yes"
},
{
"Technical Impact": "partial"
}
],
"version": "2.0.3",
"timestamp": "2026-05-11T13:04:44.572023Z"
}
}
}
],
"providerMetadata": {
"orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
"shortName": "CISA-ADP",
"dateUpdated": "2026-05-11T13:04:58.462Z"
}
},
{
"title": "php: global buffer over-read in mb_convert_encoding() with attacker-supplied encoding",
"metrics": [
{
"other": {
"type": "Red Hat severity rating",
"content": {
"value": "Important",
"namespace": "https://access.redhat.com/security/updates/classification/"
}
}
},
{
"format": "CVSS",
"cvssV3_1": {
"scope": "UNCHANGED",
"version": "3.1",
"baseScore": 8.2,
"attackVector": "NETWORK",
"baseSeverity": "HIGH",
"vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:H",
"integrityImpact": "NONE",
"userInteraction": "NONE",
"attackComplexity": "LOW",
"availabilityImpact": "HIGH",
"privilegesRequired": "NONE",
"confidentialityImpact": "LOW"
}
}
],
"affected": [
{
"cpes": [
"cpe:/o:redhat:enterprise_linux:10.2"
],
"vendor": "Red Hat",
"product": "Red Hat Enterprise Linux 10",
"versions": [
{
"status": "unaffected",
"version": "0:8.4.21-1.el10_2",
"lessThan": "*",
"versionType": "rpm"
}
],
"packageName": "php8.4",
"collectionURL": "https://access.redhat.com/downloads/content/package-browser/",
"defaultStatus": "affected"
},
{
"cpes": [
"cpe:/o:redhat:enterprise_linux:10"
],
"vendor": "Red Hat",
"product": "Red Hat Enterprise Linux 10",
"packageName": "php",
"collectionURL": "https://access.redhat.com/downloads/content/package-browser/",
"defaultStatus": "unaffected"
},
{
"cpes": [
"cpe:/o:redhat:enterprise_linux:6"
],
"vendor": "Red Hat",
"product": "Red Hat Enterprise Linux 6",
"packageName": "php",
"collectionURL": "https://access.redhat.com/downloads/content/package-browser/",
"defaultStatus": "unaffected"
},
{
"cpes": [
"cpe:/o:redhat:enterprise_linux:7"
],
"vendor": "Red Hat",
"product": "Red Hat Enterprise Linux 7",
"packageName": "php",
"collectionURL": "https://access.redhat.com/downloads/content/package-browser/",
"defaultStatus": "unaffected"
},
{
"cpes": [
"cpe:/o:redhat:enterprise_linux:8"
],
"vendor": "Red Hat",
"product": "Red Hat Enterprise Linux 8",
"packageName": "php:7.4/php",
"collectionURL": "https://access.redhat.com/downloads/content/package-browser/",
"defaultStatus": "unaffected"
},
{
"cpes": [
"cpe:/o:redhat:enterprise_linux:8"
],
"vendor": "Red Hat",
"product": "Red Hat Enterprise Linux 8",
"packageName": "php:8.2/php",
"collectionURL": "https://access.redhat.com/downloads/content/package-browser/",
"defaultStatus": "unaffected"
},
{
"cpes": [
"cpe:/o:redhat:enterprise_linux:9"
],
"vendor": "Red Hat",
"product": "Red Hat Enterprise Linux 9",
"packageName": "php",
"collectionURL": "https://access.redhat.com/downloads/content/package-browser/",
"defaultStatus": "unaffected"
},
{
"cpes": [
"cpe:/o:redhat:enterprise_linux:9"
],
"vendor": "Red Hat",
"product": "Red Hat Enterprise Linux 9",
"packageName": "php:8.2/php",
"collectionURL": "https://access.redhat.com/downloads/content/package-browser/",
"defaultStatus": "unaffected"
},
{
"cpes": [
"cpe:/o:redhat:enterprise_linux:9"
],
"vendor": "Red Hat",
"product": "Red Hat Enterprise Linux 9",
"packageName": "php:8.3/php",
"collectionURL": "https://access.redhat.com/downloads/content/package-browser/",
"defaultStatus": "unaffected"
},
{
"cpes": [
"cpe:/a:redhat:hummingbird:1"
],
"vendor": "Red Hat",
"product": "Red Hat Hardened Images",
"packageName": "php",
"collectionURL": "https://access.redhat.com/downloads/content/package-browser/",
"defaultStatus": "unaffected"
}
],
"timeline": [
{
"lang": "en",
"time": "2026-05-10T06:01:02.802Z",
"value": "Reported to Red Hat."
},
{
"lang": "en",
"time": "2026-05-10T04:35:17.328Z",
"value": "Made public."
}
],
"solutions": [
{
"lang": "en",
"value": "RHSA-2026:22649: Red Hat Enterprise Linux AppStream (v. 10)"
}
],
"x_adpType": "supplier",
"datePublic": "2026-05-10T04:35:17.328Z",
"references": [
{
"url": "https://access.redhat.com/security/cve/CVE-2026-6104",
"tags": [
"vdb-entry",
"x_refsource_REDHAT"
]
},
{
"url": "https://bugzilla.redhat.com/show_bug.cgi?id=2468573",
"name": "RHBZ#2468573",
"tags": [
"issue-tracking",
"x_refsource_REDHAT"
]
},
{
"url": "https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-6104.json",
"tags": [
"x_sadp-csaf-vex"
]
},
{
"url": "https://access.redhat.com/errata/RHSA-2026:22649",
"tags": [
"vendor-advisory",
"x_refsource_REDHAT"
]
}
],
"workarounds": [
{
"lang": "en",
"value": "To mitigate this vulnerability, sanitize any input containing a NUL byte before calling the vulnerable mbstring functions. Also, verify your PHP configuration to ensure the vulnerable INI settings are using securely hardcoded encodings."
}
],
"x_generator": {
"engine": "sadp-cli 1.0.0"
},
"descriptions": [
{
"lang": "en",
"value": "A flaw was found in PHP. When an encoding name containing an embedded NUL byte is passed to `mb_convert_encoding()` or related mbstring functions, an out-of-bounds read of only 1 byte can occur due to the incorrect processing of string lengths. This issue can cause a denial of service or limited information disclosure."
}
],
"problemTypes": [
{
"descriptions": [
{
"lang": "en",
"type": "CWE",
"cweId": "CWE-125",
"description": "Out-of-bounds Read"
}
]
}
],
"providerMetadata": {
"orgId": "0b0ca135-0b70-47e7-9f44-1890c2a1c46c",
"shortName": "redhat-SADP",
"dateUpdated": "2026-07-15T00:41:42.455Z"
}
}
]
}Archived source JSONNVD · nvd-cpe · full conditions
[
{
"nodes": [
{
"negate": false,
"cpeMatch": [
{
"criteria": "cpe:2.3:a:php:php:*:*:*:*:*:*:*:*",
"vulnerable": true,
"matchCriteriaId": "BA663C03-392C-41CC-BD11-4A1245203C42",
"versionEndExcluding": "8.4.21",
"versionStartIncluding": "8.4.0"
},
{
"criteria": "cpe:2.3:a:php:php:*:*:*:*:*:*:*:*",
"vulnerable": true,
"matchCriteriaId": "6101DA12-5AA1-4882-A52A-61FB74254F9A",
"versionEndExcluding": "8.5.6",
"versionStartIncluding": "8.5.0"
}
],
"operator": "OR"
}
]
}
]Archived source JSONCorrection evidence
Distribution packages and upstream releases are distinct. ESM channels may require the corresponding Ubuntu entitlement. Notes and branch ranges are not installable package versions. OSV fixed boundaries are ecosystem-specific version thresholds, not proof that a package is currently available or installed.
| Evidence type | Distribution / release | Package | Channel | Version or source note | Source |
|---|---|---|---|---|---|
| upstream-release | upstream / upstream | php8.4 | Not a distribution channel | 8.4.21 | Official record |
| distribution-package | Ubuntu / questing | php8.4 | security | 8.4.11-1ubuntu1.2 | Official record |
Vendor notices and operational guidance
No connected vendor notice is available for this record.
Original sources and dates
- CVE ProgramConsulted: 2026-11-19T10:46:19.124ZArchived source JSON
Source publication: 2026-05-10T04:35:17.328Z
Source modification: 2026-07-15T00:41:42.455ZDocument fingerprint
b3c3651a3e25cc0ac5d7aecdc0a0c2eb665f2c479af2edb8e62bc53e95eb4df9 - Ubuntu SecurityConsulted: 2026-11-19T14:19:00.134ZArchived source JSON
Source publication: 2026-05-10T06:16:00.000Z
Source modification: 2026-06-30T18:55:11.047ZDocument fingerprint
20fddfeece0f74c8829da78cd57103d95bb1a0e20b339dd1fef11a36202bd2f8 - CISA KEVConsulted: 2026-11-19T17:59:58.648ZArchived source JSON
Source publication: not supplied
Source modification: 2026-11-18T19:17:41.0354ZDocument fingerprint
a35fdc67c7d9802988dcfc1d3ff1198da327948d1db122ab7692ac201055ac56 - NVDConsulted: 2026-11-19T10:05:26.094ZArchived source JSON
Source publication: 2026-05-10T06:16:07.397Z
Source modification: 2026-07-24T08:10:00.150ZDocument fingerprint
1c8297d969248fbf89b5ff19942100dcf8b2aaa408f73b42aea4643bfa5ba1b0 - Ubuntu SecurityConsulted: 2026-11-19T14:19:09.487ZArchived source JSON
Source publication: 2026-05-10T06:16:00.000Z
Source modification: 2026-06-30T18:55:11.047ZDocument fingerprint
0e7f48abf40bd2e76a89d5742caff50ab5ef27fdf1365221ab7fee37916899e3 - FIRST EPSSConsulted: 2026-11-19T16:04:53.537ZArchived source JSON
Source publication: not supplied
Source modification: not suppliedDocument fingerprint
7e44f0c24d7a237474c3a56b3eb9206b3b9510af524fb7f14d94ce5ca700b828
Official status history
- UNKNOWN → PUBLISHED · · evidence