[GH-ISSUE #3066] Monitor network connection attempts with firejail/firemon #1919

Closed
opened 2026-05-05 08:35:19 -06:00 by gitea-mirror · 3 comments
Owner

Originally created by @curioustwo on GitHub (Nov 27, 2019).
Original GitHub issue: https://github.com/netblue30/firejail/issues/3066

Hi,
Is it possible to monitor outgoing network connections with either firejail or firemon? I would like to know which network connections an application is trying to make when it is "firejail'ed".

Thanks!

Originally created by @curioustwo on GitHub (Nov 27, 2019). Original GitHub issue: https://github.com/netblue30/firejail/issues/3066 Hi, Is it possible to monitor outgoing network connections with either firejail or firemon? I would like to know which network connections an application is trying to make when it is "firejail'ed". Thanks!
gitea-mirror 2026-05-05 08:35:19 -06:00
Author
Owner

@netblue30 commented on GitHub (Nov 29, 2019):

It is quite easy, but you have to start the sandbox with a network namespace (--net). For example:

$ firejail --name=mybrowser --net=eth0 firefox

Then, you open a new terminal and join the network namespace with some network monitor such as tcpdump:

$ sudo firejail --join-network=mybrowser tcpdump

The command runs as root (sudo).

You can also try wireshark. It used to work for me on the old Debian, but on the new one it doesn't. I guess it has to do with the way they set up X11, so I get something like:

~$ sudo firejail --join-network=mybrowser wireshark
Switching to pid 9548, the first child process inside the sandbox
Child process initialized in 8.57 ms
No protocol specified
qt.qpa.screen: QXcbConnection: Could not connect to display :0.0
Could not connect to any X display.
<!-- gh-comment-id:559888159 --> @netblue30 commented on GitHub (Nov 29, 2019): It is quite easy, but you have to start the sandbox with a network namespace (--net). For example: ````` $ firejail --name=mybrowser --net=eth0 firefox ````` Then, you open a new terminal and join the network namespace with some network monitor such as tcpdump: ````` $ sudo firejail --join-network=mybrowser tcpdump ````` The command runs as root (sudo). You can also try wireshark. It used to work for me on the old Debian, but on the new one it doesn't. I guess it has to do with the way they set up X11, so I get something like: ````` ~$ sudo firejail --join-network=mybrowser wireshark Switching to pid 9548, the first child process inside the sandbox Child process initialized in 8.57 ms No protocol specified qt.qpa.screen: QXcbConnection: Could not connect to display :0.0 Could not connect to any X display. `````
Author
Owner

@rusty-snake commented on GitHub (Jan 17, 2020):

@curioustwo
I'm closing here due to inactivity, please fell free to reopen if you have more questions.

<!-- gh-comment-id:575726514 --> @rusty-snake commented on GitHub (Jan 17, 2020): @curioustwo I'm closing here due to inactivity, please fell free to reopen if you have more questions.
Author
Owner

@curioustwo commented on GitHub (Jan 26, 2020):

I had a follow-up question. To do this without having the APP access Internet at all I would have to create a virtual eth interface or something? I want to monitor the attempts but not let it go through....

<!-- gh-comment-id:578549229 --> @curioustwo commented on GitHub (Jan 26, 2020): I had a follow-up question. To do this without having the APP access Internet at all I would have to create a virtual eth interface or something? I want to monitor the attempts but not let it go through....
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#1919
No description provided.