CVE-2022-50276

power: supply: fix null pointer dereferencing in power_supply_get_battery_info

MEDIUM
5.5
CVSS Score
Published: September 15, 2025 at 02:21 PM UTC
Updated: June 17, 2026 at 05:23 AM UTC
1 product affected across 1 vendorLinux Kernel

Using Linux by Linux?

Get instant alerts when new vulnerabilities affect Linux - before attackers find them.

Real-time alertsTrack your software stackFree plan available
Severity
MEDIUM5.5
Exploit prediction
EPSS 0.2%

Description

In the Linux kernel, the following vulnerability has been resolved: power: supply: fix null pointer dereferencing in power_supply_get_battery_info when kmalloc() fail to allocate memory in kasprintf(), propname will be NULL, strcmp() called by of_get_property() will cause null pointer dereference. So return ENOMEM if kasprintf() return NULL pointer.

Affected

Our own answer: ranges merged, affected separated from platform-only, with confidence and review flags.

5.0 ≤ v < 5.10.1635.0 ≤ v < 5.15.865.0 ≤ v < 5.4.2295.0 ≤ v < 6.0.165.0 ≤ v < 6.1.25.0 ≤ v < 6.25.11 ≤ v < 5.15.865.16 ≤ v < 6.0.165.5 ≤ v < 5.10.1636.1 ≤ v < 6.1.23afb50d7125bcdbf71df843134e96ceffc78c8b85.0
Vendor states this is fixed in 104bb8a663451404a26331263ce5b96c34504049 (fixed)
Vendor states this is fixed in 279af90e65cbdb3e5c4519b0043324d7876bc5ec (fixed)
Vendor states this is fixed in 5beadb55f4e36fafe5d6df5dcd5f85d803f3f134 (fixed)
Vendor states this is fixed in 8ea68b4e3fa9392ef9dae303abc8735a033c280f (fixed)
Vendor states this is fixed in b8131efb89d9f837c9244f900f0fc2699fd1181d (fixed)
Vendor states this is fixed in d21534ab4fd7883e1c8037a76671d4e8b6ea14cb (fixed)
Vendor states this is fixed in 5.0 (unaffected)
Vendor states this is fixed in 5.10.163 (unaffected)
Vendor states this is fixed in 5.15.86 (unaffected)
Vendor states this is fixed in 5.4.229 (unaffected)
Vendor states this is fixed in 6.0.16 (unaffected)
Vendor states this is fixed in 6.1.2 (unaffected)
Vendor states this is fixed in 6.2 (unaffected)

References (6)

Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/104bb8a663451404a26331263ce5b96c34504049
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/279af90e65cbdb3e5c4519b0043324d7876bc5ec
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/5beadb55f4e36fafe5d6df5dcd5f85d803f3f134
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/8ea68b4e3fa9392ef9dae303abc8735a033c280f
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/b8131efb89d9f837c9244f900f0fc2699fd1181d
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/d21534ab4fd7883e1c8037a76671d4e8b6ea14cb

CVSS

Attack Vector
LOCAL
Complexity
LOW
Privileges
LOW
User Interaction
NONE
Scope
UNCHANGED
Confidentiality
NONE
Integrity
NONE
Availability
HIGH
Vector?

Quick Info

StatusANALYZED
CWE
CWE-476

Get alerted

Stop reading CVE feeds looking for your own stack

Track the products you run and VulnTracker tells you when a new CVE affects them — with what is known about fixing it, and nothing about the rest.

Free plan, no card