# CVE-2022-48770: bpf: Guard against accessing NULL pt_regs in bpf_get_task_stack()

- Severity: Medium 5.5 (CVSS:3.1, scored by NVD) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/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.22%, higher than 12% of CVEs (2026-12-02)
- Published: 2024-06-20T11:13:45.193Z
- Modified: 2026-06-17T05:16:09.197Z
- Weaknesses: CWE-476
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: Linux

## Description

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

bpf: Guard against accessing NULL pt_regs in bpf_get_task_stack()

task_pt_regs() can return NULL on powerpc for kernel threads. This is
then used in __bpf_get_stack() to check for user mode, resulting in a
kernel oops. Guard against this by checking return value of
task_pt_regs() before trying to obtain the call chain.

(As written by CVE List.)

## Affected

- Linux Linux: from fa28dcb82a38f8e3993b0fae9106b1a80b59e4f0 before ff6bdc205fd0a83bd365405d4e31fb5905826996; from fa28dcb82a38f8e3993b0fae9106b1a80b59e4f0 before 0bcd484587b3b3092e448d27dc369e347e1810c3; from fa28dcb82a38f8e3993b0fae9106b1a80b59e4f0 before b82ef4985a6d05e80f604624332430351df7b79a; from fa28dcb82a38f8e3993b0fae9106b1a80b59e4f0 before b992f01e66150fc5e90be4a96f5eb8e634c8249e; 5.9 (not affected: before 5.9; from 5.10.96 up to 5.10.*; from 5.15.19 up to 5.15.*; from 5.16.5 up to 5.16.*; from 5.17 up to *)
- linux linux_kernel: from 5.9 before 5.10.96; from 5.11 before 5.15.19; from 5.16 before 5.16.5; 5.17

## References

- <https://git.kernel.org/stable/c/ff6bdc205fd0a83bd365405d4e31fb5905826996> (patch)
- <https://git.kernel.org/stable/c/0bcd484587b3b3092e448d27dc369e347e1810c3> (patch)
- <https://git.kernel.org/stable/c/b82ef4985a6d05e80f604624332430351df7b79a> (patch)
- <https://git.kernel.org/stable/c/b992f01e66150fc5e90be4a96f5eb8e634c8249e> (patch)

## Sources

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

---

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