ret2dir: Deconstructing Kernel Isolation
summary
ret2dir claims a practical bypass of KERNEXEC/UDEREF and hardware SMEP/SMAP/PXN by exploiting the kernel’s direct‑mapped physical memory region: it maps attacker‑controlled user pages into the kernel fmap alias, discovers their kernel synonyms via /proc/PID/pagemap, forces suitable PFNs by mass page‑faulting and zone depletion, and then overwrites kernel pointers to point at those synonyms to execute code or ROP (example: CVE‑2013‑2094 perf exploit converted). Works across x86/x86_64/AArch32/AArch64 Linux; mitigation proposed is exclusive page‑frame ownership. return-to-direct-mapped memory fmap spraying
AI-written summary · about
chapters (37)
- 0:00Introduction
- 0:17About me
- 0:44Agenda
- 2:42Kernel Vulnerabilities
- 3:23Linux
- 6:01Kernel Attack Model
- 9:17Why do they work
- 10:55Protections
- 13:50Summary
- 15:00Questions
- 16:04Return to Direct Map Memory
- 16:57Kernel Space Layout
- 19:06Role of Kernel Space Layout
- 20:47Properties of the Region
- 22:56Threat Model
- 24:10Addressaliasing
- 24:41Attack
- 25:41Location of synonym
- 26:16Problems
- 27:37How
- 30:32Second problem
- 31:08How Linux manages physical memory
- 32:13How Linux manages page frames
- 37:24What if page frames are not available
- 37:49Fishmap sprain
- 41:06Fishmap signatures
- 42:14Vulnerability overview
- 43:44Vulnerability data structure
- 44:15Static kee
- 44:34How to abuse it
- 49:23How it works
- 50:38What happens if this map is not executable
- 53:34How this works
- 54:41Demo
- 56:17Exploit DB
- 57:19Probability of success
- 58:25Pagegas
related talks
41mUsing Microarchitectural Design to Break KASLR and More
43mUsing Undocumented CPU Behavior to See Into Kernel Mode and Break KASLR in the Process
19mDisARMed: Attacking ARM TrustZone from Userspace with Memory Aliasing
34mGetting on the Same (Virtual Memory) Page: A Roundtable on Data-only Attack Mitigations
40mWinter is Coming Back
36mLost Control-Breaking Hardware-Assisted Kernel Control-Flow Integrity with Page-Oriented Programming
25mPIkit: A New Kernel-Independent Processor-Interconnect Rootkit
30mEvasive Maneuvers: Strategies to Overcome Runtime Detection Tools
