firejail/etc/profile-a-l/default.profile
Kelvin M. Klann 4d34d4c336 modif: block TPM devices & turn notpm command into keep-dev-tpm
Instead of having a `notpm` command and potentially adding it to almost
all profiles (as few programs should need direct access to TPM devices),
add a `keep-dev-tpm` command and use it only in profiles that need
access to TPM devices.

Changes:

* Turn `notpm` command into `keep-dev-tpm` command
* Warn and ignore if `notpm` is used
* Block `/dev/tpm*` devices by default
* Allow `/dev/tpm*` devices with `keep-dev-tpm` (even if `private-dev`
  is used)

Added on commit 001320226 ("feature: add notpm command & keep tpm
devices in private-dev (#6390)", 2024-07-09).

See also commit ee1c264c5 ("feature: block /dev/ntsync & add
keep-dev-ntsync command (#6660)", 2025-03-06) and the discussion at
PR #6660.

This is a follow-up to #6687.
2025-04-05 15:52:30 -03:00

64 lines
1.2 KiB
Text

# Firejail profile for default
# This file is overwritten after every install/update
# Persistent local customizations
include default.local
# Persistent global definitions
include globals.local
# generic GUI profile
# depending on your usage, you can enable some of the commands below:
include disable-common.inc
#include disable-devel.inc
#include disable-exec.inc
#include disable-interpreters.inc
include disable-programs.inc
#include disable-shell.inc
#include disable-write-mnt.inc
#include disable-xdg.inc
#include whitelist-common.inc
#include whitelist-runuser-common.inc
#include whitelist-usr-share-common.inc
#include whitelist-var-common.inc
include landlock-common.inc
#apparmor
caps.drop all
#ipc-namespace
#machine-id
#net none
netfilter
#no3d
#nodvd
#nogroups
noinput
nonewprivs
noroot
#nosound
notv
#nou2f
novideo
protocol unix,inet,inet6
seccomp
#tracelog
#disable-mnt
#private
#private-bin program
#private-cache
private-dev
# see /usr/share/doc/firejail/profile.template for more common private-etc paths.
#private-etc alternatives,fonts,machine-id
#private-lib
#private-opt none
private-tmp
#dbus-user none
#dbus-system none
#deterministic-shutdown
#memory-deny-write-execute
#read-only ${HOME}
restrict-namespaces