Linux Kernel up to 6.6.30/6.8.9 cdev gpio_chrdev_release use after free

CVSS Meta Temp Score
CVSS is a standardized scoring system to determine possibilities of attacks. The Temp Score considers temporal factors like disclosure, exploit and countermeasures. The unique Meta Score calculates the average score of different sources to provide a normalized scoring system.
Current Exploit Price (≈)
Our analysts are monitoring exploit markets and are in contact with vulnerability brokers. The range indicates the observed or calculated exploit price to be seen on exploit markets. A good indicator to understand the monetary effort required for and the popularity of an attack.
CTI Interest Score
Our Cyber Threat Intelligence team is monitoring different web sites, mailing lists, exploit markets and social media networks. The CTI Interest Score identifies the interest of attackers and the security community for this specific vulnerability in real-time. A high score indicates an elevated risk to be targeted for this vulnerability.
6.9$0-$5k0.00

Summaryinfo

A vulnerability was found in Linux Kernel up to 6.6.30/6.8.9. It has been classified as critical. This impacts the function gpio_chrdev_release of the component cdev. Performing a manipulation results in use after free. This vulnerability is cataloged as CVE-2024-36899. There is no exploit available. Upgrading the affected component is recommended.

Detailsinfo

A vulnerability was found in Linux Kernel up to 6.6.30/6.8.9. It has been classified as critical. This affects the function gpio_chrdev_release of the component cdev. The manipulation with an unknown input leads to a use after free vulnerability. CWE is classifying the issue as CWE-416. Referencing memory after it has been freed can cause a program to crash, use unexpected values, or execute code. This is going to have an impact on confidentiality, integrity, and availability. The summary by CVE is:

In the Linux kernel, the following vulnerability has been resolved: gpiolib: cdev: Fix use after free in lineinfo_changed_notify The use-after-free issue occurs as follows: when the GPIO chip device file is being closed by invoking gpio_chrdev_release(), watched_lines is freed by bitmap_free(), but the unregistration of lineinfo_changed_nb notifier chain failed due to waiting write rwsem. Additionally, one of the GPIO chip's lines is also in the release process and holds the notifier chain's read rwsem. Consequently, a race condition leads to the use-after-free of watched_lines. Here is the typical stack when issue happened: [free] gpio_chrdev_release() --> bitmap_free(cdev->watched_lines) <-- freed --> blocking_notifier_chain_unregister() --> down_write(&nh->rwsem) <-- waiting rwsem --> __down_write_common() --> rwsem_down_write_slowpath() --> schedule_preempt_disabled() --> schedule() [use] st54spi_gpio_dev_release() --> gpio_free() --> gpiod_free() --> gpiod_free_commit() --> gpiod_line_state_notify() --> blocking_notifier_call_chain() --> down_read(&nh->rwsem); <-- held rwsem --> notifier_call_chain() --> lineinfo_changed_notify() --> test_bit(xxxx, cdev->watched_lines) <-- use after free The side effect of the use-after-free issue is that a GPIO line event is being generated for userspace where it shouldn't. However, since the chrdev is being closed, userspace won't have the chance to read that event anyway. To fix the issue, call the bitmap_free() function after the unregistration of lineinfo_changed_nb notifier chain.

The advisory is shared at git.kernel.org. This vulnerability is uniquely identified as CVE-2024-36899 since 05/30/2024. The exploitability is told to be difficult. Technical details are known, but no exploit is available. The price for an exploit might be around USD $0-$5k at the moment (estimation calculated on 08/29/2025).

The vulnerability scanner Nessus provides a plugin with the ID 207776 (Oracle Linux 9 : kernel (ELSA-2024-6997)), which helps to determine the existence of the flaw in a target environment.

Upgrading to version 6.6.31 or 6.8.10 eliminates this vulnerability. Applying the patch 95ca7c90eaf5/ca710b5f40b8/02f6b0e1ec7e is able to eliminate this problem. The bugfix is ready for download at git.kernel.org. The best possible mitigation is suggested to be upgrading to the latest version.

The vulnerability is also documented in the databases at Tenable (207776) and CERT Bund (WID-SEC-2024-1259). Several companies clearly confirm that VulDB is the primary source for best vulnerability data.

Affected

  • Debian Linux
  • Amazon Linux 2
  • Red Hat Enterprise Linux
  • Ubuntu Linux
  • SUSE Linux
  • IBM InfoSphere Guardium
  • Oracle Linux
  • Oracle VM
  • NetApp FAS
  • EMC Avamar
  • NetApp AFF
  • Dell NetWorker
  • NetApp ActiveIQ Unified Manager
  • IBM Security Guardium
  • RESF Rocky Linux
  • Broadcom Brocade SANnav
  • Open Source Linux Kernel
  • IBM Business Automation Workflow
  • IBM QRadar SIEM
  • Dell Avamar
  • IBM Storage Scale
  • IBM Spectrum Protect Plus
  • Juniper Junos Space
  • IBM Storage Scale System
  • SolarWinds Security Event Manager

Productinfo

Type

Vendor

Name

Version

License

Website

CPE 2.3info

CPE 2.2info

CVSSv4info

VulDB Vector: 🔍
VulDB Reliability: 🔍

CVSSv3info

VulDB Meta Base Score: 7.1
VulDB Meta Temp Score: 6.9

VulDB Base Score: 7.1
VulDB Temp Score: 6.8
VulDB Vector: 🔍
VulDB Reliability: 🔍

NVD Base Score: 7.0
NVD Vector: 🔍

CVSSv2info

AVACAuCIA
💳💳💳💳💳💳
💳💳💳💳💳💳
💳💳💳💳💳💳
VectorComplexityAuthenticationConfidentialityIntegrityAvailability
UnlockUnlockUnlockUnlockUnlockUnlock
UnlockUnlockUnlockUnlockUnlockUnlock
UnlockUnlockUnlockUnlockUnlockUnlock

VulDB Base Score: 🔍
VulDB Temp Score: 🔍
VulDB Reliability: 🔍

Exploitinginfo

Class: Use after free
CWE: CWE-416 / CWE-119
CAPEC: 🔍
ATT&CK: 🔍

Physical: Partially
Local: Yes
Remote: Partially

Availability: 🔍
Status: Not defined

EPSS Score: 🔍
EPSS Percentile: 🔍

Price Prediction: 🔍
Current Price Estimation: 🔍

0-DayUnlockUnlockUnlockUnlock
TodayUnlockUnlockUnlockUnlock

Nessus ID: 207776
Nessus Name: Oracle Linux 9 : kernel (ELSA-2024-6997)

Threat Intelligenceinfo

Interest: 🔍
Active Actors: 🔍
Active APT Groups: 🔍

Countermeasuresinfo

Recommended: Upgrade
Status: 🔍

0-Day Time: 🔍

Upgrade: Kernel 6.6.31/6.8.10
Patch: 95ca7c90eaf5/ca710b5f40b8/02f6b0e1ec7e

Timelineinfo

05/30/2024 🔍
05/30/2024 +0 days 🔍
05/30/2024 +0 days 🔍
08/29/2025 +456 days 🔍

Sourcesinfo

Vendor: kernel.org

Advisory: git.kernel.org
Status: Confirmed

CVE: CVE-2024-36899 (🔍)
GCVE (CVE): GCVE-0-2024-36899
GCVE (VulDB): GCVE-100-266649
CERT Bund: WID-SEC-2024-1259 - Linux Kernel: Mehrere Schwachstellen erm&ouml;glichen Denial of Service und unspezifischen Angriff

Entryinfo

Created: 05/30/2024 18:56
Updated: 08/29/2025 04:05
Changes: 05/30/2024 18:56 (57), 09/28/2024 04:44 (3), 02/02/2025 12:22 (11), 08/29/2025 04:05 (7)
Complete: 🔍
Cache ID: 216::103

Several companies clearly confirm that VulDB is the primary source for best vulnerability data.

Discussion

No comments yet. Languages: en.

Please log in to comment.

Might our Artificial Intelligence support you?

Check our Alexa App!