# # インターネットと社内LANへ通信できる端末を制限 : ファイアウォール コマンド設定例 # # 経路設定 ip route default gateway pp 1 # ポート分離機能の設定 lan type lan1 port-based-option=split-into-123:4 # LAインターフェースの設定 ip lan1 address 172.16.1.254/24 # WANインターフェース(ISP)の設定 pp select 1 pp always-on on pppoe use lan2 pp auth accept chap pap pp auth myname [ISPに接続するID] [ISPに接続するパスワード] ppp lcp mru on 1454 ppp ipcp ipaddress on ppp ccp type none ip pp mtu 1454 ip pp inbound filter list 1001 1002 1003 1004 1005 1006 1007 1099 ip pp nat descriptor 1 pp enable 1 # NATの設定 nat descriptor type 1 masquerade nat descriptor address outer 1 ipcp nat descriptor address inner 1 172.16.1.150 # フィルターの設定 ip inbound filter 1001 reject-nolog * * tcp,udp * 135 ip inbound filter 1002 reject-nolog * * tcp,udp 135 * ip inbound filter 1003 reject-nolog * * tcp,udp * netbios_ns-netbios_ssn ip inbound filter 1004 reject-nolog * * tcp,udp netbios_ns-netbios_ssn * ip inbound filter 1005 reject-nolog * * tcp,udp * 445 ip inbound filter 1006 reject-nolog * * tcp,udp 445 * ip inbound filter 1007 reject-nolog 172.16.1.0/24 * * * * ip inbound filter 1099 pass-nolog * * * * * ip policy interface group 101 name=Private local lan1 ip policy address group 101 name=Private 172.16.1.0/24 ip policy address group 102 name=Any * ip policy service group 101 name="Open Services" ip policy service group 102 name=General dns ip policy service group 103 name=Mail pop3 smtp ip policy filter 1100 reject-nolog lan1 * * * * ip policy filter 1110 pass-nolog * * * * 102 ip policy filter 1122 static-pass-nolog * lan1 * * * ip policy filter 1123 static-pass-nolog * local * * * ip policy filter 1124 static-pass-log * * 172.16.1.0/24 * http ip policy filter 1150 pass-nolog * pp1 * * * ip policy filter 1500 reject-nolog pp* * * * * ip policy filter 1520 pass-log * lan1 * * 101 ip policy filter 1700 pass-nolog local * * * * ip policy filter 1710 static-pass-nolog * lan1 * * * ip policy filter 3000 reject-nolog * * * * * ip policy filter set 101 name="Internet Access" 1100 [1110 1123 [1124] 1122 1150] 1500 [1520] 1700 [1710] 3000 ip policy filter set enable 101 # DHCPの設定 dhcp service server dhcp server rfc2131 compliant except remain-silent dhcp scope 1 172.16.1.1-172.16.1.100/24 # DNSの設定 dns server [DNSサーバーのアドレス]