{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2024-42067","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","state":"PUBLISHED","assignerShortName":"Linux","dateReserved":"2024-07-29T15:50:41.168Z","datePublished":"2024-07-29T15:52:31.825Z","dateUpdated":"2026-08-05T11:35:26.064Z"},"containers":{"cna":{"providerMetadata":{"orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","shortName":"Linux","dateUpdated":"2026-08-05T11:35:26.064Z"},"descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nbpf: Take return from set_memory_rox() into account with bpf_jit_binary_lock_ro()\n\nset_memory_rox() can fail, leaving memory unprotected.\n\nCheck return and bail out when bpf_jit_binary_lock_ro() returns\nan error."}],"metrics":[{"cvssV3_1":{"version":"3.1","vectorString":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","baseScore":7.8,"baseSeverity":"HIGH"},"scenarios":[{"lang":"en","value":"AV:L - The JIT is driven only from local syscalls — `setsockopt(SO_ATTACH_FILTER)`, `seccomp(SECCOMP_SET_MODE_FILTER)`, or `bpf()` — all requiring local access to the machine. No remote peer can cause a BPF program to be JIT-compiled.\nAC:L - The precondition is a page-table allocation failure inside `set_memory_rox()`, and memory pressure is something a local attacker directly influences by ballooning allocations while spraying thousands of concurrent filter attachments. Both sides of the condition are under attacker control, so this is not a state beyond their influence.\nPR:L - A completely unprivileged user reaches `bpf_int_jit_compile()` through `sk_attach_filter()` on any socket or through `seccomp()` under NO_NEW_PRIVS — no CAP_BPF, no CAP_NET_ADMIN, and no user namespace required. Only a basic local account is needed.\nUI:N - The attacker attaches the filter and triggers execution entirely from their own process. No victim action, mount, or file open is involved.\nS:U - The unprotected memory and the resulting crash or code injection are all within the kernel's own security authority. No VM, IOMMU, or sandbox boundary is crossed.\nC:H - A failed lock leaves a writable, executable kernel page containing attacker-influenced JIT output, which is a direct kernel code-injection primitive when paired with any write; injected code yields arbitrary kernel memory disclosure. The loss of the read-only guarantee on executable memory is a full compromise of confidentiality in the worst case.\nI:H - On arm32 the JIT buffer stays RWX with attacker-chosen immediates embedded in it — precisely the JIT-spray/control-flow-hijack scenario that `bpf_jit_binary_lock_ro()` exists to prevent, permitting arbitrary kernel code execution. Kernel executable memory silently remaining writable is an integrity failure of the highest order.\nA:H - On s390 and x86-32 the buffer is allocated NX and only becomes executable via `set_memory_rox()`; on failure the JIT still sets `bpf_func`/`jited = 1`, so the first run of the filter faults on an instruction fetch from a non-executable page and oopses the kernel. An unprivileged user can repeat this to panic the system."}]}],"affected":[{"product":"Linux","vendor":"Linux","defaultStatus":"unaffected","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["arch/arm/net/bpf_jit_32.c","arch/loongarch/net/bpf_jit.c","arch/mips/net/bpf_jit_comp.c","arch/parisc/net/bpf_jit_core.c","arch/s390/net/bpf_jit_comp.c","arch/sparc/net/bpf_jit_comp_64.c","arch/x86/net/bpf_jit_comp32.c","include/linux/filter.h"],"versions":[{"version":"d48567c9a0d1e605639f8a8705a61bbb55fb4e84","lessThan":"044da7ae7afd4ef60806d73654a2e6a79aa4ed7a","status":"affected","versionType":"git"},{"version":"d48567c9a0d1e605639f8a8705a61bbb55fb4e84","lessThan":"e60adf513275c3a38e5cb67f7fd12387e43a3ff5","status":"affected","versionType":"git"}]},{"product":"Linux","vendor":"Linux","defaultStatus":"affected","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["arch/arm/net/bpf_jit_32.c","arch/loongarch/net/bpf_jit.c","arch/mips/net/bpf_jit_comp.c","arch/parisc/net/bpf_jit_core.c","arch/s390/net/bpf_jit_comp.c","arch/sparc/net/bpf_jit_comp_64.c","arch/x86/net/bpf_jit_comp32.c","include/linux/filter.h"],"versions":[{"version":"6.2","status":"affected"},{"version":"0","lessThan":"6.2","status":"unaffected","versionType":"semver"},{"version":"6.9.8","lessThanOrEqual":"6.9.*","status":"unaffected","versionType":"semver"},{"version":"6.10","lessThanOrEqual":"*","status":"unaffected","versionType":"original_commit_for_fix"}]}],"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.2","versionEndExcluding":"6.9.8"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.2","versionEndExcluding":"6.10"}]}]}],"references":[{"url":"https://git.kernel.org/stable/c/044da7ae7afd4ef60806d73654a2e6a79aa4ed7a"},{"url":"https://git.kernel.org/stable/c/e60adf513275c3a38e5cb67f7fd12387e43a3ff5"}],"title":"bpf: Take return from set_memory_rox() into account with bpf_jit_binary_lock_ro()","x_generator":{"engine":"bippy-1.2.0"}},"adp":[{"providerMetadata":{"orgId":"af854a3a-2127-422b-91ae-364da2661108","shortName":"CVE","dateUpdated":"2024-08-02T04:54:31.321Z"},"title":"CVE Program Container","references":[{"url":"https://git.kernel.org/stable/c/08f6c05feb1db21653e98ca84ea04ca032d014c7","tags":["x_transferred"]},{"url":"https://git.kernel.org/stable/c/9fef36cad60d4226f9d06953cd56d1d2f9119730","tags":["x_transferred"]},{"url":"https://git.kernel.org/stable/c/044da7ae7afd4ef60806d73654a2e6a79aa4ed7a","tags":["x_transferred"]},{"url":"https://git.kernel.org/stable/c/e60adf513275c3a38e5cb67f7fd12387e43a3ff5","tags":["x_transferred"]}]},{"metrics":[{"other":{"type":"ssvc","content":{"id":"CVE-2024-42067","role":"CISA Coordinator","options":[{"Exploitation":"none"},{"Automatable":"no"},{"Technical Impact":"partial"}],"version":"2.0.3","timestamp":"2024-09-10T16:19:56.137791Z"}}}],"title":"CISA ADP Vulnrichment","providerMetadata":{"orgId":"134c704f-9b21-4f2e-91b3-4a467353bcc0","shortName":"CISA-ADP","dateUpdated":"2024-09-11T17:33:58.173Z"}}]}}