Lune

USENIX Security2017顶会

How Double-Fetch Situations turn into Double-Fetch Vulnerabilities: A Study of Double Fetches in the Linux Kernel

Pengfei Wang, Jens Krinke, Kai Lu, Gen Li, Steve Dodier-Lazaro

摘要

We present the first static approach that systematically detects potential double-fetch vulnerabilities in the Linux kernel. Using a pattern-based analysis, we identified 90 double fetches in the Linux kernel. 57 of these occur in drivers, which previous dynamic approaches were unable to detect without access to the corresponding hardware. We manually investigated the 90 occurrences, and inferred three typical scenarios in which double fetches occur. We discuss each of them in detail. We further developed a static analysis, based on the Coccinelle matching engine, that detects double-fetch situations which can cause kernel vulnerabilities. When applied to the Linux, FreeBSD, and Android kernels, our approach found six previously unknown double-fetch bugs, four of them in drivers, three of which are exploitable double-fetch vulnerabilities. All of the identified bugs and vulnerabilities have been confirmed and patched by maintainers. Our approach has been adopted by the Coccinelle team and is currently being integrated into the Linux kernel patch vetting. Based on our study, we also provide practical solutions for anticipating double-fetch bugs and vulnerabilities. We also provide a solution to automatically patch detected double-fetch bugs.

问 Lune

几分钟读透这篇 Paper,不用再花一下午。

Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。

已有 20 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。

可以从这些问题问起

Lune 可以查阅

全文 · 引用它的顶会 Paper · 相关的 Paper

获取答案

免费开始,无需绑卡

脉络

  • PeriScope: An Effective Probing and Fuzzing Framework for the Hardware-OS Boundary 引用了 Precise and Scalable Detection of Double-Fetch Bugs in OS Kernels
  • ExpRace: Exploiting Kernel Races through Raising Interrupts 引用了 Precise and Scalable Detection of Double-Fetch Bugs in OS Kernels
  • PeX: A Permission Check Analysis Framework for Linux Kernel 引用了 Precise and Scalable Detection of Double-Fetch Bugs in OS Kernels
  • Static Detection of Unsafe DMA Accesses in Device Drivers 引用了 PeriScope: An Effective Probing and Fuzzing Framework for the Hardware-OS Boundary
  • Static Detection of Unsafe DMA Accesses in Device Drivers 引用了 PeX: A Permission Check Analysis Framework for Linux Kernel
  • Static Detection of Unsafe DMA Accesses in Device Drivers 引用了 Precise and Scalable Detection of Double-Fetch Bugs in OS Kernels
它引用的引用它的从左到右按年份排列,引用越多,位置越高。

引用它的顶会 Paper20

  1. PeriScope: An Effective Probing and Fuzzing Framework for the Hardware-OS BoundaryDokyung Song, Felicitas Hetzelt, Dipanjan Das, Chad Spensky 等NDSS 2019 · 114 次引用
  2. Precise and Scalable Detection of Double-Fetch Bugs in OS KernelsMeng Xu, Chenxiong Qian, Kangjie Lu, Michael Backes 等S&P 2018 · 95 次引用
  3. PeX: A Permission Check Analysis Framework for Linux KernelTong Zhang, Wenbo Shen, Dongyoon Lee, Changhee Jung 等USENIX Security 2019 · 77 次引用
  4. ExpRace: Exploiting Kernel Races through Raising InterruptsYoochan Lee, Changwoo Min, Byoungyoung LeeUSENIX Security 2021 · 40 次引用
  5. Static Detection of Unsafe DMA Accesses in Device DriversJia-Ju Bai, Tuo Li, Kangjie Lu, Shi-Min HuUSENIX Security 2021 · 28 次引用

相关 Paper

  1. SafeFetch: Practical Double-Fetch Protection with Kernel-Fetch CachingVictor Duta, Mitchel Aloserij, Cristiano GiuffridaUSENIX Security 2024 · 2 次引用
  2. IsolatOS: Detecting Double Fetch Bugs in COTS RTOS by Re-enabling Kernel IsolationYingjie Cao, Xiaogang Zhu, Dean Sullivan, Haowei Yang 等NDSS 2026 · 1 次引用
  3. Midas: Systematic Kernel TOCTTOU ProtectionAtri Bhattacharyya, Uros Tesic, Mathias PayerUSENIX Security 2022
  4. Detecting API Post-Handling Bugs Using Code and Description in PatchesMiaoqian Lin, Kai Chen, Yang XiaoUSENIX Security 2023
  5. SemFuzz: Semantics-based Automatic Generation of Proof-of-Concept ExploitsWei You, Peiyuan Zong, Kai Chen, XiaoFeng Wang 等CCS 2017 · 148 次引用
黄昏的海面,两侧是细线勾勒的悬崖