Kernel memory corruption via premature BPF pack free
Published Jun 18, 2025 · Updated Aug 5, 2026
Use-after-free in the x86 BPF JIT in Linux 5.18 allows local users to corrupt kernel memory via a crafted multi-subprogram eBPF load. During jit_subprogs cleanup after one compilation fails, bpf_jit_free releases a shared 2 MB bpf_prog_pack before every subprogram has been finalized. Reaching the flaw requires an x86-64 host and CAP_BPF or CAP_SYS_ADMIN; reuse of the freed executable pack enables kernel disclosure, writes, control-flow hijacking, or a kernel crash.
Summary
What happened
Use-after-free in the x86 BPF JIT in Linux 5.18 allows local users to corrupt kernel memory via a crafted multi-subprogram eBPF load. During jit_subprogs cleanup after one compilation fails, bpf_jit_free releases a shared 2 MB bpf_prog_pack before every subprogram has been finalized. Reaching the flaw requires an x86-64 host and CAP_BPF or CAP_SYS_ADMIN; reuse of the freed executable pack enables kernel disclosure, writes, control-flow hijacking, or a kernel crash.
The record
- CVE
- CVE-2022-50168
- Published
- Jun 18, 2025
- Updated
- Aug 5, 2026
- Vendor
- The Linux Kernel Organization
- Product
- Linux
- Classifications
- T1068
- Attack vector
- local
- Privileges
- authenticated
Timeline
How it unfolded
- Jun 18, 2025CVE publishedPublication date reported by the CVE source.
- Aug 5, 2026Record updatedLatest update available in the CVE record.
Exploitability
Present is not the same as exploitable
Compare your product and version with the public record. A matching version still requires validation against your environment.
Is a vulnerable build present?
Compare these published version ranges with your installed build and any vendor patches.
- Affected versionversion=1022a5498f6f745c3b5fd3f050a5e11e7ca354f0 <1d5f82d9dd477d5c66e0214a68c3e4f308eadd6d
- Affected versionversion=1022a5498f6f745c3b5fd3f050a5e11e7ca354f0 <60e66074812dde9cde3d99cdd3caa9e40f1a4516
- Affected versionversion=1022a5498f6f745c3b5fd3f050a5e11e7ca354f0 <f91ce608a79c0db3e72bd63c23e011a9ebc31505
- Affected versionversion=5.18
What conditions does exploitation require?
What is affected?
Published CVSS scores
CVSS describes severity. EPSS estimates exploitation probability.
Attacks
What attackers are doing with it
Daily unique IPs observed by Shadowserver honeypots for known exploited vulnerabilities (KEVs). Missing observations do not establish an absence of attacks.
Weakness, pattern, technique
Public exploit references
No public exploit references are available in this record.
Labels summarize the accepted research assessment. They do not indicate a test against your environment.
Technologies
Your stack
See the directory against your own environment.
Your stack
Check the software in your environment
Book a demo to see how Hinoki identifies affected software and validates exploitability in your environment.
Book a demo