3 ms·
I was on board until `PROT_READ | PROT_WRITE | PROT_EXEC`
by snek 8y ago
I was on board until `PROT_READ | PROT_WRITE | PROT_EXEC`
- orclev 8y agoI mean, how else are you going to write self-modifying code? It's kind of implicit in the name of the thing that it's going to need to at a minimum have write and exec permission, and read is kind of important to make sure you're actually modifying the right stuff. Yes it's a terrible idea to have write and execute permissions on the same piece of memory, but that's part of why literally the very first line of the article says it's a terrible idea to write self-mutating code.