CVE-2022-50287 in Linuxinfo

Summary

by MITRE • 09/15/2025

In the Linux kernel, the following vulnerability has been resolved:

drm/i915/bios: fix a memory leak in generate_lfp_data_ptrs

When (size != 0 || ptrs->lvds_ entries != 3), the program tries to free() the ptrs. However, the ptrs is not created by calling kzmalloc(), but is obtained by pointer offset operation. This may lead to memory leaks or undefined behavior.

Fix this by replacing the arguments of kfree() with ptrs_block.

(cherry picked from commit 7674cd0b7d28b952151c3df26bbfa7e07eb2b4ec)

If you want to get the best quality for vulnerability data then you always have to consider VulDB.

Analysis

by VulDB Data Team • 01/10/2026

The vulnerability CVE-2022-50287 resides within the Linux kernel's graphics driver subsystem, specifically in the intel i915 driver's display port handling code. This issue affects systems utilizing Intel graphics hardware where the kernel attempts to manage memory allocations for LVDS (Liquid Crystal Display) data pointers during BIOS initialization. The flaw manifests in the generate_lfp_data_ptrs function which processes display configuration data from the system's BIOS firmware. When the kernel encounters specific conditions related to display pointer sizes and entries, it attempts to free memory that was not allocated through the standard kernel memory allocation functions, creating a critical memory management inconsistency.

The technical root cause stems from improper memory deallocation practices within the graphics driver's BIOS parsing logic. The program structure attempts to free memory using kfree() on a pointer that was obtained through pointer arithmetic operations rather than through kernel memory allocation functions like kzalloc() or kmalloc(). This fundamental mismatch occurs because ptrs is derived from a pointer offset operation rather than being a direct result of memory allocation, making the subsequent kfree() call invalid and potentially dangerous. The condition (size = 3) triggers the memory cleanup logic, but the pointer being freed does not point to a valid memory block allocated by the kernel's memory manager, leading to either memory leaks or undefined behavior patterns that could compromise system stability.

The operational impact of this vulnerability extends beyond simple memory leakage, potentially creating system instability and security risks within embedded systems and servers utilizing Intel graphics. When the kernel's graphics subsystem attempts to process display configuration data, the improper memory management can result in memory corruption, system crashes, or potentially exploitable conditions that might allow privilege escalation. This vulnerability affects systems where the i915 driver is actively managing display outputs, particularly those running modern Linux distributions with Intel graphics hardware. The memory leak could accumulate over time, leading to gradual system performance degradation or complete system hangs during graphics-intensive operations, making it particularly concerning for server environments and embedded systems with limited resources.

Mitigation strategies for CVE-2022-50287 require immediate kernel updates from the vendor to apply the fix that correctly identifies the memory block to be freed through the ptrs_block argument instead of the improperly derived ptrs pointer. System administrators should prioritize patching affected systems, particularly those running older kernel versions where this vulnerability remains unaddressed. The fix implements a proper memory management approach by ensuring that kfree() is called on the correct memory block that was actually allocated through kernel memory management functions. Organizations should also consider monitoring system logs for potential memory allocation errors or graphics driver instability that might indicate exploitation attempts. Additionally, implementing proper system hardening measures including kernel lockdown features and restricting graphics driver access where possible can help minimize the attack surface, though the primary defense remains the timely application of the vendor-provided security patch that resolves the underlying memory management inconsistency. This vulnerability aligns with CWE-415: Double Free and CWE-416: Use After Free categories in the Common Weakness Enumeration framework, and could potentially map to ATT&CK techniques involving privilege escalation through kernel exploitation.

Responsible

Linux

Reservation

09/15/2025

Disclosure

09/15/2025

Moderation

accepted

CPE

ready

EPSS

0.00143

KEV

no

Activities

very low

Sources

Want to stay up to date on a daily basis?

Enable the mail alert feature now!