pstore/ram: fix buffer overflow in persistent_ram_save_old()
In the Linux kernel, the following vulnerability has been resolved: pstore/ram: fix buffer overflow in persistent_ram_save_old() persistent_ram_save_old() can be called multiple times for the same persistent_ram_zone (e.g., via ramoops_pstore_read -> ramoops_get_next_prz for PSTORE_TYPE_DMESG records). Currently, the function only allocates prz->old_log when it is NULL, but it unconditionally updates prz->old_log_size to the current buffer size and then performs memcpy_fromio() using this new size. If the buffer size has grown since the first allocation (which can happen across different kernel boot cycles), this leads to: 1. A heap buffer overflow (OOB write) in the memcpy_fromio() calls 2. A subsequent OOB read when ramoops_pstore_read() accesses the buffer using the incorrect (larger) old_log_size The KASAN splat would look similar to: BUG: KASAN: slab-out-of-bounds in ramoops_pstore_read+0x... Read of size N at addr ... by task ... The conditions are likely extremely hard to hit: 0. Crash with a ramoops write of less-than-record-max-size bytes. 1. Reboot: ramoops registers, pstore_get_records(0) reads old crash, allocates old_log with size X 2. Crash handler registered, timer started (if pstore_update_ms >= 0) 3. Oops happens (non-fatal, system continues) 4. pstore_dump() writes oops via ramoops_pstore_write() size Y (>X) 5. pstore_new_entry = 1, pstore_timer_kick() called 6. System continues running (not a panic oops) 7. Timer fires after pstore_update_ms milliseconds 8.
CVE-2026-46253
Primary source · Revision 1
Imported from structured advisory data. Source references identify upstream records or fields; verify affected versions and your deployed configuration.
Security context
Source reference: cve:CVE-2026-46253
Linux
Source reference: /containers/cna/affected/0/product
- Affected versions
- Not stated in this record
- Fixed versions
- Not stated in this record
- Prerequisites
- Not stated in this record
Linux
Source reference: /containers/cna/affected/1/product
- Affected versions
- Not stated in this record
- Fixed versions
- Not stated in this record
- Prerequisites
- Not stated in this record
Structured affected-version data
Original package identities and version rules from this source.
[
{
"repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
"vendor": "Linux",
"product": "Linux",
"versions": [
{
"status": "affected",
"version": "201e4aca5aa179e6c69a4dcd36a3562e56b8d670",
"lessThan": "58bda5a1d1ee98254383ef34f76b2c35140513ea",
"versionType": "git"
},
{
"status": "affected",
"version": "201e4aca5aa179e6c69a4dcd36a3562e56b8d670",
"lessThan": "06d2c8bd108cea503f6f6e13e47495ed1085275f",
"versionType": "git"
},
{
"status": "affected",
"version": "201e4aca5aa179e6c69a4dcd36a3562e56b8d670",
"lessThan": "2fa9a047c6a50ec80c3890dd623b85e237f0d1fd",
"versionType": "git"
},
{
"status": "affected",
"version": "201e4aca5aa179e6c69a4dcd36a3562e56b8d670",
"lessThan": "cff0ef043e16feb5a02307c8f9d0117a96c5587c",
"versionType": "git"
},
{
"status": "affected",
"version": "201e4aca5aa179e6c69a4dcd36a3562e56b8d670",
"lessThan": "9a6fc69a570c0780834246d52c856cc3dbc2605f",
"versionType": "git"
},
{
"status": "affected",
"version": "201e4aca5aa179e6c69a4dcd36a3562e56b8d670",
"lessThan": "4f73486ca822305c1cf5b8ebc0b53a6ab3801a81",
"versionType": "git"
},
{
"status": "affected",
"version": "201e4aca5aa179e6c69a4dcd36a3562e56b8d670",
"lessThan": "7cfe964e61c0ab667abd5f5b68e0acbf783efa4f",
"versionType": "git"
},
{
"status": "affected",
"version": "201e4aca5aa179e6c69a4dcd36a3562e56b8d670",
"lessThan": "5669645c052f235726a85f443769b6fc02f66762",
"versionType": "git"
}
],
"programFiles": [
"fs/pstore/ram_core.c"
],
"defaultStatus": "unaffected"
},
{
"repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
"vendor": "Linux",
"product": "Linux",
"versions": [
{
"status": "affected",
"version": "3.5"
},
{
"status": "unaffected",
"version": "0",
"lessThan": "3.5",
"versionType": "semver"
},
{
"status": "unaffected",
"version": "5.10.252",
"versionType": "semver",
"lessThanOrEqual": "5.10.*"
},
{
"status": "unaffected",
"version": "5.15.202",
"versionType": "semver",
"lessThanOrEqual": "5.15.*"
},
{
"status": "unaffected",
"version": "6.1.165",
"versionType": "semver",
"lessThanOrEqual": "6.1.*"
},
{
"status": "unaffected",
"version": "6.6.128",
"versionType": "semver",
"lessThanOrEqual": "6.6.*"
},
{
"status": "unaffected",
"version": "6.12.75",
"versionType": "semver",
"lessThanOrEqual": "6.12.*"
},
{
"status": "unaffected",
"version": "6.18.14",
"versionType": "semver",
"lessThanOrEqual": "6.18.*"
},
{
"status": "unaffected",
"version": "6.19.4",
"versionType": "semver",
"lessThanOrEqual": "6.19.*"
},
{
"status": "unaffected",
"version": "7.0",
"versionType": "original_commit_for_fix",
"lessThanOrEqual": "*"
}
],
"programFiles": [
"fs/pstore/ram_core.c"
],
"defaultStatus": "affected"
}
]- Related CVEs
- CVE-2026-46253
Source reference:
/cveMetadata/cveId
Publisher severity
high
Source reference: /containers/cna/metrics
- Event
- #40163 · Revision 1
- Added to Heist Feed
- Publisher date