[GH-ISSUE #1076] Cannot ping my machine when I use --ip option #735

Closed
opened 2026-05-05 06:32:38 -06:00 by gitea-mirror · 3 comments
Owner

Originally created by @kadogo on GitHub (Jan 28, 2017).
Original GitHub issue: https://github.com/netblue30/firejail/issues/1076

Hello everyone.
I need to test something from 2 differents IP on a virtualbox machine.
I want avoid running 2 VMs so I would use my computer and an instance with firejail.

My vbox interface is vboxnet0 (192.168.10.1).
I run the following command.

firejail --noprofile --net=vboxnet0 --ip=192.168.10.2 bash
ping 192.168.10.1

When I do my ping it says my host is unreachable.
Maybe I missed something, so I come here to ask some help ^^

Thanks

Originally created by @kadogo on GitHub (Jan 28, 2017). Original GitHub issue: https://github.com/netblue30/firejail/issues/1076 Hello everyone. I need to test something from 2 differents IP on a virtualbox machine. I want avoid running 2 VMs so I would use my computer and an instance with firejail. My vbox interface is vboxnet0 (192.168.10.1). I run the following command. `firejail --noprofile --net=vboxnet0 --ip=192.168.10.2 bash` `ping 192.168.10.1` When I do my ping it says my host is unreachable. Maybe I missed something, so I come here to ask some help ^^ Thanks
gitea-mirror 2026-05-05 06:32:38 -06:00
Author
Owner

@netblue30 commented on GitHub (Jan 29, 2017):

It is by design, from inside the sandbox you cannot reach the host. An exploit would be for a crook to take control of the sandbox and then starting a dictionary attack on the host ssh server.

This happens only if --net is an Ethernet interface, for bridge interfaces the host is still accessible on the IP address of the bridge interface.

<!-- gh-comment-id:275942171 --> @netblue30 commented on GitHub (Jan 29, 2017): It is by design, from inside the sandbox you cannot reach the host. An exploit would be for a crook to take control of the sandbox and then starting a dictionary attack on the host ssh server. This happens only if --net is an Ethernet interface, for bridge interfaces the host is still accessible on the IP address of the bridge interface.
Author
Owner

@kadogo commented on GitHub (Jan 29, 2017):

Ok thanks for the information.
I will look how do it with a bridge interface then ^^

<!-- gh-comment-id:275955206 --> @kadogo commented on GitHub (Jan 29, 2017): Ok thanks for the information. I will look how do it with a bridge interface then ^^
Author
Owner

@netblue30 commented on GitHub (Jan 30, 2017):

The bridge is quite easy, take a look here: https://firejail.wordpress.com/documentation-2/basic-usage/#routed

You only enable ip forwarding and set netfilter if you need to forward traffic from your sandboxes out on the network.

<!-- gh-comment-id:276073127 --> @netblue30 commented on GitHub (Jan 30, 2017): The bridge is quite easy, take a look here: https://firejail.wordpress.com/documentation-2/basic-usage/#routed You only enable ip forwarding and set netfilter if you need to forward traffic from your sandboxes out on the network.
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#735
No description provided.