Linux Kernel StarFive Crypto Memory Leak Vulnerability

Vulnerability

A memory leak vulnerability has been identified in the Linux kernel's StarFive crypto implementation, specifically within the AES AEAD request handling function. The issue arises because the function allocates memory for the 'adata' context using a zero-initialized allocation, but fails to release this memory if certain operations encounter errors. This oversight leads to memory leaks, as the allocated data is not freed under these error conditions. Although the vulnerability was discovered through static analysis and code review, it has only been compile-tested.

Impact

Exploitation of this vulnerability leads to a memory leak, causing increased memory usage and potential degradation of system performance over time.

Reproduction

The vulnerability can be reproduced by invoking the 'starfive_aes_aead_do_one_req' function with a request that triggers an error in either the 'sg_copy_to_buffer' function or the 'starfive_aes_hw_init' function'. This can be done by creating a scenario where the associated length of the cryptographic operation is not properly handled, causing the function to allocate memory for the 'adata' but not free it when an error occurs.

Remediation

Users can upgrade to the latest version of the Linux kernel where this vulnerability has been addressed. The specific commit that fixes this issue is available in the Linux kernel stable tree.

Added: May 28, 2026, 12:12 AM
Updated: May 28, 2026, 12:12 AM

Vulnerability Rating

Custom Algorithm
spread
9.0
impact
0.6
exploitability
4.3
remediation
7.7
relevance
9.1
threat
4.8
urgency
2.9
incentive
0.0

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.