CVE-2022-50167 bpf: fix potential 32-bit overflow when accessing ARRAY map element
An integer overflow in the Linux kernel BPF subsystem allows attackers to potentially execute arbitrary code or escalate privileges via large array maps.
- 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-50167?
CVE-2022-50167 is a high-severity vulnerability in Linux kernel, published on 18 Jun 2025. 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:
bpf: fix potential 32-bit overflow when accessing ARRAY map element
If BPF array map is bigger than 4GB, element pointer calculation can overflow because both index and elem_size are u32. Fix this everywhere by forcing 64-bit multiplication. Extract this formula into separate small helper and use it consistently in various places.
Speculative-preventing formula utilizing index_mask trick is left as is, but explicit u64 casts are added in both places.
Weakness: CWE-190
Which versions are affected by CVE-2022-50167?
It affects 1 product.
Products include Linux kernel.
How do I fix CVE-2022-50167?
Apply the vendor's patch.
Is CVE-2022-50167 being exploited?
There is no known exploitation of CVE-2022-50167 in the wild and no public exploit code.
Other vulnerabilities in Linux kernel
Sources
Also known as AZL-70361, DEBIAN-CVE-2022-50167, GHSA-mrhw-xcq4-7jw7, ROOT-OS-DEBIAN-11-CVE-2022-50167, ROOT-OS-UBUNTU-2204-CVE-2022-50167, UBUNTU-CVE-2022-50167.