aboutsummaryrefslogtreecommitdiffstats
path: root/security/selinux/hooks.c
diff options
context:
space:
mode:
authorSudip Mukherjee <[email protected]>2020-04-21 01:14:20 +0000
committerLinus Torvalds <[email protected]>2020-04-21 18:11:56 +0000
commitdb973a7289dad24e6c017dcedc6aee886579dc3a (patch)
treeabfece7553c0628651f012cf1ea46889c272c900 /security/selinux/hooks.c
parentmm: shmem: disable interrupt when acquiring info->lock in userfaultfd_copy path (diff)
downloadkernel-db973a7289dad24e6c017dcedc6aee886579dc3a.tar.gz
kernel-db973a7289dad24e6c017dcedc6aee886579dc3a.zip
coredump: fix null pointer dereference on coredump
If the core_pattern is set to "|" and any process segfaults then we get a null pointer derefernce while trying to coredump. The call stack shows: RIP: do_coredump+0x628/0x11c0 When the core_pattern has only "|" there is no use of trying the coredump and we can check that while formating the corename and exit with an error. After this change I get: format_corename failed Aborting core Fixes: 315c69261dd3 ("coredump: split pipe command whitespace before expanding template") Reported-by: Matthew Ruffell <[email protected]> Signed-off-by: Sudip Mukherjee <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Cc: Paul Wise <[email protected]> Cc: Alexander Viro <[email protected]> Cc: Neil Horman <[email protected]> Cc: <[email protected]> Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'security/selinux/hooks.c')
0 files changed, 0 insertions, 0 deletions