mirror of
https://github.com/netblue30/firejail.git
synced 2026-05-15 14:16:14 -06:00
[GH-ISSUE #2099] Question : firejail and Xephyr #1417
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#1417
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 @deb75 on GitHub (Aug 29, 2018).
Original GitHub issue: https://github.com/netblue30/firejail/issues/2099
Hello,
I am used to launch X applications like browsers with firejail, Xephyr and openbox :
Then,
openboxautostarts the desired application insideXephyr.I would like to proceed differently :
Xephyr -ac -br :1DISPLAY=:1 awesomeDISPLAY=:1 firejail --private firefoxI would like to know if it is equivalent in terms of security provided by firejail.
Regards
@netblue30 commented on GitHub (Aug 30, 2018):
In your example:
the last line (firefox) is bad. You need a network namespace for it, something like:
Without --net=eth0 the main X11 display is still available, the bad guy can still connect to it. Also, programs you start directly in awesome are not sandboxed. The setup is not bad, but you can do better.
I would suggest to follow this guide: https://firejail.wordpress.com/documentation-2/basic-usage/#x11 where you replace openbox with awesome but still use the openbox profile. So, the first command should be:
Then, you just follow with the rest of the steps there. In the end you will have your programs Xephyr/awesome/firefox each of them running in a different sandbox.
@chiraag-nataraj commented on GitHub (Oct 3, 2018):
I think this question was answered. @deb75 please feel free to re-open if your questions weren't answered :)
@deb75 commented on GitHub (Oct 3, 2018):
Hi,
I ended up doing :
wlp1s0is the name of my wifi interface.I prefer to launch
Xephyrmyself so that I can better control the display number. I hope it does not introduce security holes.Trouble is that
firefoxdoes not work well with the option--net=wlp1s0that you advocated. It launches itself well but cannot reach internet as if there were no internet connexion. I checked that it works well without this option, what is the trouble with-net=wlp1s0?Thanks in advance for your kind help
Regards
@chiraag-nataraj commented on GitHub (Oct 3, 2018):
@deb75 Which version of
firejaildo you have? The ability to have a network namespace with wireless interfaces was only added in0.9.56, so you should use at least that version for what you're trying to do.@deb75 commented on GitHub (Oct 3, 2018):
I have just installed the 0.9.56 version :
But when launching like this :
I get this error :
What is the trouble ?
@chiraag-nataraj commented on GitHub (Oct 4, 2018):
Are you sure the interface is called
wlp1s0? Can you do anip addrand post the output here? I had this error earlier, but it was somehow resolved by the time0.9.56was released.@deb75 commented on GitHub (Oct 4, 2018):
Hi,
Here the output of
ip addr:I wonder what means "Operation not supported". Does it depend on the wireless driver ? That is to say some drivers did implement this feature and some others did not. My wifi card uses the
mwifiexkernel module.@deb75 commented on GitHub (Oct 5, 2018):
I tried with latest git version (master branch) and I still get this very same error.
In the kernel log at boot, I can read :
So it seems the
wlp1s0interface name is not the original one,mlan0is renamedwlp1s0by the wireless kernel module for my wifi card. However callingfirejailwith--net=mlan0has no more success, it just returnsError: cannot find network device mlan0Any hints ?
Regards
@chiraag-nataraj commented on GitHub (Oct 6, 2018):
@deb75
Yeah, that's systemd renaming interfaces (you could disable that, but it's not what's causing the issue here).
As I understand it, it shouldn't be an issue.
firejailuses the standardipvlandriver to shuttle traffic back and forth, so this should work. We had #2046, but I don't think there was ever a satisfactory resolution - things just started working for me and the core issue there was never resolved.@deb75 commented on GitHub (Oct 8, 2018):
My bad !
I had my kernel recompiled a few months ago and forgot to include some drivers, among which
ipvlan.Once all drivers present, it works well, this explains the error "Operation not supported", without the driver ...