Skip to content

Instantly share code, notes, and snippets.

@arainho
Last active December 27, 2023 12:22
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save arainho/1f2e2312631c61c32ce0f7173868fff7 to your computer and use it in GitHub Desktop.
Save arainho/1f2e2312631c61c32ce0f7173868fff7 to your computer and use it in GitHub Desktop.
ArchLinux - Hardening
# https://wiki.archlinux.org/index.php/Firejail
# https://linux-audit.com/audit-and-harden-your-ssh-configuration/
sudo firecfg
mkdir -p /etc/pacman.d/hooks/
sudo bash -c 'cat > /etc/pacman.d/hooks/firejail.hook' << EOF
[Trigger]
Type = Path
Operation = Install
Operation = Upgrade
Operation = Remove
Target = usr/bin/*
Target = usr/local/bin/*
Target = usr/share/applications/*.desktop
[Action]
Description = Configure symlinks in /usr/local/bin based on firecfg.config...
When = PostTransaction
Depends = firejail
Exec = /bin/sh -c 'firecfg &>/dev/null'
EOF
# X11
#https://wiki.archlinux.org/index.php/Xephyr
#https://wiki.archlinux.org/index.php/Firejail
#https://firejail.wordpress.com/documentation-2/basic-usage/#x11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment