Memory Leak in ab8500_fg_sysfs_init in Kernel
Summary
GSD-2022-1002356: power: supply: ab8500: Fix memory leak in ab8500_fg_sysfs_init. Affects Kernel versions >= 8c0984e5a75337df513047ec92a6c09d78e3e5cd, < db3a61ef8e6aef3b888baa6a85926c2230c2cc56. No fix is published. How to fix ↓
Check if this vulnerability affects your application
Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.
No signup required · Results in about 60 seconds
Background
The Kernel is a critical component of the Linux operating system that acts as a bridge between the hardware and software layers. It provides essential functionalities, such as device drivers, memory management, and process scheduling. The ab8500_fg_sysfs_init function is responsible for initializing the sysfs interface for the AB8500 fuel gauge driver in the Kernel. This driver is used to monitor the battery level and provide power-related information on devices that utilize the AB8500 power management chip.
Vulnerability Detail
The ab8500_fg_sysfs_init function in the Kernel suffers from a memory leak vulnerability. This vulnerability was introduced in version v4.9 of the Kernel by commit 8c0984e5a75337df513047ec92a6c09d78e3e5cd and affects all subsequent versions until it was fixed in v4.19.238 by commit db3a61ef8e6aef3b888baa6a85926c2230c2cc56. The vulnerability occurs when the ab8500_fg_sysfs_init function fails to release allocated memory in certain error scenarios, leading to a continuous consumption of memory resources. If exploited, this vulnerability could result in a denial-of-service condition due to memory exhaustion, potentially impacting the stability and performance of the system.
How To Fix
No fixed version is published for this vulnerability.
Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →
Workaround
As a temporary workaround, users can unload and reload the AB8500 fuel gauge driver module to release the allocated memory. This can be achieved by executing the following commands as root:
rmmod ab8500_fg
modprobe ab8500_fg
Conclusion
In conclusion, the ab8500_fg_sysfs_init function in the Kernel suffers from a memory leak vulnerability that can lead to a denial-of-service condition. It is crucial to update the Kernel to version v4.19.238 or later to mitigate this vulnerability. In the meantime, a temporary workaround involving unloading and reloading the AB8500 fuel gauge driver module can be applied. For further support on vulnerability remediation, please contact DevNack.com.
See every vulnerability recorded for Kernel →
FAQ
If exploited, this vulnerability can lead to a denial-of-service condition due to memory exhaustion, potentially affecting the stability and performance of the system.
The vulnerability was introduced in version v4.9 of the Kernel and affects all subsequent versions until it was fixed in v4.19.238.
Yes, a temporary workaround involves unloading and reloading the AB8500 fuel gauge driver module.
To fix this vulnerability, it is recommended to update the Kernel to version v4.19.238 or later by obtaining the updated Kernel source code from the official Linux Kernel repository.
For more details about this vulnerability, you can refer to the source link provided in the database specific information section of the vulnerability report.
Related vulnerabilities
Recent vulnerabilities recorded for Kernel.