diff options
Diffstat (limited to 'src/firejail/run_symlink.c')
-rw-r--r-- | src/firejail/run_symlink.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/firejail/run_symlink.c b/src/firejail/run_symlink.c index d57816e12..cc6f6b3e9 100644 --- a/src/firejail/run_symlink.c +++ b/src/firejail/run_symlink.c | |||
@@ -91,6 +91,12 @@ void run_symlink(int argc, char **argv) { | |||
91 | 91 | ||
92 | printf("Redirecting symlink to %s\n", program); | 92 | printf("Redirecting symlink to %s\n", program); |
93 | 93 | ||
94 | // drop privileges | ||
95 | if (setgid(getgid()) < 0) | ||
96 | errExit("setgid/getgid"); | ||
97 | if (setuid(getuid()) < 0) | ||
98 | errExit("setuid/getuid"); | ||
99 | |||
94 | // run command | 100 | // run command |
95 | char *a[3 + argc]; | 101 | char *a[3 + argc]; |
96 | a[0] = firejail; | 102 | a[0] = firejail; |