KEvinn
Dabbler
- Joined
- Dec 22, 2015
- Messages
- 16
Hi,
I have a jail connected to a VPN and want to set up a firewall that make sure that the jail only gets internet access trough the VPN and if for some reason the VPN disconnects then the jail would have no internet access. So there was a guide to do this and I've followed it but when i try to connect to the jail local (192.168.1.xxx:yyyy) it cant connect, but if i disable the firewall then it will connect so there is clearly something wrong with my configuration. Can someone help me fix this please ?
Kind regards,
Kevin
I have a jail connected to a VPN and want to set up a firewall that make sure that the jail only gets internet access trough the VPN and if for some reason the VPN disconnects then the jail would have no internet access. So there was a guide to do this and I've followed it but when i try to connect to the jail local (192.168.1.xxx:yyyy) it cant connect, but if i disable the firewall then it will connect so there is clearly something wrong with my configuration. Can someone help me fix this please ?
Code:
ipfw -q -f flush ipfw -q add 01002 allow log udp from 192.168.1.0/24 to 10.4.0.1 dst-port 53 keep-state ipfw -q add 01002 allow log udp from 192.168.1.0/24 to 10.5.0.1 dst-port 53 keep-state ipfw -q add 01006 allow ip from 192.168.1.0/24 to 196.168.1.0/24 keep-state ipfw -q add 02000 allow ip from 192.168.1.0/24 to 109.232.227.148 keep-state ipfw -q add 04000 allow ip from 127.0.0.1 to any ipfw -q add 05000 allow ip from 10.0.0.0/8 to any ipfw -q add 05002 allow ip from any to 10.0.0.0/8 ipfw -q add 65534 deny ip from any to any ipfw -q nat 1 config if epair2b ipfw -q add nat 1 all from 10.8.0.0/24 to any out via epair2b ipfw -q add nat 1 all from any to any in via epair2b
Kind regards,
Kevin