3 ms·
Isn't intel's new memory protection keys feature intended to allow exactly this sort of thing?
by caf 11y ago
Isn't intel's new memory protection keys feature intended to allow exactly this sort of thing?
- amluto 11y agoNope. Intel's MPX is an opt-in thing to assist with pointer bounds checking.
- caf 11y agoI was thinking of MPK, not MPX. You'd set the library's code and data pages to protection key 1, along with the page containing a library access trampoline, leaving the rest of the address space with protection key 0. You'd call into the library through the trampoline, which would revoke access to protection key 0, call into the library, then restore access to key 0.