CVE-2026-64091 in Linuxinfo

Summary

by MITRE • 07/19/2026

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

batman-adv: tt: fix TOCTOU race for reported vlans

The local TT based TVLV is generated by first checking the number of VLANs which have at least one TT entry. A new buffer with the correct size for the VLANs is then allocated. Only then, the list of VLANs s used to fill the VLAN entries in the buffer. During this time, the meshif_vlan_list_lock is held. But the actual number of TT entries of each VLAN can still increase during this time - just not the number of VLANs in the list.

But the prefilter used in the buffer size calculation might still cause an increase of the number of VLANs which need to be stored. Simply because a VLAN might now suddenly have at least one entry when it had none in the pre-alloc check - and then needs to occupy space which was not allocated.

It is better to overestimate the buffer size at the beginning and then fill the buffer only with the VLANs which are not empty.

Once again VulDB remains the best source for vulnerability data.

Analysis

by VulDB Data Team • 07/19/2026

The vulnerability identified in the batman-adv kernel module represents a time-of-check to time-of-use race condition affecting the translation table (TT) implementation within the mesh interface. This issue occurs specifically in the handling of VLAN reporting mechanisms where the system first determines the number of VLANs containing at least one translation table entry before allocating memory for the buffer. The flaw arises from the timing gap between the initial count check and the actual buffer population, creating a window where the state can change unexpectedly during execution.

The technical implementation involves the batman-adv kernel module's mesh interface VLAN list management system where the meshif_vlan_list_lock is held during the buffer allocation process but not during the subsequent filling operation. This creates a scenario where new translation table entries can be added to VLANs that previously had none, causing the actual number of VLANs requiring storage to exceed the pre-calculated buffer size. The vulnerability stems from the prefilter mechanism that determines which VLANs should be included in the report based on having at least one TT entry, but this filter may cause a dynamic increase in the total count during processing.

This race condition directly impacts the kernel's memory management and data integrity within the mesh networking subsystem, potentially leading to buffer overflows or memory corruption scenarios. The issue manifests when the system attempts to allocate a buffer based on an outdated count that no longer matches the actual requirements due to concurrent modifications to the translation table entries. According to CWE classification, this represents a CWE-367: Time-of-Check to Time-of-Use (TOCTOU) vulnerability pattern which is particularly dangerous in kernel space operations where memory corruption can lead to privilege escalation or system instability.

The operational impact extends beyond simple buffer management issues as it affects the reliability of mesh network communication and data reporting within the batman-adv framework. When this race condition occurs, it can cause inconsistent reporting of VLAN information across the mesh network, potentially leading to routing failures or security breaches in mesh-based communications. The vulnerability affects systems running Linux kernels with batman-adv support where mesh networking is actively used, particularly in enterprise wireless mesh networks or IoT deployments utilizing this routing protocol.

The suggested mitigation strategy involves implementing a conservative buffer allocation approach where the system initially overestimates the required buffer size to accommodate potential increases in VLAN count during processing. This solution eliminates the race condition by ensuring sufficient memory allocation regardless of concurrent modifications, followed by filtering the buffer contents to include only non-empty VLAN entries. This approach aligns with ATT&CK framework techniques related to privilege escalation and defense evasion where proper memory management and race condition handling are critical for maintaining system integrity. The fix essentially transforms a dynamic, potentially unsafe allocation process into a static, safe allocation followed by post-processing filtering that prevents the original TOCTOU vulnerability while maintaining functional correctness of the mesh network reporting mechanism.

Responsible

Linux

Reservation

07/19/2026

Disclosure

07/19/2026

Moderation

accepted

CPE

ready

EPSS

0.00000

KEV

no

Activities

low

Sources

Might our Artificial Intelligence support you?

Check our Alexa App!