youtube-viewers: refactor and add gtk-youtube-viewers-common

This commit is contained in:
pirate486743186 2023-04-16 00:06:28 +02:00
parent 0554f6d769
commit 99898db8fc
12 changed files with 46 additions and 29 deletions

View file

@ -6,7 +6,9 @@ include gtk-lbry-viewer.local
# added by included profile
#include globals.local
ignore quiet
private-bin gtk-lbry-viewer
include gtk-youtube-viewers-common.profile
# Redirect
include lbry-viewer.profile

View file

@ -6,7 +6,9 @@ include gtk-pipe-viewer.local
# added by included profile
#include globals.local
ignore quiet
private-bin gtk-pipe-viewer
include gtk-youtube-viewers-common.profile
# Redirect
include pipe-viewer.profile

View file

@ -6,7 +6,9 @@ include gtk-straw-viewer.local
# added by included profile
#include globals.local
ignore quiet
private-bin gtk-straw-viewer
include gtk-youtube-viewers-common.profile
# Redirect
include straw-viewer.profile

View file

@ -6,7 +6,9 @@ include gtk-youtube-viewer.local
# added by included profile
#include globals.local
ignore quiet
private-bin gtk-youtube-viewer
include gtk-youtube-viewers-common.profile
# Redirect
include youtube-viewer.profile

View file

@ -0,0 +1,22 @@
# Firejail profile for gtk-youtube-viewer clones
# Description: common profile for Trizen's gtk Youtube viewers
# This file is overwritten after every install/update
# Persistent local customizations
include gtk-youtube-viewers-common.local
# Persistent global definitions
# added by caller profile
#include globals.local
ignore quiet
# The lines below are needed to find the default Firefox profile name, to allow
# opening links in an existing instance of Firefox (note that it still fails if
# there isn't a Firefox instance running with the default profile; see #5352)
noblacklist ${HOME}/.mozilla
whitelist ${HOME}/.mozilla/firefox/profiles.ini
private-bin firefox,xterm
dbus-user filter
# allow D-Bus communication with firefox for opening links
dbus-user.talk org.mozilla.*

View file

@ -6,12 +6,9 @@ include gtk2-youtube-viewer.local
# added by included profile
#include globals.local
ignore quiet
private-bin gtk2-youtube-viewer
noblacklist /tmp/.X11-unix
noblacklist ${RUNUSER}
include whitelist-runuser-common.inc
include gtk-youtube-viewers-common.profile
# Redirect
include youtube-viewer.profile

View file

@ -6,12 +6,9 @@ include gtk3-youtube-viewer.local
# added by included profile
#include globals.local
ignore quiet
private-bin gtk3-youtube-viewer
noblacklist /tmp/.X11-unix
noblacklist ${RUNUSER}
include whitelist-runuser-common.inc
include gtk-youtube-viewers-common.profile
# Redirect
include youtube-viewer.profile

View file

@ -15,7 +15,7 @@ mkdir ${HOME}/.cache/lbry-viewer
whitelist ${HOME}/.cache/lbry-viewer
whitelist ${HOME}/.config/lbry-viewer
private-bin gtk-lbry-viewer,lbry-viewer
private-bin lbry-viewer
# Redirect
include youtube-viewers-common.profile

View file

@ -15,7 +15,7 @@ mkdir ${HOME}/.cache/pipe-viewer
whitelist ${HOME}/.cache/pipe-viewer
whitelist ${HOME}/.config/pipe-viewer
private-bin gtk-pipe-viewer,pipe-viewer
private-bin pipe-viewer
# Redirect
include youtube-viewers-common.profile

View file

@ -15,7 +15,7 @@ mkdir ${HOME}/.cache/straw-viewer
whitelist ${HOME}/.cache/straw-viewer
whitelist ${HOME}/.config/straw-viewer
private-bin gtk-straw-viewer,straw-viewer
private-bin straw-viewer
# Redirect
include youtube-viewers-common.profile

View file

@ -15,7 +15,7 @@ mkdir ${HOME}/.config/youtube-viewer
whitelist ${HOME}/.cache/youtube-viewer
whitelist ${HOME}/.config/youtube-viewer
private-bin gtk-youtube-viewer,gtk2-youtube-viewer,gtk3-youtube-viewer,youtube-viewer
private-bin youtube-viewer
# Redirect
include youtube-viewers-common.profile

View file

@ -8,6 +8,7 @@ include youtube-viewers-common.local
#include globals.local
noblacklist ${HOME}/.cache/youtube-dl
noblacklist ${HOME}/.config/mpv
# Allow lua (blacklisted by disable-interpreters.inc)
include allow-lua.inc
@ -19,12 +20,6 @@ include allow-perl.inc
include allow-python2.inc
include allow-python3.inc
# The lines below are needed to find the default Firefox profile name, to allow
# opening links in an existing instance of Firefox (note that it still fails if
# there isn't a Firefox instance running with the default profile; see #5352)
noblacklist ${HOME}/.mozilla
whitelist ${HOME}/.mozilla/firefox/profiles.ini
include disable-common.inc
include disable-devel.inc
include disable-exec.inc
@ -34,7 +29,9 @@ include disable-xdg.inc
whitelist ${DOWNLOADS}
whitelist ${HOME}/.cache/youtube-dl/youtube-sigfuncs
whitelist ${HOME}/.config/mpv
include whitelist-common.inc
include whitelist-run-common.inc
include whitelist-runuser-common.inc
include whitelist-usr-share-common.inc
include whitelist-var-common.inc
@ -55,16 +52,12 @@ seccomp
tracelog
disable-mnt
private-bin bash,ffmpeg,ffprobe,firefox,mpv,perl,python*,sh,smplayer,stty,wget,wget2,which,xterm,youtube-dl,yt-dlp
private-bin bash,ffmpeg,ffprobe,mpv,perl,python*,sh,smplayer,stty,wget,wget2,which,youtube-dl,yt-dlp
private-cache
private-dev
private-etc @tls-ca,@x11,host.conf,mime.types
private-tmp
dbus-user filter
# allow D-Bus communication with firefox for opening links
dbus-user.talk org.mozilla.*
dbus-system none
restrict-namespaces