{"uuid": "294ec66e-79e8-4426-9e14-aa493cb6f201", "vulnerability_lookup_origin": "1a89b78e-f703-45f3-bb86-59eb712668bd", "author": "2a075640-a300-48a4-bb44-bc6130783b9b", "vulnerability": "CVE-2025-21664", "type": "seen", "source": "https://t.me/cvedetector/15934", "content": "{\n  \"Source\": \"CVE FEED\",\n  \"Title\": \"CVE-2025-21664 - \"Linux dm thin RCU List DoS\"\", \n  \"Content\": \"CVE ID : CVE-2025-21664 \nPublished : Jan. 21, 2025, 1:15 p.m. | 42\u00a0minutes ago \nDescription : In the Linux kernel, the following vulnerability has been resolved:  \n  \ndm thin: make get_first_thin use rcu-safe list first function  \n  \nThe documentation in rculist.h explains the absence of list_empty_rcu()  \nand cautions programmers against relying on a list_empty() -&gt;  \nlist_first() sequence in RCU safe code.  This is because each of these  \nfunctions performs its own READ_ONCE() of the list head.  This can lead  \nto a situation where the list_empty() sees a valid list entry, but the  \nsubsequent list_first() sees a different view of list head state after a  \nmodification.  \n  \nIn the case of dm-thin, this author had a production box crash from a GP  \nfault in the process_deferred_bios path.  This function saw a valid list  \nhead in get_first_thin() but when it subsequently dereferenced that and  \nturned it into a thin_c, it got the inside of the struct pool, since the  \nlist was now empty and referring to itself.  The kernel on which this  \noccurred printed both a warning about a refcount_t being saturated, and  \na UBSAN error for an out-of-bounds cpuid access in the queued spinlock,  \nprior to the fault itself.  When the resulting kdump was examined, it  \nwas possible to see another thread patiently waiting in thin_dtr's  \nsynchronize_rcu.  \n  \nThe thin_dtr call managed to pull the thin_c out of the active thins  \nlist (and have it be the last entry in the active_thins list) at just  \nthe wrong moment which lead to this crash.  \n  \nFortunately, the fix here is straight forward.  Switch get_first_thin()  \nfunction to use list_first_or_null_rcu() which performs just a single  \nREAD_ONCE() and returns NULL if the list is already empty.  \n  \nThis was run against the devicemapper test suite's thin-provisioning  \nsuites for delete and suspend and no regressions were observed. \nSeverity: 0.0 | NA \nVisit the link for more details, such as CVSS details, affected products, timeline, and more...\",\n  \"Detection Date\": \"21 Jan 2025\",\n  \"Type\": \"Vulnerability\"\n}\n\ud83d\udd39 t.me/cvedetector \ud83d\udd39", "creation_timestamp": "2025-01-21T15:17:13.000000Z"}