summaryrefslogtreecommitdiffstats
path: root/runtime/staprun/cap.c
diff options
context:
space:
mode:
authorhunt <hunt>2007-10-12 19:42:32 +0000
committerhunt <hunt>2007-10-12 19:42:32 +0000
commit2972246a08bfc7c516455ecc4ef976e10c0ddb2c (patch)
tree030cb7ae2694103f6c9abb64e5419a0df11368eb /runtime/staprun/cap.c
parent7651c16b0e3d7dba7265be5e83720e324bdf64b0 (diff)
downloadsystemtap-steved-2972246a08bfc7c516455ecc4ef976e10c0ddb2c.tar.gz
systemtap-steved-2972246a08bfc7c516455ecc4ef976e10c0ddb2c.tar.xz
systemtap-steved-2972246a08bfc7c516455ecc4ef976e10c0ddb2c.zip
2007-10-12 Martin Hunt <hunt@redhat.com>
Changes to separate the symbols from the command channel. * cap.c (init_cap): Add CAP_DAC_OVERRIDE. * staprun.h: Change init_ctl_channel prototype. * ctl.c (init_ctl_channel): Modify to open either a command or symbol channel. Use ".cmd" and ".symbols" as the new names. * mainloop.c (init_stapio): Call init_ctl_channel(0); * staprun.c (cleanup): Call stop_symbol_thread(). (main): Call start_symbol_thread(). * staprun_funcs.c (handle_symbols): Make a thread. (start_symbol_thread): New. (stop_symbol_thread): New.
Diffstat (limited to 'runtime/staprun/cap.c')
-rw-r--r--runtime/staprun/cap.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/runtime/staprun/cap.c b/runtime/staprun/cap.c
index df4a7130..6f22dfc9 100644
--- a/runtime/staprun/cap.c
+++ b/runtime/staprun/cap.c
@@ -28,7 +28,7 @@
_perr(msg); \
exit(1); \
} \
-
+
/*
* init_cap() sets up the initial capabilities for staprun. Then
* it calls prctl( PR_SET_KEEPCAPS) to arrrange to keep these capabilities
@@ -57,7 +57,7 @@
int init_cap(void)
{
cap_t caps = cap_init();
- cap_value_t capv[] = {CAP_SYS_MODULE, CAP_SYS_ADMIN, CAP_SYS_NICE, CAP_SETUID, CAP_SETGID};
+ cap_value_t capv[] = {CAP_SYS_MODULE, CAP_SYS_ADMIN, CAP_SYS_NICE, CAP_SETUID, CAP_SETGID, CAP_DAC_OVERRIDE};
const int numcaps = sizeof(capv) / sizeof(capv[0]);
uid_t uid = getuid();
gid_t gid = getgid();