Memory Leak in jffs2_do_fill_super in Kernel

Kernel Updated 02 Oct 2025

Summary

28/06/2022
N/A
No i
Unrated
Not published

GSD-2022-1003858: jffs2: fix memory leak in jffs2_do_fill_super. Affects Kernel versions >= e631ddba588783edd521c5a89f7b2902772fb691, < 28048a4cf3813b7cf5cc8cce629dfdc7951cb1c2. No fix is published. How to fix ↓

Free scan

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.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

The Kernel is a critical component of the Linux operating system that provides core functionalities and interfaces between hardware and software. It is responsible for managing system resources, including memory, processes, and device drivers. The jffs2 file system is a flash-friendly file system used in embedded systems. It is designed to work efficiently with flash memory devices, providing wear leveling and other optimizations.

However, a vulnerability has been identified in the jffs2_do_fill_super function of the Kernel, which can lead to a memory leak. This function is responsible for initializing the jffs2 file system superblock and mounting the file system. The memory leak occurs when an error condition is encountered during the initialization process, causing allocated memory to be leaked without proper deallocation.

This vulnerability can be exploited by an attacker to exhaust system memory resources, leading to a denial of service condition. Additionally, it may also impact system stability and performance.

Vulnerability Detail

The vulnerability in jffs2_do_fill_super is due to a failure to properly release allocated memory in error scenarios. When an error occurs during the initialization of the jffs2 file system superblock, the function fails to free the previously allocated memory, resulting in a memory leak. This can be triggered by various error conditions, such as invalid file system parameters or corrupted file system data.

An attacker can exploit this vulnerability by repeatedly triggering the error condition, causing the system to gradually consume all available memory resources. This can lead to a denial of service condition, where the system becomes unresponsive or crashes due to lack of memory.

The vulnerability was introduced in version 2.6.15 of the Kernel and has been present in subsequent versions until it was fixed in version 4.19.247. The fix involves proper deallocation of memory in error scenarios, preventing the memory leak from occurring.

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

If updating the Kernel is not immediately feasible, a possible workaround for mitigating the memory leak vulnerability is to avoid using the jffs2 file system. Instead, consider using an alternative file system that does not exhibit the same vulnerability.

For example, you can switch to the ext4 file system by following these steps:

  1. Backup any important data stored on the jffs2 file system.
  2. Create a new partition or use an existing one to format as ext4.
  3. Format the partition as ext4 using the appropriate command (e.g., mkfs.ext4).
  4. Mount the newly formatted partition as the desired mount point.
  5. Update the system configuration (e.g., /etc/fstab) to reflect the changes.

By switching to an alternative file system, you can avoid the memory leak vulnerability in jffs2_do_fill_super until a Kernel update can be performed.

Conclusion

The memory leak vulnerability in jffs2_do_fill_super can have serious consequences, including system instability, performance degradation, and denial of service. It is crucial to update the Kernel to version 4.19.247 or later to fix the vulnerability. If immediate updating is not possible, switching to an alternative file system like ext4 can serve as a temporary workaround. For further support on vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for Kernel →

Share this vulnerability

FAQ

The vulnerability can lead to a memory leak, causing the system to gradually consume all available memory resources. This can result in a denial of service condition, system instability, and performance degradation.

An attacker can exploit this vulnerability by repeatedly triggering the error condition during the initialization of the jffs2 file system superblock. This can be done by providing invalid file system parameters or corrupted file system data.

The vulnerability was introduced in version 2.6.15 of the Kernel and has been present in subsequent versions until it was fixed in version 4.19.247.

Yes, a possible workaround is to avoid using the jffs2 file system and switch to an alternative file system, such as ext4.

To update the Kernel, you need to identify the current version installed, check for a newer version, download the latest version from the official Linux Kernel repository, compile and install it, and then reboot the system.

Related vulnerabilities

Recent vulnerabilities recorded for Kernel.

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 →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback