tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: new mremap(2): relax alignment restrictions?



On Wed, Jul 25, 2007 at 04:51:46PM -0400, der Mouse wrote:
> >>> I suppose there's a bit of a performance hit with zeroing out the
> >>> page every time, but it seems like a necessary thing to do.
> >> There are security implications if we're not doing so.
> 
> There may be.  If the only data available dates from a previous mmap of
> the same file, I'm not sure there's more here than a covert channel for
> passing data that is very hard to find - though that much is certainly
> noteworthy; whether it Needs Fixing is debatable, though I'm in favour
> of it.  (I'd actually *prefer* getting SEGV/BUS/etc for accesses to
> space after EOF, but that would be quite run-time expensive to do, and
> likely somewhat difficult besides.)

To make that efficient, we'd need flexible *segmentation* on top
of paging in the hardware - that is, a MMU length field per page
with byte granularity.

        -is


Home | Main Index | Thread Index | Old Index