aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/util/build-id.c
diff options
context:
space:
mode:
authorMasami Hiramatsu <mhiramat@kernel.org>2016-05-29 00:15:13 +0900
committerArnaldo Carvalho de Melo <acme@redhat.com>2016-05-30 13:15:01 -0300
commit11870d714a1b744a0225e90b0b395346357defe9 (patch)
treeb0cabbde5a55ad879ec9505710bef357a385239c /tools/perf/util/build-id.c
parentperf tools: Add arch/*/include/generated/ to .gitignore (diff)
downloadlinux-dev-11870d714a1b744a0225e90b0b395346357defe9.tar.xz
linux-dev-11870d714a1b744a0225e90b0b395346357defe9.zip
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/util/build-id.c')
0 files changed, 0 insertions, 0 deletions