I start VirtualBox and load required kernel modules through script when I need to use it. My VBox guests use the Host-Only network model, which passes traffic through the virtual NIC vboxnet0. This is a clone of lo0 AFAIK.
The problem is that vboxnet0 does not get created until I start a VBox guest, and this prevents me from writing rules involving vboxnet0 into my firewall pf.conf. What's the solution to this? I thought of creating a dummy vboxnet0 so that PF sees it when system starts up, but I can't remember how to create such interface:
I also have some doubts about this method because seeing that vboxnet0 already exists, VirtualBox may decide to create vboxnet1. Does any one have alternate bright ideas?
The problem is that vboxnet0 does not get created until I start a VBox guest, and this prevents me from writing rules involving vboxnet0 into my firewall pf.conf. What's the solution to this? I thought of creating a dummy vboxnet0 so that PF sees it when system starts up, but I can't remember how to create such interface:
Code:
cloned_interfaces="vboxnet0"
ifconfig_vboxnet0="inet 192.168.56.1/28"
I also have some doubts about this method because seeing that vboxnet0 already exists, VirtualBox may decide to create vboxnet1. Does any one have alternate bright ideas?