xfrm: clear trailing padding in build_polexpire()
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 · < b1dfd6b27df35ef4f87825aa5f607378d23ff0f2| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
xfrm: clear trailing padding in build_polexpire()
build_expire() clears the trailing padding bytes of struct xfrm_user_expire after setting the hard field via memset_after(), but the analogous function build_polexpire() does not do this for struct xfrm_user_polexpire.
The padding bytes after the __u8 hard field are left uninitialized from the heap allocation, and are then sent to userspace via netlink multicast to XFRMNLGRP_EXPIRE listeners, leaking kernel heap memory contents.
Add the missing memset_after() call, matching build_expire().
From the CVE record · Linux
The Linux kernel's build_polexpire() leaves padding bytes uninitialized in XFRM policy expiration messages. Kernel heap contents can be exposed to userspace listeners receiving those messages through netlink multicast; the input does not specify authentication requirements or user interaction.
Engineers running the Linux kernel should check their versions; the affected versions are not specified.