Goal Reached Thanks to every supporter — we hit 100%!

Goal: 1000 CNY · Raised: 1000 CNY

100.0%

CVE-2021-47608— bpf: Fix kernel address leakage in atomic fetch

EPSS 0.06% · P19

Affected Version Matrix 6

VendorProductVersion RangeStatus
LinuxLinux37086bfdc737ea6f66bf68dcf16757004d68e1e1< 423628125a484538111c2c6d9bb1588eb086053baffected
37086bfdc737ea6f66bf68dcf16757004d68e1e1< 7d3baf0afa3aa9102d6a521a8e4c41888bb79882affected
5.12affected
< 5.12unaffected
5.15.11≤ 5.15.*unaffected
5.16≤ *unaffected
Get alerts for future matching vulnerabilitiesLog in to subscribe

I. Basic Information for CVE-2021-47608

Vulnerability Information

Have questions about the vulnerability? See if Shenlong's analysis helps!
View Shenlong Deep Dive ↗

Although we use advanced large model technology, its output may still contain inaccurate or outdated information.Shenlong tries to ensure data accuracy, but please verify and judge based on the actual situation.

Vulnerability Title
bpf: Fix kernel address leakage in atomic fetch
Source: NVD (National Vulnerability Database)
Vulnerability Description
In the Linux kernel, the following vulnerability has been resolved: bpf: Fix kernel address leakage in atomic fetch The change in commit 37086bfdc737 ("bpf: Propagate stack bounds to registers in atomics w/ BPF_FETCH") around check_mem_access() handling is buggy since this would allow for unprivileged users to leak kernel pointers. For example, an atomic fetch/and with -1 on a stack destination which holds a spilled pointer will migrate the spilled register type into a scalar, which can then be exported out of the program (since scalar != pointer) by dumping it into a map value. The original implementation of XADD was preventing this situation by using a double call to check_mem_access() one with BPF_READ and a subsequent one with BPF_WRITE, in both cases passing -1 as a placeholder value instead of register as per XADD semantics since it didn't contain a value fetch. The BPF_READ also included a check in check_stack_read_fixed_off() which rejects the program if the stack slot is of __is_pointer_value() if dst_regno < 0. The latter is to distinguish whether we're dealing with a regular stack spill/ fill or some arithmetical operation which is disallowed on non-scalars, see also 6e7e63cbb023 ("bpf: Forbid XADD on spilled pointers for unprivileged users") for more context on check_mem_access() and its handling of placeholder value -1. One minimally intrusive option to fix the leak is for the BPF_FETCH case to initially check the BPF_READ case via check_mem_access() with -1 as register, followed by the actual load case with non-negative load_reg to propagate stack bounds to registers.
Source: NVD (National Vulnerability Database)
CVSS Information
N/A
Source: NVD (National Vulnerability Database)
Vulnerability Type
N/A
Source: NVD (National Vulnerability Database)
Vulnerability Title
Linux kernel 安全漏洞
Source: CNNVD (China National Vulnerability Database)
Vulnerability Description
Linux kernel是美国Linux基金会的开源操作系统Linux所使用的内核。 Linux kernel存在安全漏洞,该漏洞源于对check_mem_access()处理的更改存在问题,该问题允许非特权用户泄露内核指针。
Source: CNNVD (China National Vulnerability Database)
CVSS Information
N/A
Source: CNNVD (China National Vulnerability Database)
Vulnerability Type
N/A
Source: CNNVD (China National Vulnerability Database)

Affected Products

VendorProductAffected VersionsCPESubscribe
LinuxLinux 37086bfdc737ea6f66bf68dcf16757004d68e1e1 ~ 423628125a484538111c2c6d9bb1588eb086053b -
LinuxLinux 5.12 -

II. Public POCs for CVE-2021-47608

#POC DescriptionSource LinkShenlong Link
AI-Generated POCPremium

No public POC found.

Login to generate AI POC

III. Intelligence Information for CVE-2021-47608

登录查看更多情报信息。

Same Patch Batch · Linux · 2024-06-19 · 122 CVEs total

CVE-2024-38612ipv6: sr: fix invalid unregister error path
CVE-2021-47584iocost: Fix divide-by-zero on donation from low hweight cgroup
CVE-2021-47582USB: core: Make do_proc_control() and do_proc_bulk() killable
CVE-2021-47583media: mxl111sf: change mutex_init() location
CVE-2021-47579ovl: fix warning in ovl_create_real()
CVE-2021-47580scsi: scsi_debug: Fix type in min_t to avoid stack OOB
CVE-2021-47578scsi: scsi_debug: Don't call kcalloc() if size arg is zero
CVE-2021-47576scsi: scsi_debug: Sanity check block descriptor length in resp_mode_select()
CVE-2021-47577io-wq: check for wq exit after adding new worker task_work
CVE-2024-38617kunit/fortify: Fix mismatched kvalloc()/vfree() usage
CVE-2024-38618ALSA: timer: Set lower bound of start tick time
CVE-2024-38616wifi: carl9170: re-fix fortified-memset warning
CVE-2024-38615cpufreq: exit() callback is optional
CVE-2024-38614openrisc: traps: Don't send signals to kernel mode threads
CVE-2024-38613m68k: Fix spinlock race in kernel thread creation
CVE-2024-38611media: i2c: et8ek8: Don't strip remove function when driver is builtin
CVE-2024-38603drivers/perf: hisi: hns3: Actually use devm_add_action_or_reset()
CVE-2024-38601ring-buffer: Fix a race between readers and resize checks
CVE-2024-38600ALSA: Fix deadlocks with kctl removals at disconnection
CVE-2024-38602ax25: Fix reference count leak issues of ax25_dev

Showing top 20 of 122 CVEs. View all on vendor page &rarr; →

IV. Related Vulnerabilities

V. Comments for CVE-2021-47608

No comments yet


Leave a comment