Recursive page table mapping and permissions
Posted: Wed Jul 01, 2009 9:45 am
After realizing the benefits of doing a "recursive mapping" of page tables, I've been rewriting my kernel's memory manager. By recursive mapping, I mean putting the page directory as the last page table, thereby mapping all of the page tables from 0xFFC00000 through 0xFFFFE000 (and the page directory itself at 0xFFFFF000). My issue is that if I want to allow user processes to use memory mapped by a table, the user flag must be set on that table. But if the user flag is set on the table, the recursive mapping of that table is then user accessible - a *very* bad thing for security. I know others use this technique; how do you solve this problem?