Messages in this thread | | | Date | Sat, 01 May 1999 03:50:27 -0700 | From | "H. Peter Anvin" <> | Subject | Re: 64bit port |
| |
David Miller wrote: > > From: hpa@transmeta.com (H. Peter Anvin) > Date: 1 May 1999 10:29:25 GMT > > No good... it's trivial for the malicious user to bypass the > simple-minded check. The general problem is uncomputable. > > If you mark read-only pages as clean after you scan them, and do > checks on ITLB misses for pages which have been written to, plus add a > special hook in the kernel for the dynamic linker to write instruction > relocations efficiently in the face of this, I believe it can be done > without too much of a performance hit for dynamic linking. >
Actually; I believe if you use the state-flipping trick I mentioned previously, you will have no performance issues, since the dynamic linker will run with the pages in the writable state. Only when execution starts will the code pages flip into the execute state.
The downside, of course, is that you don't get the error until at runtime, but that's the normal behaviour for illegal instructions anyway (SIGILL).
-hpa
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |