crypto: Kernel memory overwrite attempt detected to spans multiple pages
Kees Cook
keescook at chromium.org
Wed Apr 10 23:27:28 UTC 2019
On Wed, Apr 10, 2019 at 4:12 PM Eric Biggers <ebiggers at kernel.org> wrote:
> You've explained *what* it does again, but not *why*. *Why* do you want
> hardened usercopy to detect copies across page boundaries, when there is no
> actual buffer overflow?
But that *is* how it determines it was a buffer overflow: "if you
cross page boundaries (of a non-compound allocation), it *is* a buffer
overflow". This assertion, however, is flawed because many contiguous
allocations are not marked as being grouped together when it reality
they were. It was an attempt to get allocation size information out of
the page allocator, similar to how slab can be queries about
allocation size. I'm open to improvements here, since it's obviously
broken in its current state. :)
--
Kees Cook
More information about the Linux-security-module-archive
mailing list