diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/firejail/profile.c | 11 | ||||
-rw-r--r-- | src/man/firejail-login.txt | 2 | ||||
-rw-r--r-- | src/man/firejail-profile.txt | 24 | ||||
-rw-r--r-- | src/man/firejail.txt | 2 | ||||
-rw-r--r-- | src/man/firemon.txt | 2 |
5 files changed, 32 insertions, 9 deletions
diff --git a/src/firejail/profile.c b/src/firejail/profile.c index 343907584..877428637 100644 --- a/src/firejail/profile.c +++ b/src/firejail/profile.c | |||
@@ -415,9 +415,18 @@ void profile_read(const char *fname, const char *skip1, const char *skip2) { | |||
415 | p++; | 415 | p++; |
416 | } | 416 | } |
417 | 417 | ||
418 | // expand ${HOME}/ in front of the new profile file | ||
419 | char *newprofile2 = NULL; | ||
420 | if (strncmp(newprofile, "${HOME}", 7) == 0) { | ||
421 | if (asprintf(&newprofile2, "%s%s", cfg.homedir, newprofile + 7) == -1) | ||
422 | errExit("asprintf"); | ||
423 | } | ||
424 | |||
418 | // recursivity | 425 | // recursivity |
419 | profile_read(newprofile, newskip1, newskip2); | 426 | profile_read((newprofile2)? newprofile2:newprofile, newskip1, newskip2); |
420 | include_level--; | 427 | include_level--; |
428 | if (newprofile2) | ||
429 | free(newprofile2); | ||
421 | free(ptr); | 430 | free(ptr); |
422 | continue; | 431 | continue; |
423 | } | 432 | } |
diff --git a/src/man/firejail-login.txt b/src/man/firejail-login.txt index 6613dc044..768896872 100644 --- a/src/man/firejail-login.txt +++ b/src/man/firejail-login.txt | |||
@@ -1,4 +1,4 @@ | |||
1 | .TH man 5 "MONTH YEAR" "VERSION" "firejail login.users man page" | 1 | .TH FIREJAIL-LOGIN 5 "MONTH YEAR" "VERSION" "firejail login.users man page" |
2 | .SH NAME | 2 | .SH NAME |
3 | login.users \- Login file syntax for Firejail | 3 | login.users \- Login file syntax for Firejail |
4 | 4 | ||
diff --git a/src/man/firejail-profile.txt b/src/man/firejail-profile.txt index 46da19ecd..f85e10171 100644 --- a/src/man/firejail-profile.txt +++ b/src/man/firejail-profile.txt | |||
@@ -1,4 +1,4 @@ | |||
1 | .TH man 5 "MONTH YEAR" "VERSION" "firejail profiles man page" | 1 | .TH FIREJAIL-PROFILE 5 "MONTH YEAR" "VERSION" "firejail profiles man page" |
2 | .SH NAME | 2 | .SH NAME |
3 | profile \- Profile file syntax for Firejail | 3 | profile \- Profile file syntax for Firejail |
4 | 4 | ||
@@ -15,8 +15,19 @@ directory and ~/.config/firejail directory. | |||
15 | Include and comment support: | 15 | Include and comment support: |
16 | 16 | ||
17 | .TP | 17 | .TP |
18 | \f\include other.profile | 18 | \f\include other.profile exclude-token |
19 | Include other.profile file. | 19 | Include other.profile file. exclued-token disables blacklist commands in other.profile |
20 | if exclude-token word is found in the name section of blacklist command. | ||
21 | exclude-tyoken is optional. | ||
22 | |||
23 | Example: "include /etc/firejail/disable-common.inc .filezilla" | ||
24 | loads disable-common.inc file disables "blacklist ${HOME}/.filezilla" command in this file. | ||
25 | |||
26 | other.profile file name can be prefixed with ${HOME}. This will force Firejail to look for the | ||
27 | file in user home directory. | ||
28 | |||
29 | Example: "include ${HOME}/myprofiles/profile1" will load "~/myprofiles/profile1" file. | ||
30 | |||
20 | .TP | 31 | .TP |
21 | # this is a comment | 32 | # this is a comment |
22 | 33 | ||
@@ -81,14 +92,17 @@ Enable default Linux capabilities filter. | |||
81 | caps.drop all | 92 | caps.drop all |
82 | Blacklist all Linux capabilities. | 93 | Blacklist all Linux capabilities. |
83 | .TP | 94 | .TP |
84 | caps.drop capability,capability,capability | 95 | caps.keep capability,capability,capability |
85 | Blacklist Linux capabilities filter. | 96 | Blacklist Linux capabilities filter. |
86 | .TP | 97 | .TP |
87 | caps.drop capability,capability,capability | 98 | caps.drop capability,capability,capability |
88 | Whitelist Linux capabilities filter. | 99 | Whitelist Linux capabilities filter. |
89 | .TP | 100 | .TP |
90 | \f\seccomp | 101 | \f\seccomp |
91 | Enable default seccomp filter. | 102 | Enable default seccomp filter. The default list is as follows: |
103 | mount, umount2, ptrace, kexec_load, open_by_handle_at, init_module, finit_module, delete_module, | ||
104 | iopl, ioperm, swapon, swapoff, mknode, syslog, process_vm_readv and process_vm_writev, | ||
105 | sysfs,_sysctl, adjtimex, clock_adjtime, lookup_dcookie, perf_event_open, fanotify_init and kcmp. | ||
92 | .TP | 106 | .TP |
93 | \f\seccomp syscall,syscall,syscall | 107 | \f\seccomp syscall,syscall,syscall |
94 | Enable seccomp filter and blacklist the system calls in the list on top of default seccomp filter. | 108 | Enable seccomp filter and blacklist the system calls in the list on top of default seccomp filter. |
diff --git a/src/man/firejail.txt b/src/man/firejail.txt index 51f21975e..4e8d96d31 100644 --- a/src/man/firejail.txt +++ b/src/man/firejail.txt | |||
@@ -1,4 +1,4 @@ | |||
1 | .TH man 1 "MONTH YEAR" "VERSION" "firejail man page" | 1 | .TH FIREJAIL 1 "MONTH YEAR" "VERSION" "firejail man page" |
2 | .SH NAME | 2 | .SH NAME |
3 | Firejail \- Linux namespaces sandbox program | 3 | Firejail \- Linux namespaces sandbox program |
4 | .SH SYNOPSIS | 4 | .SH SYNOPSIS |
diff --git a/src/man/firemon.txt b/src/man/firemon.txt index b6010f46e..293547a3b 100644 --- a/src/man/firemon.txt +++ b/src/man/firemon.txt | |||
@@ -1,4 +1,4 @@ | |||
1 | .TH man 1 "MONTH YEAR" "VERSION" "firemon man page" | 1 | .TH FIREMON 1 "MONTH YEAR" "VERSION" "firemon man page" |
2 | .SH NAME | 2 | .SH NAME |
3 | Firemon \- Monitoring program for processes started in a Firejail sandbox. | 3 | Firemon \- Monitoring program for processes started in a Firejail sandbox. |
4 | .SH SYNOPSIS | 4 | .SH SYNOPSIS |