mirror of
https://github.com/netblue30/firejail.git
synced 2026-05-15 14:16:14 -06:00
[GH-ISSUE #2004] [Question] Does Firejail "sudo" commands effective in this special case ? #1350
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#1350
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 @Nokia808 on GitHub (Jun 19, 2018).
Original GitHub issue: https://github.com/netblue30/firejail/issues/2004
Hi.
Currently I'm using WineHQ according to this super secure installation guide:
https://forums.fedoraforum.org/showthread.php?313858-Risk-Free-WineHQ-Installation-amp-Usage
Please notice the following about this method:
WineHQ binaries ownership & permissions all are changed so that WineHQ are owned by a special user account (WineHQ are isolated totally in special new user account)
the special new user account is completely rootless (have no su nor sudo nor PolcyKit power).
My question case is: I like to add additional layer of security by using Firejail. Firejail certainly can never ever be installed from Wine special account because it need sudo to be installed. So, I'm only able to install Firejail from within my 1st user account which I created during fresh installation & have all root powers including su.
But to make Firejail's profile of WineHQ I need the following command:
sudo firecfg --clean && sudo ln -s /usr/bin/firejail /usr/local/bin/wine
the above command is to make WineHQ only sanbox WineHQ not other application.
So, does the above command (or "sudo firecfg" which make WineHQ sandbox all supported application not only Wine) will take effect on WineHQ ? When I run "sudo dnf remove wine" or sudo dnf upgrade wine" from my 1st user account they working. But the Firejail commands that I asking about them deal with sandbox for a package binaries owned by only special user account & not by all accounts on system (Windows application inside my 1st user account can not make use of Wine to run at all).
Best.
@netblue30 commented on GitHub (Jun 22, 2018):
firecfg is setting a bunch of symbolic links in /usr/local/bin. Once you run it from your regular account, it is available to all users in the system. You don't need to run it again from your special wineuser account. All you have to do is to add that user to the list in /etc/firejail/firejail.users file. Or you can run "sudo firecfg --add-users wineuser" from your regular account.
@Nokia808 commented on GitHub (Jun 22, 2018):
@netblue30
Thank you for response. O.K, so, "sudo firecfg --add-users wineuser"
But what about "sudo firecfg --clean && sudo ln -s /usr/bin/firejail /usr/local/bin/wine" command ? Is the same applied to this command also ? If yes, then, how it will be ? (where I have to put "--add-users wineuser" ?)
By the way, I conclude from the need to add "--add-users wineuser" to firecfg (add that user to the list in /etc/firejail/firejail.users file), that Firejail by default add only the root accounts (su & sudo accounts) after it's installation & do not include other added accounts. Is this correct or I'm wrong ?
@chiraag-nataraj commented on GitHub (Jul 9, 2018):
So if I understand you correctly, you're asking if manually symlinking one binary (rather than all as
firecfgwill do) will be subject to the same access restrictions as it would be underfirecfg. The answer, from what I understand, should be yes. If you only want to (automatically) runwineunderfirejail, then do the following steps:sudo firecfg --cleansudo ln -s /usr/bin/firejail /usr/local/bin/winesudo firecfg --add-users wineuserand you should be good to go!
@chiraag-nataraj commented on GitHub (Jul 24, 2018):
Closing, since the question seems to be answered. @Nokia808 Please feel free to re-open if you still have questions.