mirror of
https://github.com/torvalds/linux.git
synced 2024-12-14 15:13:52 +00:00
b64913394f
WRITE_KERN is supposed to overwrite some kernel text, namely do_overwritten() function. But at the time being it overwrites do_overwritten() function descriptor, not function text. Fix it by dereferencing the function descriptor to obtain function text pointer. Export dereference_function_descriptor() for when LKDTM is built as a module. And make do_overwritten() noinline so that it is really do_overwritten() which is called by lkdtm_WRITE_KERN(). Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu> Acked-by: Kees Cook <keescook@chromium.org> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://lore.kernel.org/r/31e58eaffb5bc51c07d8d4891d1982100ade8cfc.1644928018.git.christophe.leroy@csgroup.eu |
||
---|---|---|
.. | ||
bugs.c | ||
cfi.c | ||
core.c | ||
fortify.c | ||
heap.c | ||
lkdtm.h | ||
Makefile | ||
perms.c | ||
powerpc.c | ||
refcount.c | ||
rodata.c | ||
stackleak.c | ||
usercopy.c |