android_kernel_xiaomi_sm8350/security
Dan Rosenberg eaf06b241b Restrict unprivileged access to kernel syslog
The kernel syslog contains debugging information that is often useful
during exploitation of other vulnerabilities, such as kernel heap
addresses.  Rather than futilely attempt to sanitize hundreds (or
thousands) of printk statements and simultaneously cripple useful
debugging functionality, it is far simpler to create an option that
prevents unprivileged users from reading the syslog.

This patch, loosely based on grsecurity's GRKERNSEC_DMESG, creates the
dmesg_restrict sysctl.  When set to "0", the default, no restrictions are
enforced.  When set to "1", only users with CAP_SYS_ADMIN can read the
kernel syslog via dmesg(8) or other mechanisms.

[akpm@linux-foundation.org: explain the config option in kernel.txt]
Signed-off-by: Dan Rosenberg <drosenberg@vsecurity.com>
Acked-by: Ingo Molnar <mingo@elte.hu>
Acked-by: Eugene Teo <eugeneteo@kernel.org>
Acked-by: Kees Cook <kees.cook@canonical.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2010-11-12 07:55:32 -08:00
..
apparmor fs: take dcache_lock inside __d_path 2010-10-25 21:26:12 -04:00
integrity/ima IMA: fix the ToMToU logic 2010-10-26 11:37:19 -07:00
keys Fix install_process_keyring error handling 2010-10-28 09:02:15 -07:00
selinux convert get_sb_single() users 2010-10-29 04:16:28 -04:00
smack convert get_sb_single() users 2010-10-29 04:16:28 -04:00
tomoyo fs: take dcache_lock inside __d_path 2010-10-25 21:26:12 -04:00
capability.c secmark: make secmark object handling generic 2010-10-21 10:12:48 +11:00
commoncap.c Restrict unprivileged access to kernel syslog 2010-11-12 07:55:32 -08:00
device_cgroup.c
inode.c convert get_sb_single() users 2010-10-29 04:16:28 -04:00
Kconfig Restrict unprivileged access to kernel syslog 2010-11-12 07:55:32 -08:00
lsm_audit.c
Makefile
min_addr.c
security.c Merge branch 'ima-memory-use-fixes' 2010-10-26 11:37:48 -07:00