aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLibravatar glitsj16 <glitsj16@users.noreply.github.com>2023-07-25 19:36:31 +0000
committerLibravatar GitHub <noreply@github.com>2023-07-25 19:36:31 +0000
commita95a742727b09dd773fff08e1bdc9b9415dc0c27 (patch)
tree7772342cfab5ca067f84a634fed4a1e8ffc22a7c
parentprofiles: Miscellaneous cleanups (#5918) (diff)
downloadfirejail-a95a742727b09dd773fff08e1bdc9b9415dc0c27.tar.gz
firejail-a95a742727b09dd773fff08e1bdc9b9415dc0c27.tar.zst
firejail-a95a742727b09dd773fff08e1bdc9b9415dc0c27.zip
profiles: fixes and cleanups for opening links with firefox (#5919)
-rw-r--r--etc/profile-a-l/kube.profile19
-rw-r--r--etc/profile-m-z/signal-desktop.profile8
-rw-r--r--etc/profile-m-z/trojita.profile11
3 files changed, 24 insertions, 14 deletions
diff --git a/etc/profile-a-l/kube.profile b/etc/profile-a-l/kube.profile
index 5cf30ed40..82336969d 100644
--- a/etc/profile-a-l/kube.profile
+++ b/etc/profile-a-l/kube.profile
@@ -6,11 +6,10 @@ include kube.local
6# Persistent global definitions 6# Persistent global definitions
7include globals.local 7include globals.local
8 8
9noblacklist ${HOME}/.gnupg
10noblacklist ${HOME}/.mozilla
11noblacklist ${HOME}/.cache/kube 9noblacklist ${HOME}/.cache/kube
12noblacklist ${HOME}/.config/kube 10noblacklist ${HOME}/.config/kube
13noblacklist ${HOME}/.config/sink 11noblacklist ${HOME}/.config/sink
12noblacklist ${HOME}/.gnupg
14noblacklist ${HOME}/.local/share/kube 13noblacklist ${HOME}/.local/share/kube
15noblacklist ${HOME}/.local/share/sink 14noblacklist ${HOME}/.local/share/sink
16 15
@@ -22,23 +21,28 @@ include disable-programs.inc
22include disable-shell.inc 21include disable-shell.inc
23include disable-xdg.inc 22include disable-xdg.inc
24 23
25mkdir ${HOME}/.gnupg 24# The lines below are needed to find the default Firefox profile name, to allow
25# opening links in an existing instance of Firefox (note that it still fails if
26# there isn't a Firefox instance running with the default profile; see #5352)
27noblacklist ${HOME}/.mozilla
28whitelist ${HOME}/.mozilla/firefox/profiles.ini
29
26mkdir ${HOME}/.cache/kube 30mkdir ${HOME}/.cache/kube
27mkdir ${HOME}/.config/kube 31mkdir ${HOME}/.config/kube
28mkdir ${HOME}/.config/sink 32mkdir ${HOME}/.config/sink
33mkdir ${HOME}/.gnupg
29mkdir ${HOME}/.local/share/kube 34mkdir ${HOME}/.local/share/kube
30mkdir ${HOME}/.local/share/sink 35mkdir ${HOME}/.local/share/sink
31whitelist ${HOME}/.gnupg
32whitelist ${HOME}/.mozilla/firefox/profiles.ini
33whitelist ${HOME}/.cache/kube 36whitelist ${HOME}/.cache/kube
34whitelist ${HOME}/.config/kube 37whitelist ${HOME}/.config/kube
35whitelist ${HOME}/.config/sink 38whitelist ${HOME}/.config/sink
39whitelist ${HOME}/.gnupg
36whitelist ${HOME}/.local/share/kube 40whitelist ${HOME}/.local/share/kube
37whitelist ${HOME}/.local/share/sink 41whitelist ${HOME}/.local/share/sink
38whitelist ${RUNUSER}/gnupg 42whitelist ${RUNUSER}/gnupg
39whitelist /usr/share/kube
40whitelist /usr/share/gnupg 43whitelist /usr/share/gnupg
41whitelist /usr/share/gnupg2 44whitelist /usr/share/gnupg2
45whitelist /usr/share/kube
42include whitelist-common.inc 46include whitelist-common.inc
43include whitelist-runuser-common.inc 47include whitelist-runuser-common.inc
44include whitelist-usr-share-common.inc 48include whitelist-usr-share-common.inc
@@ -63,7 +67,6 @@ tracelog
63 67
64# disable-mnt 68# disable-mnt
65# Add "gpg,gpg2,gpg-agent,pinentry-curses,pinentry-emacs,pinentry-fltk,pinentry-gnome3,pinentry-gtk,pinentry-gtk2,pinentry-gtk-2,pinentry-qt,pinentry-qt4,pinentry-tty,pinentry-x2go,pinentry-kwallet" for gpg 69# Add "gpg,gpg2,gpg-agent,pinentry-curses,pinentry-emacs,pinentry-fltk,pinentry-gnome3,pinentry-gtk,pinentry-gtk2,pinentry-gtk-2,pinentry-qt,pinentry-qt4,pinentry-tty,pinentry-x2go,pinentry-kwallet" for gpg
66# Add "ignore private-bin" for hyperlinks or have a look at the private-bins in firefox.profile and firefox-common.profile.
67private-bin kube,sink_synchronizer 70private-bin kube,sink_synchronizer
68private-cache 71private-cache
69private-dev 72private-dev
@@ -75,6 +78,8 @@ dbus-user filter
75dbus-user.talk ca.desrt.dconf 78dbus-user.talk ca.desrt.dconf
76dbus-user.talk org.freedesktop.secrets 79dbus-user.talk org.freedesktop.secrets
77dbus-user.talk org.freedesktop.Notifications 80dbus-user.talk org.freedesktop.Notifications
81# allow D-Bus communication with firefox for opening links
82dbus-user.talk org.mozilla.*
78dbus-system none 83dbus-system none
79 84
80restrict-namespaces 85restrict-namespaces
diff --git a/etc/profile-m-z/signal-desktop.profile b/etc/profile-m-z/signal-desktop.profile
index 3e1899ef3..8cb4e4173 100644
--- a/etc/profile-m-z/signal-desktop.profile
+++ b/etc/profile-m-z/signal-desktop.profile
@@ -11,7 +11,9 @@ ignore noexec /tmp
11 11
12noblacklist ${HOME}/.config/Signal 12noblacklist ${HOME}/.config/Signal
13 13
14# These lines are needed to allow Firefox to open links 14# The lines below are needed to find the default Firefox profile name, to allow
15# opening links in an existing instance of Firefox (note that it still fails if
16# there isn't a Firefox instance running with the default profile; see #5352)
15noblacklist ${HOME}/.mozilla 17noblacklist ${HOME}/.mozilla
16whitelist ${HOME}/.mozilla/firefox/profiles.ini 18whitelist ${HOME}/.mozilla/firefox/profiles.ini
17 19
@@ -21,11 +23,9 @@ whitelist ${HOME}/.config/Signal
21private-etc @tls-ca 23private-etc @tls-ca
22 24
23dbus-user filter 25dbus-user filter
24
25# allow D-Bus notifications 26# allow D-Bus notifications
26dbus-user.talk org.freedesktop.Notifications 27dbus-user.talk org.freedesktop.Notifications
27 28# allow D-Bus communication with firefox for opening links
28# allow D-Bus communication with Firefox browsers for opening links
29dbus-user.talk org.mozilla.* 29dbus-user.talk org.mozilla.*
30 30
31ignore dbus-user none 31ignore dbus-user none
diff --git a/etc/profile-m-z/trojita.profile b/etc/profile-m-z/trojita.profile
index ba68ccb53..2578eb0be 100644
--- a/etc/profile-m-z/trojita.profile
+++ b/etc/profile-m-z/trojita.profile
@@ -7,7 +7,6 @@ include trojita.local
7include globals.local 7include globals.local
8 8
9noblacklist ${HOME}/.abook 9noblacklist ${HOME}/.abook
10noblacklist ${HOME}/.mozilla
11noblacklist ${HOME}/.cache/flaska.net/trojita 10noblacklist ${HOME}/.cache/flaska.net/trojita
12noblacklist ${HOME}/.config/flaska.net 11noblacklist ${HOME}/.config/flaska.net
13 12
@@ -19,11 +18,16 @@ include disable-programs.inc
19include disable-shell.inc 18include disable-shell.inc
20include disable-xdg.inc 19include disable-xdg.inc
21 20
21# The lines below are needed to find the default Firefox profile name, to allow
22# opening links in an existing instance of Firefox (note that it still fails if
23# there isn't a Firefox instance running with the default profile; see #5352)
24noblacklist ${HOME}/.mozilla
25whitelist ${HOME}/.mozilla/firefox/profiles.ini
26
22mkdir ${HOME}/.abook 27mkdir ${HOME}/.abook
23mkdir ${HOME}/.cache/flaska.net/trojita 28mkdir ${HOME}/.cache/flaska.net/trojita
24mkdir ${HOME}/.config/flaska.net 29mkdir ${HOME}/.config/flaska.net
25whitelist ${HOME}/.abook 30whitelist ${HOME}/.abook
26whitelist ${HOME}/.mozilla/firefox/profiles.ini
27whitelist ${HOME}/.cache/flaska.net/trojita 31whitelist ${HOME}/.cache/flaska.net/trojita
28whitelist ${HOME}/.config/flaska.net 32whitelist ${HOME}/.config/flaska.net
29include whitelist-common.inc 33include whitelist-common.inc
@@ -49,7 +53,6 @@ seccomp
49tracelog 53tracelog
50 54
51# disable-mnt 55# disable-mnt
52# Add "ignore private-bin" for hyperlinks or have a look at the private-bins in firefox.profile and firefox-common.profile.
53private-bin trojita 56private-bin trojita
54private-cache 57private-cache
55private-dev 58private-dev
@@ -58,6 +61,8 @@ private-tmp
58 61
59dbus-user filter 62dbus-user filter
60dbus-user.talk org.freedesktop.secrets 63dbus-user.talk org.freedesktop.secrets
64# allow D-Bus communication with firefox for opening links
65dbus-user.talk org.mozilla.*
61dbus-system none 66dbus-system none
62 67
63restrict-namespaces 68restrict-namespaces