Hello.
Trying to play with IPFW ruleset with a Freebsd box that acts as a router.
A quite steep learning curve for sure, but managed to get it working after countless hours reading forums/examples.
Network is segmented into vlans. DMZ is one of them where all public services reside.
Trying to stick with recommendations to have as few rules as possible and place arguments as CIDR's, network interfaces in tables.
Current working set:
Dynamic rules for incoming packets on wan (igb0) are working just fine, but I'm failing to set dynamic ones up for internal vlans.
Idea would be that traffic via
would punch to DMZ and have a way back dynamically.
Any suggestions on how to achieve that? ?
Trying to play with IPFW ruleset with a Freebsd box that acts as a router.
A quite steep learning curve for sure, but managed to get it working after countless hours reading forums/examples.
Network is segmented into vlans. DMZ is one of them where all public services reside.
Trying to stick with recommendations to have as few rules as possible and place arguments as CIDR's, network interfaces in tables.
Current working set:
Code:
01001 allow ip4 from any to any via table(ifsafe) #internal vlans + lo0
01003 allow ip4 from any to table(dmz) via table(ifall) #allow all vlans to reach services in dmz
01009 allow ip4 from any to not table(netsafe) via table(ifwww) #vlan accessibility/separation
01020 allow icmp from any to any icmptypes 3,4,5,11,12 in
02001 nat 1 ip4 from any to any in recv igb0
02005 check-state :default
03001 deny tcp from any to any established in recv igb0
03004 skipto 9091 tag 999 tcp from any to any 25,587,993,5232,80,443 setup in recv igb0 keep-state :default
03005 skipto 9091 tag 999 udp from any to any 51820 in recv igb0 keep-state :default
03999 deny ip from any to any in recv igb0
05000 skipto 9010 tcp from not table(netnowww) to any setup out xmit igb0 keep-state :default
05001 skipto 9010 udp from not table(netnowww) to any out xmit igb0 keep-state :default
09010 nat 1 ip4 from any to any out xmit igb0
09011 allow ip4 from any to any via igb0
09091 nat 1 tag 999 ip4 from any to any out xmit igb0
09092 allow ip4 from any to any via igb0 tagged 999
10000 deny log ip from any to any
Dynamic rules for incoming packets on wan (igb0) are working just fine, but I'm failing to set dynamic ones up for internal vlans.
Idea would be that traffic via
Code:
table(ifall)
Any suggestions on how to achieve that? ?