CVE-2025-38398
Linux Ubuntu vulnerability analysis and mitigation

Overview

A memory corruption vulnerability was discovered in the Linux kernel's SPI QPIC SNAND driver, identified as CVE-2025-38398. The issue was disclosed on July 25, 2025, affecting the spi-qpic-snand component. The vulnerability stems from improper memory allocation for BAM transactions, where the initial allocation is done for only one 'codeword' before the actual required size is known (NVD).

Technical details

The vulnerability occurs when the driver performs flash operations where the number of required transactions exceeds the size of the allocated arrays, leading to out-of-bounds memory access. The issue manifests in two ways: first, through swiotlb mapping failures with error messages indicating buffer fullness, and second, through system panics due to NULL pointer dereference or bad spinlock magic. The root cause is traced to the qcomnandcalloc() function which allocates memory for BAM transactions during probe, but only for one 'codeword' when the actual required space depends on the pagesize of the NAND chip (NVD).

Impact

The vulnerability can lead to system crashes, memory corruption, and potential system instability. When triggered, it can cause either a swiotlb buffer overflow or system panics due to NULL pointer dereference. This affects systems using the mtd_nandbiterrs module for testing the driver (NVD).

Mitigation and workarounds

The fix involves modifying the code to free the initially allocated BAM transactions memory and allocate new memory once the actual number of 'codewords' required for a given NAND chip is known (NVD).

Additional resources


SourceThis report was generated using AI

Related Linux Ubuntu vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2025-64460HIGH7.5
  • Linux DebianLinux Debian
  • python-django
NoYesDec 02, 2025
CVE-2025-13735HIGH7.4
  • Linux UbuntuLinux Ubuntu
  • linux-fips
NoNoNov 26, 2025
CVE-2025-13372MEDIUM4.3
  • Linux DebianLinux Debian
  • py3-django
NoYesDec 02, 2025
CVE-2025-2486LOW3.7
  • Linux UbuntuLinux Ubuntu
  • edk2
NoYesNov 26, 2025
CVE-2025-66270N/AN/A
  • Linux DebianLinux Debian
  • kdeconnect
NoYesNov 27, 2025

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management