From: Dave R. <ld...@dr...> - 2005-08-05 02:51:49
|
On Thu, 2005-08-04 at 16:41 +0300, Juho Snellman wrote: > On Wed, Aug 03, 2005 at 09:07:19PM -0700, Dave Roberts wrote: > > That might work. Basically just request an address through mmap, but > > don't use the MAP_FIXED flag. Although in a randomized memory system > > you'll almost always get something different than what you requested. > > The mmap randomization doesn't actually work by assigning the address > at random, but by selecting the highest memory range below a certain > base value for the mmap. It's this base value which is randomized by a > modest amount. So if you're requesting memory that's not close to the > mmap base, you're likely to get it. It's unlikely that even the > lunatic fringe would actually do completely random mmaps. And this > isn't really a problem for SBCL; it runs just fine on the latest > vanilla kernels that do this randomization. > > (The Fedora kernel has patches that do additional randomization which > causes problems for SBCL, but they're similar in spirit. The initial > allocation of some spaces is offset a bit). Okay, gotcha. So it isn't as bad as completely randomizing every call to mmap. That's better than I thought. -- Dave Roberts <ld...@dr...> |