CVE-2022-50453

gpiolib: cdev: fix NULL-pointer dereferences

MEDIUM
5.5
CVSS Score
Published: October 1, 2025 at 11:45 AM 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: gpiolib: cdev: fix NULL-pointer dereferences There are several places where we can crash the kernel by requesting lines, unbinding the GPIO device, then calling any of the system calls relevant to the GPIO character device's annonymous file descriptors: ioctl(), read(), poll(). While I observed it with the GPIO simulator, it will also happen for any of the GPIO devices that can be hot-unplugged - for instance any HID GPIO expander (e.g. CP2112). This affects both v1 and v2 uAPI. This fixes it partially by checking if gdev->chip is not NULL but it doesn't entirely remedy the situation as we still have a race condition in which another thread can remove the device after the check.

Affected

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

4.8 ≤ v < 5.10.1634.8 ≤ v < 5.15.864.8 ≤ v < 6.0.164.8 ≤ v < 6.1.24.8 ≤ v < 6.25.11 ≤ v < 5.15.865.16 ≤ v < 6.0.166.1 ≤ v < 6.1.24.8d7c51b47ac11e66f547b55640405c1c474642d72
Vendor states this is fixed in 533aae7c94dbc2b14301cfd68ae7e0e90f0c8438 (fixed)
Vendor states this is fixed in 6d79546622baab843172b52c3af035f83c1b21df (fixed)
Vendor states this is fixed in 7c755a2d6df511eeb5afba966ac28140f9ea5063 (fixed)
Vendor states this is fixed in ac6ce3cd7a3e10a2e37b8970bab81b4d33d5cfc3 (fixed)
Vendor states this is fixed in d66f68ac9e7ba46b6b90fbe25155723f2126088a (fixed)
Vendor states this is fixed in 4.8 (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 6.0.16 (unaffected)
Vendor states this is fixed in 6.1.2 (unaffected)
Vendor states this is fixed in 6.2 (unaffected)

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