SlideShare a Scribd company logo
01. Simple Tutorial on Juniper Firewall Filters
R1
R2
J9
J10
20.0.0.0/30
20.0.0.4/30
20.0.0.8/30
e1
e0
e1
TooManyICMP
The scenario is simple. R1 is sending too many ICMP to R2 and this needs to be stopped.
Question to consider... do we place filters on 20.0.0.4/30 or at 20.0.0.8/30?
If you know that the source of the ICMP is coming from R1, the 20.0.0.4/30 segment is good.
Otherwise, placing it on the 20.0.0.8/30 segment is OK. It will buy you sometime for further
investigation. Most of the time, the customer(R2) can only tell you that their IP xxx is currently
experiencing an attack. They may not be able to tell you the source.
In our case, we will make pretend that we DO NOT know the source of the ICMP.
We will configure filters on 20.0.0.8/30 interface em1.
J10 – Define the firewall
firewall {
family inet {
filter no-icmp {
term 1 {
from {
icmp-type echo-request;
}
then {
reject administratively-prohibited;
}
}
term 2 {
then accept;
}
This rule will do the job
There is an IMPLICIT DENY rule if
you DON'T include this in term 2.
You have been warned.
Note the many types of ICMP
J10 - Apply this rule to your target interface
kjteoh@JunOS-10> show configuration interfaces em1
description J10-R2;
unit 0 {
family inet {
filter {
output no-icmp;
}
address 20.0.0.9/30;
You only need an
output rule here
R1 – After application of the rule ...
R1#ping 20.0.0.10
Sending 5, 100-byte ICMP Echos
to 20.0.0.10,
UUUUU
Success rate is 0 percent (0/5)
You can add this if you're interested
then {
count icmp-count;
reject administratively-prohibited;
}
J10 – firewall counters / hit rates
kjteoh@JunOS-10> show firewall counter filter no-icmp icmp-count
Filter: no-icmp
Counters:
Name Bytes Packets
icmp-count 152000 1580
In the alternative to “administratively-prohibited”, you can use
“discard” which will dissolve the pkt.
NB: We should note that all
other protocols between
R1 – R2 should work … eg.
R1 telnet R2... OK
R1#telnet 20.0.0.10
Trying 20.0.0.10 ... Open
User Access Verification
Username:
R1
R2
J9
J10
20.0.0.0/30
20.0.0.4/30
20.0.0.8/30
e1
e0
e1
TooManyICMP
02. Simple Tutorial on Juniper Firewall Filters – A place for Notes.
kjteoh 30/6/2016

More Related Content

Viewers also liked

Bgp
BgpBgp
Segment Routing Lab
Segment Routing Lab Segment Routing Lab
Segment Routing Lab
Cisco Canada
 
Traffic Engineering Using Segment Routing
Traffic Engineering Using Segment Routing Traffic Engineering Using Segment Routing
Traffic Engineering Using Segment Routing
Cisco Canada
 
Implementing Internet and MPLS BGP
Implementing Internet and MPLS BGPImplementing Internet and MPLS BGP
Implementing Internet and MPLS BGP
Private
 
Using BGP To Manage Dual Internet Connections
Using BGP To Manage Dual Internet ConnectionsUsing BGP To Manage Dual Internet Connections
Using BGP To Manage Dual Internet Connections
Rowell Dionicio
 
Bgp tutorial for ISP
Bgp tutorial for ISPBgp tutorial for ISP
Bgp tutorial for ISP
Wahyu Nasution
 
BGP Advance Technique by Steven & James
BGP Advance Technique by Steven & JamesBGP Advance Technique by Steven & James
BGP Advance Technique by Steven & JamesFebrian ‎
 
Deploying IP/MPLS VPN - Cisco Networkers 2010
Deploying IP/MPLS VPN - Cisco Networkers 2010Deploying IP/MPLS VPN - Cisco Networkers 2010
Deploying IP/MPLS VPN - Cisco Networkers 2010Febrian ‎
 
BGP Traffic Engineering / Routing Optimisation
BGP Traffic Engineering / Routing OptimisationBGP Traffic Engineering / Routing Optimisation
BGP Traffic Engineering / Routing Optimisation
Andy Davidson
 
Border Gateway Protocol
Border Gateway ProtocolBorder Gateway Protocol
Border Gateway ProtocolKashif Latif
 
Bgp Basic Labs
Bgp Basic LabsBgp Basic Labs
Bgp Basic Labs
cisconetworker
 
Segment Routing & Application Engeering Routing
Segment Routing & Application Engeering RoutingSegment Routing & Application Engeering Routing
Segment Routing & Application Engeering Routing
Bertrand Duvivier
 
Segment Routing Advanced Use Cases - Cisco Live 2016 USA
Segment Routing Advanced Use Cases - Cisco Live 2016 USASegment Routing Advanced Use Cases - Cisco Live 2016 USA
Segment Routing Advanced Use Cases - Cisco Live 2016 USA
Jose Liste
 
Segment Routing: A Tutorial
Segment Routing: A TutorialSegment Routing: A Tutorial
Segment Routing: A Tutorial
APNIC
 

Viewers also liked (15)

Bgp
BgpBgp
Bgp
 
Segment Routing Lab
Segment Routing Lab Segment Routing Lab
Segment Routing Lab
 
BGP
BGPBGP
BGP
 
Traffic Engineering Using Segment Routing
Traffic Engineering Using Segment Routing Traffic Engineering Using Segment Routing
Traffic Engineering Using Segment Routing
 
Implementing Internet and MPLS BGP
Implementing Internet and MPLS BGPImplementing Internet and MPLS BGP
Implementing Internet and MPLS BGP
 
Using BGP To Manage Dual Internet Connections
Using BGP To Manage Dual Internet ConnectionsUsing BGP To Manage Dual Internet Connections
Using BGP To Manage Dual Internet Connections
 
Bgp tutorial for ISP
Bgp tutorial for ISPBgp tutorial for ISP
Bgp tutorial for ISP
 
BGP Advance Technique by Steven & James
BGP Advance Technique by Steven & JamesBGP Advance Technique by Steven & James
BGP Advance Technique by Steven & James
 
Deploying IP/MPLS VPN - Cisco Networkers 2010
Deploying IP/MPLS VPN - Cisco Networkers 2010Deploying IP/MPLS VPN - Cisco Networkers 2010
Deploying IP/MPLS VPN - Cisco Networkers 2010
 
BGP Traffic Engineering / Routing Optimisation
BGP Traffic Engineering / Routing OptimisationBGP Traffic Engineering / Routing Optimisation
BGP Traffic Engineering / Routing Optimisation
 
Border Gateway Protocol
Border Gateway ProtocolBorder Gateway Protocol
Border Gateway Protocol
 
Bgp Basic Labs
Bgp Basic LabsBgp Basic Labs
Bgp Basic Labs
 
Segment Routing & Application Engeering Routing
Segment Routing & Application Engeering RoutingSegment Routing & Application Engeering Routing
Segment Routing & Application Engeering Routing
 
Segment Routing Advanced Use Cases - Cisco Live 2016 USA
Segment Routing Advanced Use Cases - Cisco Live 2016 USASegment Routing Advanced Use Cases - Cisco Live 2016 USA
Segment Routing Advanced Use Cases - Cisco Live 2016 USA
 
Segment Routing: A Tutorial
Segment Routing: A TutorialSegment Routing: A Tutorial
Segment Routing: A Tutorial
 

Similar to junos-firewall-filter

Gsm developer guide gsm at commands - rev a
Gsm developer guide   gsm at commands - rev  aGsm developer guide   gsm at commands - rev  a
Gsm developer guide gsm at commands - rev aAbdusSalam Voip
 
8051 training an interactive tutorial
8051 training an interactive tutorial8051 training an interactive tutorial
8051 training an interactive tutorial
Futura infotech
 
Didactum SNMP Manual
Didactum SNMP ManualDidactum SNMP Manual
Didactum SNMP Manual
Didactum
 
Handling Interrupts in Microchip MCUs
Handling Interrupts in Microchip MCUsHandling Interrupts in Microchip MCUs
Handling Interrupts in Microchip MCUsCorrado Santoro
 
Using Timers in PIC18F Microcontrollers
Using Timers in PIC18F MicrocontrollersUsing Timers in PIC18F Microcontrollers
Using Timers in PIC18F MicrocontrollersCorrado Santoro
 
s130-s150-user-manual-v1-50.pdf
s130-s150-user-manual-v1-50.pdfs130-s150-user-manual-v1-50.pdf
s130-s150-user-manual-v1-50.pdf
IbidhiEskander
 
Exam viewer2
Exam viewer2Exam viewer2
Exam viewer2
Jorgito Leal
 
Howto ethereal-wireshark-trace en
Howto ethereal-wireshark-trace enHowto ethereal-wireshark-trace en
Howto ethereal-wireshark-trace en
JORGE GOMEZ
 
892 f sfp configuration example
892 f sfp configuration example892 f sfp configuration example
892 f sfp configuration example
IT Tech
 
Esp8266 wi fi_module_quick_start_guide_v_1.0.4
Esp8266 wi fi_module_quick_start_guide_v_1.0.4Esp8266 wi fi_module_quick_start_guide_v_1.0.4
Esp8266 wi fi_module_quick_start_guide_v_1.0.4
Melvin Gutiérrez Rivero
 
33c3 - 2G and 3G intercom attacks
33c3 - 2G and 3G intercom attacks33c3 - 2G and 3G intercom attacks
33c3 - 2G and 3G intercom attacks
📡 Sebastien Dudek
 
Cisco CCNA-CCNP IP SLA Configuration
Cisco CCNA-CCNP IP SLA ConfigurationCisco CCNA-CCNP IP SLA Configuration
Cisco CCNA-CCNP IP SLA Configuration
Hamed Moghaddam
 
OSMC 2014: Server Hardware Monitoring done right | Werner Fischer
OSMC 2014: Server Hardware Monitoring done right | Werner FischerOSMC 2014: Server Hardware Monitoring done right | Werner Fischer
OSMC 2014: Server Hardware Monitoring done right | Werner Fischer
NETWAYS
 
Best-embedded-corporate-training-in-mumbai
Best-embedded-corporate-training-in-mumbaiBest-embedded-corporate-training-in-mumbai
Best-embedded-corporate-training-in-mumbai
Unmesh Baile
 
VoiceBootcamp Ccnp collaboration lab guide v1.0 sample
VoiceBootcamp Ccnp collaboration lab guide v1.0 sampleVoiceBootcamp Ccnp collaboration lab guide v1.0 sample
VoiceBootcamp Ccnp collaboration lab guide v1.0 sample
Faisal Khan
 
CCNA Lab 2-Configuring a Switch Part II
CCNA Lab 2-Configuring a Switch Part IICCNA Lab 2-Configuring a Switch Part II
CCNA Lab 2-Configuring a Switch Part II
Amir Jafari
 
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual-1...
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual-1...Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual-1...
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual-1...
Dien Ha The
 
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual-1...
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual-1...Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual-1...
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual-1...
Dien Ha The
 
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual d...
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual d...Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual d...
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual d...
Dien Ha The
 
Catalog Inverter FR-D700 safety stop function instruction manual-Beeteco.com
Catalog Inverter FR-D700 safety stop function instruction manual-Beeteco.comCatalog Inverter FR-D700 safety stop function instruction manual-Beeteco.com
Catalog Inverter FR-D700 safety stop function instruction manual-Beeteco.com
Beeteco
 

Similar to junos-firewall-filter (20)

Gsm developer guide gsm at commands - rev a
Gsm developer guide   gsm at commands - rev  aGsm developer guide   gsm at commands - rev  a
Gsm developer guide gsm at commands - rev a
 
8051 training an interactive tutorial
8051 training an interactive tutorial8051 training an interactive tutorial
8051 training an interactive tutorial
 
Didactum SNMP Manual
Didactum SNMP ManualDidactum SNMP Manual
Didactum SNMP Manual
 
Handling Interrupts in Microchip MCUs
Handling Interrupts in Microchip MCUsHandling Interrupts in Microchip MCUs
Handling Interrupts in Microchip MCUs
 
Using Timers in PIC18F Microcontrollers
Using Timers in PIC18F MicrocontrollersUsing Timers in PIC18F Microcontrollers
Using Timers in PIC18F Microcontrollers
 
s130-s150-user-manual-v1-50.pdf
s130-s150-user-manual-v1-50.pdfs130-s150-user-manual-v1-50.pdf
s130-s150-user-manual-v1-50.pdf
 
Exam viewer2
Exam viewer2Exam viewer2
Exam viewer2
 
Howto ethereal-wireshark-trace en
Howto ethereal-wireshark-trace enHowto ethereal-wireshark-trace en
Howto ethereal-wireshark-trace en
 
892 f sfp configuration example
892 f sfp configuration example892 f sfp configuration example
892 f sfp configuration example
 
Esp8266 wi fi_module_quick_start_guide_v_1.0.4
Esp8266 wi fi_module_quick_start_guide_v_1.0.4Esp8266 wi fi_module_quick_start_guide_v_1.0.4
Esp8266 wi fi_module_quick_start_guide_v_1.0.4
 
33c3 - 2G and 3G intercom attacks
33c3 - 2G and 3G intercom attacks33c3 - 2G and 3G intercom attacks
33c3 - 2G and 3G intercom attacks
 
Cisco CCNA-CCNP IP SLA Configuration
Cisco CCNA-CCNP IP SLA ConfigurationCisco CCNA-CCNP IP SLA Configuration
Cisco CCNA-CCNP IP SLA Configuration
 
OSMC 2014: Server Hardware Monitoring done right | Werner Fischer
OSMC 2014: Server Hardware Monitoring done right | Werner FischerOSMC 2014: Server Hardware Monitoring done right | Werner Fischer
OSMC 2014: Server Hardware Monitoring done right | Werner Fischer
 
Best-embedded-corporate-training-in-mumbai
Best-embedded-corporate-training-in-mumbaiBest-embedded-corporate-training-in-mumbai
Best-embedded-corporate-training-in-mumbai
 
VoiceBootcamp Ccnp collaboration lab guide v1.0 sample
VoiceBootcamp Ccnp collaboration lab guide v1.0 sampleVoiceBootcamp Ccnp collaboration lab guide v1.0 sample
VoiceBootcamp Ccnp collaboration lab guide v1.0 sample
 
CCNA Lab 2-Configuring a Switch Part II
CCNA Lab 2-Configuring a Switch Part IICCNA Lab 2-Configuring a Switch Part II
CCNA Lab 2-Configuring a Switch Part II
 
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual-1...
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual-1...Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual-1...
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual-1...
 
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual-1...
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual-1...Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual-1...
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual-1...
 
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual d...
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual d...Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual d...
Mitsubishi inverter catalog-fr-d700-safety-stop-function-instruction-manual d...
 
Catalog Inverter FR-D700 safety stop function instruction manual-Beeteco.com
Catalog Inverter FR-D700 safety stop function instruction manual-Beeteco.comCatalog Inverter FR-D700 safety stop function instruction manual-Beeteco.com
Catalog Inverter FR-D700 safety stop function instruction manual-Beeteco.com
 

junos-firewall-filter

  • 1. 01. Simple Tutorial on Juniper Firewall Filters R1 R2 J9 J10 20.0.0.0/30 20.0.0.4/30 20.0.0.8/30 e1 e0 e1 TooManyICMP The scenario is simple. R1 is sending too many ICMP to R2 and this needs to be stopped. Question to consider... do we place filters on 20.0.0.4/30 or at 20.0.0.8/30? If you know that the source of the ICMP is coming from R1, the 20.0.0.4/30 segment is good. Otherwise, placing it on the 20.0.0.8/30 segment is OK. It will buy you sometime for further investigation. Most of the time, the customer(R2) can only tell you that their IP xxx is currently experiencing an attack. They may not be able to tell you the source. In our case, we will make pretend that we DO NOT know the source of the ICMP. We will configure filters on 20.0.0.8/30 interface em1. J10 – Define the firewall firewall { family inet { filter no-icmp { term 1 { from { icmp-type echo-request; } then { reject administratively-prohibited; } } term 2 { then accept; } This rule will do the job There is an IMPLICIT DENY rule if you DON'T include this in term 2. You have been warned. Note the many types of ICMP J10 - Apply this rule to your target interface kjteoh@JunOS-10> show configuration interfaces em1 description J10-R2; unit 0 { family inet { filter { output no-icmp; } address 20.0.0.9/30; You only need an output rule here R1 – After application of the rule ... R1#ping 20.0.0.10 Sending 5, 100-byte ICMP Echos to 20.0.0.10, UUUUU Success rate is 0 percent (0/5) You can add this if you're interested then { count icmp-count; reject administratively-prohibited; } J10 – firewall counters / hit rates kjteoh@JunOS-10> show firewall counter filter no-icmp icmp-count Filter: no-icmp Counters: Name Bytes Packets icmp-count 152000 1580 In the alternative to “administratively-prohibited”, you can use “discard” which will dissolve the pkt. NB: We should note that all other protocols between R1 – R2 should work … eg. R1 telnet R2... OK R1#telnet 20.0.0.10 Trying 20.0.0.10 ... Open User Access Verification Username:
  • 2. R1 R2 J9 J10 20.0.0.0/30 20.0.0.4/30 20.0.0.8/30 e1 e0 e1 TooManyICMP 02. Simple Tutorial on Juniper Firewall Filters – A place for Notes. kjteoh 30/6/2016