# CVE-2022-50167: bpf: fix potential 32-bit overflow when accessing ARRAY map element

- Severity: High 7.8 (CVSS:3.1, scored by Linux) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.28%, higher than 21% of CVEs (2026-12-01)
- Published: 2025-06-18T11:03:20.997Z
- Modified: 2026-10-30T13:17:14.400Z
- Weaknesses: CWE-190
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact total
- Assigned by: Linux

## 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.

(As written by CVE List.)

## Affected

- Linux Linux: from c85d69135a9175c50a823d04d62d932312d037b3 before 2157ac13db8d5763835f1663bdabda6de744cba8; from c85d69135a9175c50a823d04d62d932312d037b3 before f665c56e6836933335e5a4513fc9b0bf47cdf81f; from c85d69135a9175c50a823d04d62d932312d037b3 before 063e092534d4c6785228e5b1eb6e9329f66ccbe4; from c85d69135a9175c50a823d04d62d932312d037b3 before 3c7256b880b3a5aa1895fd169a34aa4224a11862; from c85d69135a9175c50a823d04d62d932312d037b3 before 87ac0d600943994444e24382a87aa19acc4cd3d4; 5.3 (not affected: before 5.3; from 5.10.273 up to 5.10.*; from 5.15.224 up to 5.15.*; from 5.18.18 up to 5.18.*; from 5.19.2 up to 5.19.*; from 6.0 up to *)
- linux linux_kernel: from 5.3 before 5.18.18; from 5.19 before 5.19.2

## Every score

- Linux: CVSS:3.1 7.8 High `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:3.1 5.5 Medium `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`

## References

- <https://git.kernel.org/stable/c/2157ac13db8d5763835f1663bdabda6de744cba8>
- <https://git.kernel.org/stable/c/f665c56e6836933335e5a4513fc9b0bf47cdf81f>
- <https://git.kernel.org/stable/c/063e092534d4c6785228e5b1eb6e9329f66ccbe4> (patch)
- <https://git.kernel.org/stable/c/3c7256b880b3a5aa1895fd169a34aa4224a11862> (patch)
- <https://git.kernel.org/stable/c/87ac0d600943994444e24382a87aa19acc4cd3d4> (patch)

## Sources

- CVE List: [CVE-2022-50167](https://www.cve.org/CVERecord?id=CVE-2022-50167), CVE Terms of Use, modified 2026-10-30
- NVD: [CVE-2022-50167](https://nvd.nist.gov/vuln/detail/CVE-2022-50167), Public domain, modified 2026-10-30

---

Page: https://cve.day/CVE-2022-50167 · Whole record: https://cve.day/CVE-2022-50167.json · Rebuilt by cve.day 2026-11-25T22:58:21.086Z
