CVE-2026-64539

Source
https://cve.org/CVERecord?id=CVE-2026-64539
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-64539.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2026-64539
Downstream
Published
2026-07-27T20:10:33.363Z
Modified
2026-07-29T03:48:18.369087176Z
Summary
Bluetooth: eir: Fix stack OOB write when prepending the Flags AD
Details

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

Bluetooth: eir: Fix stack OOB write when prepending the Flags AD

eircreateadvdata() builds the advertising data into a fixed-size buffer ("size", 31 for the legacy path). It may prepend a 3-byte "Flags" AD structure (LEADNOBREDR on an LE-only controller) and then copies the per-instance data without checking that it still fits:

memcpy(ptr, adv->adv_data, adv->adv_data_len);

tlvdatamaxlen() only reserves those 3 bytes when the user-supplied flags carry a managed-flags bit, so an instance added with flags == 0 is accepted with advdatalen up to the full buffer. At advertise time the flags are still prepended, and the memcpy() writes 3 + advdata_len bytes into the size-byte buffer:

BUG: KASAN: stack-out-of-bounds in eircreateadvdata (net/bluetooth/eir.c:301) Write of size 31 at addr ffff88800a547bdc by task kworker/u9:0/65 Workqueue: hci0 hcicmdsyncwork __asanmemcpy (mm/kasan/shadow.c:106) eircreateadvdata (net/bluetooth/eir.c:301) hciupdateadvdatasync (net/bluetooth/hcisync.c:1310) hcischeduleadvinstancesync (net/bluetooth/hcisync.c:1817) hcicmdsyncwork (net/bluetooth/hcisync.c:332) This frame has 1 object: [32, 64) 'cp'

The "Flags" structure is added by the kernel, not requested by userspace, so only prepend it when it fits together with the instance advertising data; when there is no room for both, drop the flags rather than the user-provided data.

Reachable by a local user with CAPNETADMIN owning an LE-only controller on the legacy advertising path.

Database specific
{
    "cna_assigner": "Linux",
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/64xxx/CVE-2026-64539.json"
}
References

Affected packages

Git / git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git

Affected ranges

Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
b44133ff03be30b55f23036e62f403a3f7784fce
Fixed
0f0b6232af56441d0a2dcb173cc4f8d8aab39014
Fixed
09301f1fdf2aef8cce34d0c4650c30e7edb1ced9
Fixed
f1b4df9c260c51726da2e86e19322825fddeefd0
Fixed
57077eeb586c42f124bc09e018449362223067b3
Fixed
6f5fb689fdf80bdd143f22a502f9eb1f3c85e286

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-64539.json"

Linux / Kernel

Package

Name
Kernel

Affected ranges

Type
ECOSYSTEM
Events
Introduced
4.1.0
Fixed
6.1.178
Type
ECOSYSTEM
Events
Introduced
6.2.0
Fixed
6.12.97
Type
ECOSYSTEM
Events
Introduced
6.13.0
Fixed
6.18.40
Type
ECOSYSTEM
Events
Introduced
6.19.0
Fixed
7.1.5

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-64539.json"