{"schema":"/api/v1/schema/cve.json","api_version":"1","id":"CVE-2021-47608","published":"2024-06-19T15:15:55.360000Z","last_modified":"2026-06-17T04:18:09.287000Z","status":"Modified","cvss":{"version":"3.1","score":5.5,"severity":"MEDIUM","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N","source":"nvd@nist.gov","primary":true},"auth":true,"cwes":[],"cpes":[{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","part":"o","vendor":"linux","product":"linux_kernel","version_start_including":"5.12","version_end_excluding":"5.15.11"},{"criteria":"cpe:2.3:o:linux:linux_kernel:5.16:rc1:*:*:*:*:*:*","part":"o","vendor":"linux","product":"linux_kernel","version":"5.16"},{"criteria":"cpe:2.3:o:linux:linux_kernel:5.16:rc2:*:*:*:*:*:*","part":"o","vendor":"linux","product":"linux_kernel","version":"5.16"},{"criteria":"cpe:2.3:o:linux:linux_kernel:5.16:rc3:*:*:*:*:*:*","part":"o","vendor":"linux","product":"linux_kernel","version":"5.16"},{"criteria":"cpe:2.3:o:linux:linux_kernel:5.16:rc4:*:*:*:*:*:*","part":"o","vendor":"linux","product":"linux_kernel","version":"5.16"},{"criteria":"cpe:2.3:o:linux:linux_kernel:5.16:rc5:*:*:*:*:*:*","part":"o","vendor":"linux","product":"linux_kernel","version":"5.16"}],"cpes_truncated":false,"vendors":["linux"],"products":["linux/linux_kernel"],"ssvc":{"exploitation":"none","automatable":"no","technical_impact":"partial"},"epss":{"score":0.00291,"percentile":0.14208,"date":"2026-11-29","model_version":"v2026.06.15"},"cat":"os","platform":"linux","eol":false,"packages":[],"severity":"medium","priority_score":33,"links":{"html_es":"/es/cve/CVE-2021-47608/","html_en":"/en/cve/CVE-2021-47608/","nvd":"https://nvd.nist.gov/vuln/detail/CVE-2021-47608","cve_org":"https://www.cve.org/CVERecord?id=CVE-2021-47608"},"untrusted":{"vendor_name":"Linux","product_name":"Linux Kernel","desc_en":"In the Linux kernel, the following vulnerability has been resolved:\n\nbpf: Fix kernel address leakage in atomic fetch\n\nThe change in commit 37086bfdc737 (\"bpf: Propagate stack bounds to registers\nin atomics w/ BPF_FETCH\") around check_mem_access() handling is buggy since\nthis would allow for unprivileged users to leak kernel pointers. For example,\nan atomic fetch/and with -1 on a stack destination which holds a spilled\npointer will migrate the spilled register type into a scalar, which can then\nbe exported out of the program (since scalar != pointer) by dumping it into\na map value.\n\nThe original implementation of XADD was preventing this situation by using\na double call to check_mem_access() one with BPF_READ and a subsequent one\nwith BPF_WRITE, in both cases passing -1 as a placeholder value instead of\nregister as per XADD semantics since it didn't contain a value fetch. The\nBPF_READ also included a check in check_stack_read_fixed_off() which rejects\nthe program if the stack slot is of __is_pointer_value() if dst_regno < 0.\nThe latter is to distinguish whether we're dealing with a regular stack spill/\nfill or some arithmetical operation which is disallowed on non-scalars, see\nalso 6e7e63cbb023 (\"bpf: Forbid XADD on spilled pointers for unprivileged\nusers\") for more context on check_mem_access() and its handling of placeholder\nvalue -1.\n\nOne minimally intrusive option to fix the leak is for the BPF_FETCH case to\ninitially check the BPF_READ case via check_mem_access() with -1 as register,\nfollowed by the actual load case with non-negative load_reg to propagate\nstack bounds to registers.","affected":[{"untrusted_vendor":"Linux","untrusted_product":"Linux","versions":[]}],"references":[{"url":"https://git.kernel.org/stable/c/423628125a484538111c2c6d9bb1588eb086053b","tags":["Patch"]},{"url":"https://git.kernel.org/stable/c/7d3baf0afa3aa9102d6a521a8e4c41888bb79882","tags":["Patch"]}]}}