This article provides information about the behavior of the firewall filters that are applied on loopback interfaces, which are part of virtual routers.
To protect the control-plane (routing engine) from various attacks that enter an interface, which is part of a virtual router.
To protect the routing engine or control plane from various DoS attacks via self traffic, such as SSH, Telnet, HTTP, HTTPS, and so on, a firewall filter has to be applied on the loopback interface ( lo0 unit 0 (lo0.0) ), which is part of the inet.0 default routing instance. In the default routing instance, not more than one logical unit for the loopback interface ( lo0 ) can be present. If more than one logical unit is configured in inet.0 , the following commit error is generated:
root@srx100-4# commit check [edit interfaces lo0] 'unit 1' if_instance: Multiple loopback interfaces not permitted in master routing instance error: configuration check-out failed
root@srx-2# show firewall filter A { term 1 { then { count A-rejected; reject; } } } filter B { term 1 { then { count B-accepted; accept; } } } [edit] root@srx-2# show interfaces lo0 unit 0 { family inet { filter { input A; } } } unit 1 { family inet { filter { input B; } } }
root@srx-1# run ssh 10.20.30.1 ssh: connect to host 10.20.30.2 port 22: Connection refused >>> rejected because of filter A applied in inet.0 [edit] root@srx-1# run ssh 10.20.40.1 [email protected]'s password: >>> accepted because of filter B applied in test.inet.0 routing instance
root@srx-2# show firewall filter A { term 1 { then { count A-rejected; reject; } } } root@srx-2# show interfaces lo0 unit 0 { family inet { filter { input A; } } } }
root@srx-1# run ssh 10.20.30.1 ssh: connect to host 10.20.30.2 port 22: Connection refused >>> rejected because of filter A applied in inet.0 [edit] root@srx-1# run ssh 10.20.40.1 [email protected]'s password: >>> accepted because of no filter applied on lo0.1 which belongs to test.inet.0 routing instance
root@srx-1# run ssh 10.20.30.1 ssh: connect to host 10.20.30.2 port 22: Connection refused >>> rejected because of filter A applied in inet.0 [edit] root@srx-1# run ssh 10.20.40.1 ssh: connect to host 10.20.40.2 port 22: Connection refused >>> rejected because there is no loopback interface in routing-instance test, which uses the filter A applied in default instance inet.0