mirror of
https://github.com/netblue30/firejail.git
synced 2026-05-15 14:16:14 -06:00
[GH-ISSUE #498] "generic.profile" vs "default.profile" ambiguity #349
Labels
No labels
LTS merge
LTS merge
bug
bug
converted-to-discussion
doc-todo
documentation
duplicate
enhancement
file-transfer
firecfg
firejail-in-firejail
firetools
graphics
help wanted
information_old
installation
invalid
modif
moved
needinfo
networking
notabug
notourbug
old-version
overlayfs
packaging
profile-request
pull-request
question
question_old
removal
runtime-permissions
sandbox-ipc
security
stale
wiki
wiki
wontfix
wordpress
workaround
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/firejail#349
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @vn971 on GitHub (May 3, 2016).
Original GitHub issue: https://github.com/netblue30/firejail/issues/498
Please fix the ambiguity in either of the two directions.
Currently, firejail does ship a
generic.profilefile, and uses it when possible. On the other hand,firejail-profilemanual says it will look fordefault.profileandserver.profilefiles.I find
default.profileto be a better name, butgenericis used already, so I guess I fully leave the choice to the author..@netblue30 commented on GitHub (May 4, 2016):
From man firejail-profile:
later: You are right, I'll have to fix it. I'll change generic.profile to default profile!
@vn971 commented on GitHub (May 4, 2016):
Cool, thanks.:)
@netblue30 commented on GitHub (May 4, 2016):
Fixed, give it a try and let me know if you find anything else. I'll update the project webpages after I release the next version. Thanks.
@vn971 commented on GitHub (May 15, 2016):
Hm, I'm not sure it works. I'm testing the following scheme now:
firejail.configanddefault.profile, with default.profile being generated byecho syntaxError > /etc/firejail/default.profilefirejailwithout any additional command line arguments.Expected: firejail failing to load itself because either the absence of a profile file, or because of incorrect syntaxt in it.
Observe: firejail actually loading itself. With empty rule set it seems.
@netblue30 commented on GitHub (May 17, 2016):
This is what I get:
I would say it is the expected behavior. Not a bug.
@vn971 commented on GitHub (May 17, 2016):
Hm, that's strange.
It still does not work for me. I even removed both the
/etc/firejailand~/.config/firejaildirectories, but firejail still loads itself.UPDATE: I re-compiled from
master, but still observe the bug. I use ArchLinux with the following build "script": https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=firejail-git@vn971 commented on GitHub (May 17, 2016):
Output for
firejail --debug(first lines):@netblue30 commented on GitHub (May 31, 2016):
I have the new release out, give it a try and I'll reopen the bug if you still have problems.
@vn971 commented on GitHub (Jul 14, 2016):
Hi! Sorry for the late reply. The bug persists in recent versions of
firejail, too. My directory structure and the observed bug are the same as described earlier: https://github.com/netblue30/firejail/issues/498#issuecomment-219276532I'm using "firejail version 0.9.41" (as shown by
firejail --version).@netblue30 commented on GitHub (Jul 14, 2016):
OK, let's start from the beginning. On version 0.9.41, print here the commands you run and the output you get.
@vn971 commented on GitHub (Jul 14, 2016):
mv ~/.config/firejail ~/.config/firejail2(no output since it is a successful operation)/etc/firejailexcept/etc/firejail/firejail.configfirejail.Without any additional command line arguments. Output:@vn971 commented on GitHub (Jul 14, 2016):
Alternative one-liner to show the bug:
firejail --noprofile --private --blacklist=/etc/firejail firejailIn this example, inner firejail should not have access to any profiles, so it should fail. In fact it does not fail.
@vn971 commented on GitHub (Jul 14, 2016):
@netblue30 Can you reproduce with the last (simple) example?
@netblue30 commented on GitHub (Jul 14, 2016):
It doesn't get a chance to fail, but it doesn't start either. It detects an existing sandbox, and it runs a normal bash session (see the warning).
If you force it to start with --force, this is what happens:
So it fails, as it should be.
@vn971 commented on GitHub (Jul 14, 2016):
@netblue30 indeed. I have to write it a bit differently. This command still shows the bug:
firejail --noprofile --private --blacklist=/etc/firejail/default.profile firejail --force@netblue30 commented on GitHub (Jul 14, 2016):
It doesn't find a default.profile and it is shutting down. Is this a bug? You can add --noprofile at the end of the command and it will start.
@vn971 commented on GitHub (Jul 15, 2016):
@netblue30 sorry again, I forgot my computer does not have the file ("/etc/firejail/default.profile"), so my
--blacklistbehaves differently on other computers.If your patience has not been spent already yet... To reproduce the bug on a fresh environment, the following is needed:
Or, alternatively, this:
@netblue30 commented on GitHub (Jul 18, 2016):
No problem, keep going. It usually ends up with me fixing some hard to catch bug. This is what I do:
So far so good. Firejail doens't care /etcfirejail/default.profile is missing because it was told not to care by --noprofile. Then I run the second command:
This one shouldn't succeed because the default profile is missing. You are right, it is a bug!
@netblue30 commented on GitHub (Jul 20, 2016):
Fixed in git, thanks!
@vn971 commented on GitHub (Jul 20, 2016):
@netblue30 indeed it works now. Thanks!