CVE-2022-49030 libbpf: Handle size overflow for ringbuf mmap
Integer overflow in libbpf ringbuf mmap handling can cause denial of service on Linux systems.
- Exploited in the wild
- Not known
- Login needed
- Any signed-in user
- Attackable
- Local or same network only
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2022-49030?
CVE-2022-49030 is a high-severity vulnerability in Linux kernel, published on 21 Oct 2024. It can only be exploited from the same machine or local network, with no action from the victim.
Official description
In the Linux kernel, the following vulnerability has been resolved:
libbpf: Handle size overflow for ringbuf mmap
The maximum size of ringbuf is 2GB on x86-64 host, so 2 * max_entries will overflow u32 when mapping producer page and data pages. Only casting max_entries to size_t is not enough, because for 32-bits application on 64-bits kernel the size of read-only mmap region also could overflow size_t.
So fixing it by casting the size of read-only mmap region into a __u64 and checking whether or not there will be overflow during mmap.
Weakness: CWE-190
Which versions are affected by CVE-2022-49030?
It affects 1 product.
Products include Linux kernel.
How do I fix CVE-2022-49030?
Apply the vendor's patch.
Is CVE-2022-49030 being exploited?
There is no known exploitation of CVE-2022-49030 in the wild and no public exploit code.
Other vulnerabilities in Linux kernel
Sources
Also known as DEBIAN-CVE-2022-49030, GHSA-75vm-7626-f557, UBUNTU-CVE-2022-49030.