diff options
author | Masami Hiramatsu <mhiramat@kernel.org> | 2016-05-28 18:15:13 +0300 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2016-05-30 19:15:01 +0300 |
commit | 11870d714a1b744a0225e90b0b395346357defe9 (patch) | |
tree | b0cabbde5a55ad879ec9505710bef357a385239c /tools/perf/scripts/python/export-to-postgresql.py | |
parent | dcd1e2a7ba63710843d559f1570628321e62223e (diff) | |
download | linux-11870d714a1b744a0225e90b0b395346357defe9.tar.xz |
perf symbols: Introduce filename__readable to check readability
Introduce filename__readable to check readability by opening the file
directly. Since the access(R_OK) just checks the readability based on
real UID/GID, it is ignored that the effective UID/GID and capabilities
for some special file (e.g. /proc/kcore).
filename__readable() directly opens given file with O_RDONLY so that the
kernel checks it by effective UID/GID and capabilities.
Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org>
Acked-by: Namhyung Kim <namhyung@kernel.org>
Cc: Ananth N Mavinakayanahalli <ananth@linux.vnet.ibm.com>
Cc: Brendan Gregg <brendan.d.gregg@gmail.com>
Cc: Hemant Kumar <hemant@linux.vnet.ibm.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/r/20160528151513.16098.97576.stgit@devbox
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions