lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20191121210909.15086-1-dxu@dxuuu.xyz>
Date:   Thu, 21 Nov 2019 13:09:09 -0800
From:   Daniel Xu <dxu@...uu.xyz>
To:     adobriyan@...il.com, christian@...uner.io,
        akpm@...ux-foundation.org, tglx@...utronix.de, mhocko@...e.com,
        keescook@...omium.org, shakeelb@...gle.com, casey@...aufler-ca.com,
        khlebnikov@...dex-team.ru, kent.overstreet@...il.com,
        linux-kernel@...r.kernel.org, linux-fsdevel@...r.kernel.org
Cc:     Daniel Xu <dxu@...uu.xyz>, dschatzberg@...com, htejun@...com,
        dennis@...nel.org, kernel-team@...com
Subject: [PATCH] proc: Make /proc/<pid>/io world readable

/proc/<pid>/io is currently only owner readable. This forces monitoring
programs (such as atop) to run with elevated permissions to collect disk
stats. Changing this file to world readable can add a measure of safety to
userspace.

Signed-off-by: Daniel Xu <dxu@...uu.xyz>
---
 fs/proc/base.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/proc/base.c b/fs/proc/base.c
index ebea9501afb8..1d1c1d680e16 100644
--- a/fs/proc/base.c
+++ b/fs/proc/base.c
@@ -3076,7 +3076,7 @@ static const struct pid_entry tgid_base_stuff[] = {
 	REG("coredump_filter", S_IRUGO|S_IWUSR, proc_coredump_filter_operations),
 #endif
 #ifdef CONFIG_TASK_IO_ACCOUNTING
-	ONE("io",	S_IRUSR, proc_tgid_io_accounting),
+	ONE("io",	S_IRUGO, proc_tgid_io_accounting),
 #endif
 #ifdef CONFIG_USER_NS
 	REG("uid_map",    S_IRUGO|S_IWUSR, proc_uid_map_operations),
@@ -3473,7 +3473,7 @@ static const struct pid_entry tid_base_stuff[] = {
 	REG("fail-nth", 0644, proc_fail_nth_operations),
 #endif
 #ifdef CONFIG_TASK_IO_ACCOUNTING
-	ONE("io",	S_IRUSR, proc_tid_io_accounting),
+	ONE("io",	S_IRUGO, proc_tid_io_accounting),
 #endif
 #ifdef CONFIG_USER_NS
 	REG("uid_map",    S_IRUGO|S_IWUSR, proc_uid_map_operations),
-- 
2.21.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ