4 ms·
Yeesh. I didn’t know that Windows still uses the self-referential page table trick. This makes me very nervous, especially since they seem to keep it mapped in
by amluto 9y ago
Yeesh. I didn’t know that Windows still uses the self-referential page table trick. This makes me very nervous, especially since they seem to keep it mapped in the user page tables. This seems likely to poke a big hole in ASLR if nothing else. It’s a huge target for write-what-where exploits.
- staticassertion 9y ago> This seems likely to poke a big hole in ASLR if nothing else. It’s a huge target for write-what-where exploits. How? Is it mapped to a static location?
- monocasa 9y agoIt is in Windows 7.
- staticassertion 9y agoGood to know, thanks.
- deleted 9y ago[deleted]
- nikital 9y agoAccording to the article, the self-mapping PTE is randomized in the latest Windows 10.
- ryuuchin 9y agoThey changed it in Windows 10 (RS1 IIRC)[1]. [1] http://www.alex-ionescu.com/?p=323 http://www.alex-ionescu.com/?p=323
- caf 9y agoThe tl;dr is that they're still using the self-referential page table trick, however the PTE_BASE is now randomised at runtime with dynamic fixups.
- amluto 9y agoIf an attacker can’t find it by probing the smallish number of choices using one of many MMU layout fixes, I’d be quite surprised.
- caf 9y agoDoes this bug also imply they're not using SMAP, since otherwise any kernel access to the page tables should have tripped it?
- caf 9y agoReplying to myself, I guess not, because the kernel doesn't modify the user pagetables using the user pagetables' own self-referencing entry. Rather it has the kernel %cr3 loaded and modifies them using a mapping of the user pagetables in those kernel pagetables.
- caf 9y ago..which, on further reflection, raises the question: if those page tables aren't loaded when in kernel mode, why do they even need a self-referential entry at all?
- nialv7 9y agoWhat's wrong with using self-referential page table? I thought everyone uses that?