[GH-ISSUE #6152] Read profiles from /usr, in addition to /etc and ~/.config #3206

Closed
opened 2026-05-05 09:49:20 -06:00 by gitea-mirror · 2 comments
Owner

Originally created by @gioele on GitHub (Jan 7, 2024).
Original GitHub issue: https://github.com/netblue30/firejail/issues/6152

Problem description

Firejail profiles are currently stored in /etc/firejail/ (or /usr/local/etc/firejail/) and ~/.config/firejail/. This is not compatible with stateless systems and hermetic builds, in which distro-provided packages only ship files under /usr/, including default configuration files.

In addition, files in /etc are supposed to be owned by the system administrator and freely editable. Firejail's wiki states that profiles should not be modified

Modifying a profile file (.profile) in /etc/firejail is discouraged. Changes will be overwritten when you update Firejail

so it would make more sense to have the default profiles in /usr.

Proposed solution

In addition to searching for profiles in ~/.config/firejail/ and /etc/firejail/, Firejail should also search in /usr/lib/firejail/.

Distribution packages will install their files in /usr/lib/firejail/, system administators in /etc/firejail, and non-admin users in ~/.config/firejail.

Originally created by @gioele on GitHub (Jan 7, 2024). Original GitHub issue: https://github.com/netblue30/firejail/issues/6152 ### Problem description Firejail profiles are currently stored in `/etc/firejail/` (or `/usr/local/etc/firejail/`) and `~/.config/firejail/`. This is not compatible with stateless systems and hermetic builds, in which distro-provided packages only ship files under `/usr/`, including default configuration files. In addition, files in `/etc` are supposed to be owned by the system administrator and freely editable. [Firejail's wiki states that profiles should not be modified](https://github.com/netblue30/firejail/wiki/Creating-overrides#when-to-use-overrides) > Modifying a profile file (.profile) in /etc/firejail is discouraged. Changes will be overwritten when you update Firejail so it would make more sense to have the default profiles in `/usr`. ### Proposed solution In addition to searching for profiles in `~/.config/firejail/` and `/etc/firejail/`, Firejail should also search in `/usr/lib/firejail/`. Distribution packages will install their files in `/usr/lib/firejail/`, system administators in `/etc/firejail`, and non-admin users in `~/.config/firejail`.
gitea-mirror 2026-05-05 09:49:21 -06:00
  • closed this issue
  • added the
    duplicate
    label
Author
Owner

@rusty-snake commented on GitHub (Jan 7, 2024):

Duplicate of #4871

<!-- gh-comment-id:1880040883 --> @rusty-snake commented on GitHub (Jan 7, 2024): Duplicate of #4871
Author
Owner

@gioele commented on GitHub (Jan 7, 2024):

Thanks @rusty-snake for the pointer.

<!-- gh-comment-id:1880055832 --> @gioele commented on GitHub (Jan 7, 2024): Thanks @rusty-snake for the pointer.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/firejail#3206
No description provided.