Commit 91fcd412 authored by Bastian Blank's avatar Bastian Blank Committed by Linus Torvalds

Allow reading tainted flag as user

The commit 34f5a398 restricted reading
of the tainted value. The attached patch changes this back to a
write-only check and restores the read behaviour of older versions.
Signed-off-by: default avatarBastian Blank <bastian@waldi.eu.org>
Cc: Theodore Ts'o <tytso@mit.edu>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 94e22e13
...@@ -1676,7 +1676,7 @@ static int proc_dointvec_taint(ctl_table *table, int write, struct file *filp, ...@@ -1676,7 +1676,7 @@ static int proc_dointvec_taint(ctl_table *table, int write, struct file *filp,
{ {
int op; int op;
if (!capable(CAP_SYS_ADMIN)) if (write && !capable(CAP_SYS_ADMIN))
return -EPERM; return -EPERM;
op = OP_OR; op = OP_OR;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment