# CVE-2026-64436: net: af\_key: initialize alg\_key\_len for IPComp states

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** HIGH 7.1
- **CVSS:** 7.1 (v3.1, CNA) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: High; Integrity impact: None; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.17% (percentile 3, 2026-11-26)
- **CWE:** CWE-125, CWE-119
- **Published:** 2026-07-25T08:51:10.370Z
- **Modified:** 2026-10-19T21:17:38.040Z

## Who should check

- Anyone running Linux \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< 58e82fc3dedb57b1432292504415b224fd2d6acb; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< 01b9115b55018123ef2449ac4951f89147a8428e; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< 3f63d1752d90c0e28be931a48ab5d89bc97d637d; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< 273c06b81d2e902b21acc801ae18c8276c8a9b69; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< 6de2a650917bedaaefd65b17cede83c5e2c1dedd; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< e8417353cbd078d10531ba3928e609c84ab09e6b; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< cea34abc94b0a81e3a8b5cfb41cf45af37c2c67e; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< d129c3177d7b1138fd5066fcc63a698b3ba415b0
- Anyone running Linux 2.6.21

## Description

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

net: af\_key: initialize alg\_key\_len for IPComp states

pfkey\_msg2xfrm\_state() handles the IPComp (SADB\_X\_SATYPE\_IPCOMP) case by
allocating x-\>calg and copying only the algorithm name:

	x-\>calg = kmalloc\_obj(\*x-\>calg);
	if (!x-\>calg) {
		err = -ENOMEM;
		goto out;
	}
	strcpy(x-\>calg-\>alg\_name, a-\>name);
	x-\>props.calgo = sa-\>sadb\_sa\_encrypt;

Unlike the authentication (x-\>aalg) and encryption (x-\>ealg) branches of
the same function, the compression branch never initializes
calg-\>alg\_key\_len.  IPComp carries no key and the allocation only
reserves sizeof(struct xfrm\_algo) (i.e. no room for a key), so the field
is left containing uninitialized slab data.

calg-\>alg\_key\_len is later used as a length by xfrm\_algo\_clone() when an
IPComp state is cloned during XFRM\_MSG\_MIGRATE:

	xfrm\_state\_migrate()
	  xfrm\_state\_clone\_and\_setup()
	    x-\>calg = xfrm\_algo\_clone(orig-\>calg);
	      kmemdup(orig, xfrm\_alg\_len(orig));

where xfrm\_alg\_len() returns sizeof(\*alg) + (alg\_key\_len + 7) / 8.  With
a non-zero garbage alg\_key\_len, kmemdup() reads past the end of the
68-byte calg object.  Adding an IPComp SA via PF\_KEY and then migrating
it triggers (net-next, KASAN, init\_on\_alloc=0):

  BUG: KASAN: slab-out-of-bounds in kmemdup\_noprof+0x44/0x60
  Read of size 4164 at addr ff11000025a74980 by task diag2/9287
  CPU: 3 UID: 0 PID: 9287 Comm: diag2 7.1.0-rc6-g903db046d557 \#1
  Call Trace:
   \<TASK\>
   dump\_stack\_lvl+0x10e/0x1f0
   print\_report+0xf7/0x600
   kasan\_report+0xe4/0x120
   kasan\_check\_range+0x105/0x1b0
   \_\_asan\_memcpy+0x23/0x60
   kmemdup\_noprof+0x44/0x60
   xfrm\_state\_migrate+0x70a/0x1da0
   xfrm\_migrate+0x753/0x18a0
   xfrm\_do\_migrate+0xb47/0xf10
   xfrm\_user\_rcv\_msg+0x411/0xb50
   netlink\_rcv\_skb+0x158/0x420
   xfrm\_netlink\_rcv+0x71/0x90
   netlink\_unicast+0x584/0x850
   netlink\_sendmsg+0x8b0/0xdc0
   \_\_\_\_sys\_sendmsg+0x9f7/0xb90
   \_\_\_sys\_sendmsg+0x134/0x1d0
   \_\_sys\_sendmsg+0x16d/0x220
   do\_syscall\_64+0x116/0x7d0
   entry\_SYSCALL\_64\_after\_hwframe+0x77/0x7f
   \</TASK\>

  Allocated by task 9287:
   kasan\_save\_stack+0x33/0x60
   kasan\_save\_track+0x14/0x30
   \_\_kasan\_kmalloc+0xaa/0xb0
   pfkey\_add+0x2652/0x2ea0
   pfkey\_process+0x6d0/0x830
   pfkey\_sendmsg+0x42c/0x850
   \_\_sys\_sendto+0x461/0x4b0
   \_\_x64\_sys\_sendto+0xe0/0x1c0
   do\_syscall\_64+0x116/0x7d0
   entry\_SYSCALL\_64\_after\_hwframe+0x77/0x7f

  The buggy address belongs to the object at ff11000025a74980
   which belongs to the cache kmalloc-96 of size 96
  The buggy address is located 0 bytes inside of
   allocated 68-byte region \[ff11000025a74980, ff11000025a749c4)

Depending on the uninitialized value the same field can instead request
an oversized kmemdup() allocation and make the migration clone fail.

The XFRM netlink path is not affected: verify\_one\_alg() rejects an
XFRMA\_ALG\_COMP attribute shorter than xfrm\_alg\_len(), so a calg added via
XFRM\_MSG\_NEWSA is always self-consistent.

Initialize calg-\>alg\_key\_len to 0, matching the aalg/ealg branches.

## Affected and fixed versions

- Linux: \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< 58e82fc3dedb57b1432292504415b224fd2d6acb; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< 01b9115b55018123ef2449ac4951f89147a8428e; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< 3f63d1752d90c0e28be931a48ab5d89bc97d637d; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< 273c06b81d2e902b21acc801ae18c8276c8a9b69; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< 6de2a650917bedaaefd65b17cede83c5e2c1dedd; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< e8417353cbd078d10531ba3928e609c84ab09e6b; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< cea34abc94b0a81e3a8b5cfb41cf45af37c2c67e; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< d129c3177d7b1138fd5066fcc63a698b3ba415b0 (cvelist)
- Linux: 2.6.21 (cvelist)

## Mitigation

- No fix listed yet: follow the vendor advisory.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2026-64436. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2026-64436.md
Affected: Linux >= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, < 58e82fc3dedb57b1432292504415b224fd2d6acb; >= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, < 01b9115b55018123ef2449ac4951f89147a8428e; >= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, < 3f63d1752d90c0e28be931a48ab5d89bc97d637d; >= 80c9abaabf4283f7cf4a0b3…
Fixed in: Linux 58e82fc3dedb57b1432292504415b224fd2d6acb, Linux 01b9115b55018123ef2449ac4951f89147a8428e, Linux 3f63d1752d90c0e28be931a48ab5d89bc97d637d, Linux 273c06b81d2e902b21acc801ae18c8276c8a9b69, Linux 6de2a650917bedaaefd65b17cede83c5e2c1dedd

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2026-64436 being exploited?

There is no confirmed exploitation: CVE-2026-64436 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.17% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2026-64436?

High: CVSS 7.1 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2026-64436?

Linux \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< 58e82fc3dedb57b1432292504415b224fd2d6acb; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< 01b9115b55018123ef2449ac4951f89147a8428e; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< 3f63d1752d90c0e28be931a48ab5d89bc97d637d; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< 273c06b81d2e902b21acc801ae18c8276c8a9b69; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< 6de2a650917bedaaefd65b17cede83c5e2c1dedd; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< e8417353cbd078d10531ba3928e609c84ab09e6b; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< cea34abc94b0a81e3a8b5cfb41cf45af37c2c67e; \>= 80c9abaabf4283f7cf4a0b3597cd302506635b7f, \< d129c3177d7b1138fd5066fcc63a698b3ba415b0; Linux 2.6.21.

### Is there a fix for CVE-2026-64436?

Yes. Fixed in Linux 58e82fc3dedb57b1432292504415b224fd2d6acb, Linux 01b9115b55018123ef2449ac4951f89147a8428e, Linux 3f63d1752d90c0e28be931a48ab5d89bc97d637d, Linux 273c06b81d2e902b21acc801ae18c8276c8a9b69, Linux 6de2a650917bedaaefd65b17cede83c5e2c1dedd. No fix listed yet: follow the vendor advisory.

### How do I check if I'm affected by CVE-2026-64436?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- patch: <https://git.kernel.org/stable/c/58e82fc3dedb57b1432292504415b224fd2d6acb>
- patch: <https://git.kernel.org/stable/c/01b9115b55018123ef2449ac4951f89147a8428e>
- patch: <https://git.kernel.org/stable/c/3f63d1752d90c0e28be931a48ab5d89bc97d637d>
- patch: <https://git.kernel.org/stable/c/273c06b81d2e902b21acc801ae18c8276c8a9b69>
- patch: <https://git.kernel.org/stable/c/6de2a650917bedaaefd65b17cede83c5e2c1dedd>
- patch: <https://git.kernel.org/stable/c/e8417353cbd078d10531ba3928e609c84ab09e6b>
- patch: <https://git.kernel.org/stable/c/cea34abc94b0a81e3a8b5cfb41cf45af37c2c67e>
- patch: <https://git.kernel.org/stable/c/d129c3177d7b1138fd5066fcc63a698b3ba415b0>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2026-64436>

HTML: <https://flawdb.com/CVE-2026-64436> · JSON: <https://flawdb.com/api/v1/entries/CVE-2026-64436>
