3 ms·
If you work on crypto, or any application where sensitive data is handled, then this short post on the WIPEONFORK option may be interesting: http://www.metzdow
by colmmacc 9y ago
If you work on crypto, or any application where sensitive data is handled, then this short post on the WIPEONFORK option may be interesting:
http://www.metzdowd.com/pipermail/cryptography/2017-November/033133.html http://www.metzdowd.com/pipermail/cryptography/2017-November...
- throwaway613834 9y agoHow does this work with heap allocation? When you free memory and then allocate it again and get back the same address range, wouldn't the flag still apply to the new block?
- colmmacc 9y agomadvise() works at the page level and if you're using madvise(), then you're expected to be using mmap() to allocate pages explicitly. It would be unusual and a bad idea to start madvise()ing memory that's being handled by an allocator (like malloc). Of course you could also write a security focused heap allocator that uses these madvise() options under the hood.