Access Control List
The right tool for the right job.
Vocab:
- ACL
- ACE
- VACL
- tACL (Transit)
- iACL (infrastructure)
- rACL (Receive)
! Anti-spoofing entries
R2(config)#access-list 110 deny ip host 55.44.33.195 any
R2(config)#access-list 110 deny ip host 55.44.33.200 any
! Deny special-use address sources
* Note: Refer to RFC 3330 for more special use addresses [Link]
R2(config)#access-list 110 deny ip host 0.0.0.0 any
R2(config)#access-list 110 deny ip 127.0.0.0 0.255.255.255 any
R2(config)#access-list 110 deny ip 192.0.2.0 0.0.0.255 any
R2(config)#access-list 110 deny ip 224.0.0.0 31.255.255.255 any
! --- Filter RFC 1918 space as source
R2(config)#access-list 110 deny ip 10.0.0.0 0.255.255.255 any
R2(config)#access-list 110 deny ip 172.16.0.0 0.15.255.255 any
R2(config)#access-list 110 deny ip 192.166.0.0 0.0.255.255 any
! Deny your space as source from entering your network
! Deploy only at the AS edge
R2(config)#access-list 110 deny ip 55.44.33.192 0.0.0.15 any
! Permit BGP
R2(config)#access-list 110 permit tcp host 12.23.34.45 host 55.44.33.195 eq bgp
R2(config)#access-list 110 permit tcp host 12.23.34.45 eq bgp host 55.44.33.195
! Deny access to internal infrastructure addresses
R2(config)#access-list 110 deny ip any host 55.44.33.195
R2(config)#access-list 110 deny ip any host 55.44.33.200
! Permit transit traffic
R2(config)#access-list 110 permit ip any any
! Verify Configuration
R2(config)#do show access-list 110
Extended IP access list 110
10 deny ip host 55.44.33.195 any
20 deny ip host 55.44.33.200 any
30 deny ip host 0.0.0.0 any
40 deny ip 127.0.0.0 0.255.255.255 any
50 deny ip 192.0.2.0 0.0.0.255 any
60 deny ip 224.0.0.0 31.255.255.255 any
70 deny ip 10.0.0.0 0.255.255.255 any
80 deny ip 172.16.0.0 0.15.255.255 any
90 deny ip 192.166.0.0 0.0.255.255 any
100 deny ip 55.44.33.192 0.0.0.15 any
110 permit tcp host 12.23.34.45 host 55.44.33.195 eq bgp
120 permit tcp host 12.23.34.45 eq bgp host 55.44.33.195
130 deny ip any host 55.44.33.195
140 deny ip any host 55.44.33.200
150 permit ip any any
RFC 3330 :
Address Block Present Use Reference
---------------------------------------------------------------------
0.0.0.0/8 "This" Network [RFC1700, page 4]
10.0.0.0/8 Private-Use Networks [RFC1918]
14.0.0.0/8 Public-Data Networks [RFC1700, page 181]
24.0.0.0/8 Cable Television Networks
39.0.0.0/8 Reserved but subject to allocation [RFC1797]
127.0.0.0/8 Loopback [RFC1700, page 5]
128.0.0.0/16 Reserved but subject to allocation
169.254.0.0/16 Link Local
172.16.0.0/12 Private-Use Networks [RFC1918]
191.255.0.0/16 Reserved but subject to allocation
192.0.0.0/24 Reserved but subject to allocation
192.0.2.0/24 Test-Net
192.88.99.0/24 6to4 Relay Anycast [RFC3068]
192.168.0.0/16 Private-Use Networks [RFC1918]
198.18.0.0/15 Net Interconnect Device Benchmark Test [RFC2544]
223.255.255.0/24 Reserved but subject to allocation
224.0.0.0/4 Multicast [RFC3171]
240.0.0.0/4 Reserved for Future Use [RFC1700, page 4]
We are here some LoRaWAN Certified Engineers, Really interested to extend the coverage over the Globe! Lets Build IoT Network ! We can help and support to buy your correct Miner. Helium Hotspot Mining - Sharing Experience - Recommendations, Antennas and Hardware.
Showing posts with label BGP. Show all posts
Showing posts with label BGP. Show all posts
04 August, 2014
30 July, 2014
Understanding BGP TTL Security
By default, IOS sends BGP messages to EBGP neighbors with an IP time-to-live (TTL) of 1.
This can be adjusted with ebgp-multihop attached to the desired neighbor or peer group under BGP configuration.)
Sending BGP messages with a TTL of one requires that the peer be directly connected, or the packets will expire in transit.
Likewise, a BGP router will only accept incoming BGP messages with a TTL of 1 (or whatever value is specified by ebgp-multihop),
which can help mitigate spoofing attacks.
However, there is an inherent vulnerability to this approach: it is trivial for a remote attacker to adjust the TTL of sent packets
so that they appear to originating from a directly-connected peer.
By spoofing legitimate-looking packets toward a BGP router at high volume, a denial of service (DoS) attack may be accomplished.
A very simple solution to this, as discussed in RFC 5082, is to invert the direction in which the TTL is counted. The maximum value
of the 8-bit TTL field in an IP packet is 255; instead of accepting only packets with a TTL set to 1, we can accept only packets with
a TTL of 255 to ensure the originator really is exactly one hop away. This is accomplished on IOS with the TTL security feature,
by appending ttl-security hops <count> to the BGP peer statement.
Only BGP messages with an IP TTL greater than or equal to 255 minus the specified hop count will be accepted. TTL security and
EBGP multihop are mutually exclusive; ebgp-multihop is no longer needed when TTL security is in use.
This can be adjusted with ebgp-multihop attached to the desired neighbor or peer group under BGP configuration.)
Sending BGP messages with a TTL of one requires that the peer be directly connected, or the packets will expire in transit.
Likewise, a BGP router will only accept incoming BGP messages with a TTL of 1 (or whatever value is specified by ebgp-multihop),
which can help mitigate spoofing attacks.
However, there is an inherent vulnerability to this approach: it is trivial for a remote attacker to adjust the TTL of sent packets
so that they appear to originating from a directly-connected peer.
By spoofing legitimate-looking packets toward a BGP router at high volume, a denial of service (DoS) attack may be accomplished.
A very simple solution to this, as discussed in RFC 5082, is to invert the direction in which the TTL is counted. The maximum value
of the 8-bit TTL field in an IP packet is 255; instead of accepting only packets with a TTL set to 1, we can accept only packets with
a TTL of 255 to ensure the originator really is exactly one hop away. This is accomplished on IOS with the TTL security feature,
by appending ttl-security hops <count> to the BGP peer statement.
Only BGP messages with an IP TTL greater than or equal to 255 minus the specified hop count will be accepted. TTL security and
EBGP multihop are mutually exclusive; ebgp-multihop is no longer needed when TTL security is in use.
07 July, 2013
BGP ALWAYS COMPARE MED
BGP ALWAYS COMPARE MED
SCENARIO:
You are the senior networking engineer working for a huge comic book provider. Your network (AS 100) is connected to 2 different service providers and normally all traffic is being sent to your main ISP which is AS 300. However there is a certain network that is being sent to AS 200 which is your backup ISP. All traffic should be sent towards AS300, is this a cheap trick from your backup ISP to make more money? Or is there something else going on? Time for justice!
You are the senior networking engineer working for a huge comic book provider. Your network (AS 100) is connected to 2 different service providers and normally all traffic is being sent to your main ISP which is AS 300. However there is a certain network that is being sent to AS 200 which is your backup ISP. All traffic should be sent towards AS300, is this a cheap trick from your backup ISP to make more money? Or is there something else going on? Time for justice!
GOAL:
- All IP addresses are preconfigured as specified in the topology picture.
- Configure EBGP between AS 100 and AS 200.
- Configure EBGP between AS 100 and AS 300, make sure you have a neighbor relationship between router Spiderman and Superman as well as between router Spiderman and Ironman.
- Configure IBGP within AS 300.
- Make sure all neighbor relationships are working, advertise the correct networks in BGP to achieve full connectivity.
- Router Batman AND Superman have the same IP address on the loopback1 interface, advertise this in BGP on both routers.
- Ensure you can ping the 1.2.3.4 address from router Spiderman.
- Take a look at the BGP table with 'show ip bgp' on router Spiderman.
- Which path is being used for the 1.2.3.4 network?
- Configure router Ironman and Superman so they send a MED of 50 for the 1.2.3.4 network towards router Spiderman.
- Configure router Batman so it sends a MED of 150 for the 1.2.3.4 network towards router Spiderman.
- Check router Spiderman with 'show ip bgp' to see the changes you just made, if not do a 'clear ip bgp *'
- Even though the MED from AS 300 is better, why is traffic towards 1.2.3.4 still being sent towards AS 200?
- Configure router Spiderman so traffic towards 1.2.3.4 is sent towards AS 300, the only attribute you are allowed to change is MED.
- All IP addresses are preconfigured as specified in the topology picture.
- Configure EBGP between AS 100 and AS 200.
- Configure EBGP between AS 100 and AS 300, make sure you have a neighbor relationship between router Spiderman and Superman as well as between router Spiderman and Ironman.
- Configure IBGP within AS 300.
- Make sure all neighbor relationships are working, advertise the correct networks in BGP to achieve full connectivity.
- Router Batman AND Superman have the same IP address on the loopback1 interface, advertise this in BGP on both routers.
- Ensure you can ping the 1.2.3.4 address from router Spiderman.
- Take a look at the BGP table with 'show ip bgp' on router Spiderman.
- Which path is being used for the 1.2.3.4 network?
- Configure router Ironman and Superman so they send a MED of 50 for the 1.2.3.4 network towards router Spiderman.
- Configure router Batman so it sends a MED of 150 for the 1.2.3.4 network towards router Spiderman.
- Check router Spiderman with 'show ip bgp' to see the changes you just made, if not do a 'clear ip bgp *'
- Even though the MED from AS 300 is better, why is traffic towards 1.2.3.4 still being sent towards AS 200?
- Configure router Spiderman so traffic towards 1.2.3.4 is sent towards AS 300, the only attribute you are allowed to change is MED.
batman(config)#router bgp 200
batman(config-router)#neighbor 192.168.12.1 remote-as 100
batman(config-router)#neighbor 192.168.12.1 remote-as 100
ironman#conf ter
ironman(config)#router bgp 300
ironman(config-router)#neighbor 192.168.13.1 remote-as 100
ironman(config-router)#neighbor 192.168.34.4 remote-as 300
superman#configure terminal
superman(config)#router bgp 300
superman(config-router)#neighbor 192.168.34.3 remote-as 300
superman(config-router)#neighbor 192.168.14.1 remote-as 100
*Mar 1 00:13:38.751: %BGP-5-ADJCHANGE: neighbor 192.168.34.3 Up
spiderman#configure terminal
spiderman(config)#router bgp 100
spiderman(config-router)#neighbor 192.168.12.2 remote-as 200
spiderman(config-router)#neighbor 192.168.13.3 remote-as 300
spiderman(config-router)#neighbor 192.168.14.4 remote-as 300
*Mar 1 00:10:13.655: %BGP-5-ADJCHANGE: neighbor 192.168.12.2 Up
*Mar 1 00:12:11.971: %BGP-5-ADJCHANGE: neighbor 192.168.13.3 Up
*Mar 1 00:14:21.431: %BGP-5-ADJCHANGE: neighbor 192.168.14.4 Up
superman(config-router)#network 4.4.4.0 mask 255.255.255.0
superman(config-router)#network 192.168.14.0 mask 255.255.255.0
superman(config-router)#network 192.168.34.0 mask 255.255.255.0
spiderman(config-router)#network 1.1.1.0 mask 255.255.255.0
spiderman(config-router)#network 192.168.12.0 mask 255.255.255.0
spiderman(config-router)#network 192.168.13.0 mask 255.255.255.0
spiderman(config-router)#network 192.168.14.0 mask 255.255.255.0
batman#configure terminal
batman(config)#interface loopback 1
batman(config-if)#ip address 1.2.3.4 255.255.255.255
batman(config-if)#router bgp 200
batman(config-router)#network 1.2.3.4 mask 255.255.255.255
superman(config)#interface loopback 1
superman(config-if)#ip address 1.2.3.4 255.255.255.255
superman(config-if)#router bgp 300
superman(config-router)#network 1.2.3.4 mask 255.255.255.255
spiderman#show ip bgp 1.2.3.4
BGP routing table entry for 1.2.3.4/32, version 11
Paths: (3 available, best #3, table Default-IP-Routing-Table)
Advertised to update-groups:
1
200
192.168.12.2 from 192.168.12.2 (2.2.2.2)
Origin IGP, metric 0, localpref 100, valid, external
300
192.168.13.3 from 192.168.13.3 (3.3.3.3)
Origin IGP, localpref 100, valid, external
300
192.168.14.4 from 192.168.14.4 (4.4.4.4)
Origin IGP, metric 0, localpref 100, valid, external, best
spiderman#show ip bgp | be 1.2.3.4
* 1.2.3.4/32 192.168.12.2 0 0 200 i
* 192.168.13.3 0 300 i
*> 192.168.14.4 0 0 300 i
superman#configure terminal
superman(config)#access-list 1 permit 1.2.3.4
superman(config)#route-map MED permit 10
superman(config-route-map)#match ip address 1
superman(config-route-map)#set metric 50
superman(config-route-map)#exit
superman(config)#route-map MED permit 20
superman(config-route-map)#exit
superman(config)#router bgp 300
superman(config-router)#neighbor 192.168.14.1 route-map MED out
superman(config-router)#exit
ironman#configure terminal
ironman(config)#access-list 1 permit 1.2.3.4
ironman(config)#route-map MED permit 10
ironman(config-route-map)#match ip address 1
ironman(config-route-map)#set metric 50
ironman(config-route-map)#exit
ironman(config)#route-map MED permit 20
ironman(config-route-map)#exit
ironman(config)#router bgp 300
ironman(config-router)#neighbor 192.168.13.1 route-map MED out
ironman(config-router)#exit
spiderman#clear ip bgp *
spiderman#show ip bgp | be 1.2.3.4
* 1.2.3.4/32 192.168.13.3 50 0 300 i
* 192.168.14.4 50 0 300 i
*> 192.168.12.2 150 0 200 i
spiderman#configure terminal
spiderman(config)#router bgp 100
spiderman(config-router)#bgp always-compare-med
spiderman(config-router)#do clear ip bgp *
*Mar 1 00:56:27.611: %BGP-5-ADJCHANGE: neighbor 192.168.12.2 Down User reset
*Mar 1 00:56:27.615: %BGP-5-ADJCHANGE: neighbor 192.168.13.3 Down User reset
*Mar 1 00:56:27.615: %BGP-5-ADJCHANGE: neighbor 192.168.14.4 Down User reset
*Mar 1 00:56:28.443: %BGP-5-ADJCHANGE: neighbor 192.168.12.2 Up
*Mar 1 00:56:28.835: %BGP-5-ADJCHANGE: neighbor 192.168.14.4 Up
*Mar 1 00:56:29.135: %BGP-5-ADJCHANGE: neighbor 192.168.13.3 Up
spiderman(config-router)#do show ip bgp | be 1.2.3.4
*> 1.2.3.4/32 192.168.13.3 50 0 300 i
* 192.168.14.4 50 0 300 i
* 192.168.12.2 150 0 200 i
ironman(config)#router bgp 300
ironman(config-router)#neighbor 192.168.13.1 remote-as 100
ironman(config-router)#neighbor 192.168.34.4 remote-as 300
superman#configure terminal
superman(config)#router bgp 300
superman(config-router)#neighbor 192.168.34.3 remote-as 300
superman(config-router)#neighbor 192.168.14.1 remote-as 100
*Mar 1 00:13:38.751: %BGP-5-ADJCHANGE: neighbor 192.168.34.3 Up
spiderman#configure terminal
spiderman(config)#router bgp 100
spiderman(config-router)#neighbor 192.168.12.2 remote-as 200
spiderman(config-router)#neighbor 192.168.13.3 remote-as 300
spiderman(config-router)#neighbor 192.168.14.4 remote-as 300
*Mar 1 00:10:13.655: %BGP-5-ADJCHANGE: neighbor 192.168.12.2 Up
*Mar 1 00:12:11.971: %BGP-5-ADJCHANGE: neighbor 192.168.13.3 Up
*Mar 1 00:14:21.431: %BGP-5-ADJCHANGE: neighbor 192.168.14.4 Up
spiderman(config-router)#do show ip bgp summary
BGP router identifier 1.1.1.1, local AS number 100
BGP table version is 1, main routing table version 1
Neighbor V AS MsgRcvd MsgSent TblVer InQ OutQ Up/Down State/PfxRcd
192.168.12.2 4 200 13 13 1 0 0 00:10:06 0
192.168.13.3 4 300 11 12 1 0 0 00:08:07 0
192.168.14.4 4 300 9 9 1 0 0 00:05:58 0
superman(config-router)#do show ip bgp summary
BGP router identifier 4.4.4.4, local AS number 300
BGP table version is 1, main routing table version 1
Neighbor V AS MsgRcvd MsgSent TblVer InQ OutQ Up/Down State/PfxRcd
192.168.14.1 4 100 10 10 1 0 0 00:06:28 0
192.168.34.3 4 300 10 10 1 0 0 00:06:34 0
Advertise Networks
batman(config-router)#network 2.2.2.0 mask 255.255.255.0
batman(config-router)#network 192.168.12.0 mask 255.255.255.0
superman(config-router)#network 192.168.14.0 mask 255.255.255.0
superman(config-router)#network 192.168.34.0 mask 255.255.255.0
ironman(config-router)#network 3.3.3.0 mask 255.255.255.0
ironman(config-router)#network 192.168.34.0 mask 255.255.255.0
ironman(config-router)#network 192.168.13.0 mask 255.255.255.0
spiderman(config-router)#network 192.168.12.0 mask 255.255.255.0
spiderman(config-router)#network 192.168.13.0 mask 255.255.255.0
spiderman(config-router)#network 192.168.14.0 mask 255.255.255.0
batman(config)#interface loopback 1
batman(config-if)#ip address 1.2.3.4 255.255.255.255
batman(config-if)#router bgp 200
batman(config-router)#network 1.2.3.4 mask 255.255.255.255
superman(config-if)#ip address 1.2.3.4 255.255.255.255
superman(config-if)#router bgp 300
superman(config-router)#network 1.2.3.4 mask 255.255.255.255
BGP routing table entry for 1.2.3.4/32, version 11
Paths: (3 available, best #3, table Default-IP-Routing-Table)
Advertised to update-groups:
1
200
192.168.12.2 from 192.168.12.2 (2.2.2.2)
Origin IGP, metric 0, localpref 100, valid, external
300
192.168.13.3 from 192.168.13.3 (3.3.3.3)
Origin IGP, localpref 100, valid, external
300
192.168.14.4 from 192.168.14.4 (4.4.4.4)
Origin IGP, metric 0, localpref 100, valid, external, best
* 1.2.3.4/32 192.168.12.2 0 0 200 i
* 192.168.13.3 0 300 i
*> 192.168.14.4 0 0 300 i
Configure Route-Map
batman#configure terminal
batman(config)#access-list 1 permit 1.2.3.4
batman(config)#route-map MED permit 10
batman(config-route-map)#match ip address 1
batman(config-route-map)#set metric 150
batman(config-route-map)#exit
batman(config)#route-map MED permit 20
batman(config-route-map)#exit
batman(config)#router bgp 200
batman(config-router)#neighbor 192.168.12.1 route-map MED out
superman(config)#access-list 1 permit 1.2.3.4
superman(config)#route-map MED permit 10
superman(config-route-map)#match ip address 1
superman(config-route-map)#set metric 50
superman(config-route-map)#exit
superman(config)#route-map MED permit 20
superman(config-route-map)#exit
superman(config)#router bgp 300
superman(config-router)#neighbor 192.168.14.1 route-map MED out
superman(config-router)#exit
ironman(config)#access-list 1 permit 1.2.3.4
ironman(config)#route-map MED permit 10
ironman(config-route-map)#match ip address 1
ironman(config-route-map)#set metric 50
ironman(config-route-map)#exit
ironman(config)#route-map MED permit 20
ironman(config-route-map)#exit
ironman(config)#router bgp 300
ironman(config-router)#neighbor 192.168.13.1 route-map MED out
ironman(config-router)#exit
* 1.2.3.4/32 192.168.13.3 50 0 300 i
* 192.168.14.4 50 0 300 i
*> 192.168.12.2 150 0 200 i
Its Use Mad Metric To The Best Path
spiderman(config)#router bgp 100
spiderman(config-router)#bgp always-compare-med
spiderman(config-router)#do clear ip bgp *
*Mar 1 00:56:27.611: %BGP-5-ADJCHANGE: neighbor 192.168.12.2 Down User reset
*Mar 1 00:56:27.615: %BGP-5-ADJCHANGE: neighbor 192.168.13.3 Down User reset
*Mar 1 00:56:27.615: %BGP-5-ADJCHANGE: neighbor 192.168.14.4 Down User reset
*Mar 1 00:56:28.443: %BGP-5-ADJCHANGE: neighbor 192.168.12.2 Up
*Mar 1 00:56:28.835: %BGP-5-ADJCHANGE: neighbor 192.168.14.4 Up
*Mar 1 00:56:29.135: %BGP-5-ADJCHANGE: neighbor 192.168.13.3 Up
spiderman(config-router)#do show ip bgp | be 1.2.3.4
*> 1.2.3.4/32 192.168.13.3 50 0 300 i
* 192.168.14.4 50 0 300 i
* 192.168.12.2 150 0 200 i
##########################################################################################################
06 July, 2013
BGP BACKDOOR
BGP BACKDOOR
Configure BGP
HEARTS(config)#router bgp 300
HEARTS(config-router)#neighbor 192.168.13.1 remote-as 100
DIAMONDS#configure terminal
DIAMONDS(config)#router bgp 100
DIAMONDS(config-router)#neighbor 192.168.13.3 remote-as 300
*Mar 1 00:17:23.255: %BGP-5-ADJCHANGE: neighbor 192.168.13.3 Up
DIAMONDS(config-router)#network 1.1.1.0 mask 255.255.255.0
SPADES#ping 1.1.1.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 1.1.1.1, timeout is 2 seconds:
.....
Success rate is 0 percent (0/5)
Fix This
SPADES(config)#router bgp 200
SPADES(config-router)#network 192.168.24.0 mask 255.255.255.0
DIAMONDS(config)#router bgp 100
DIAMONDS(config-router)#network 192.168.13.0 mask 255.255.255.0
Verify:
DIAMONDS#show ip route | inc 2.2.2
B 2.2.2.0 [20/0] via 192.168.13.3, 00:01:06
DIAMONDS#ping 2.2.2.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2.2.2.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 40/63/84 ms
SPADES#show ip route | include 1.1.1
B 1.1.1.0 [20/0] via 192.168.24.4, 00:11:01
SPADES#ping 1.1.1.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 1.1.1.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 48/65/84 ms
DIAMONDS#configure terminal
DIAMONDS(config)#router eigrp 1
DIAMONDS(config-router)#no auto-summary
DIAMONDS(config-router)#network 192.168.12.0 255.255.255.0
DIAMONDS(config-router)#network 1.1.1.1 0.0.0.0
SPADES(config-router)#do show ip eigrp neighbor
IP-EIGRP neighbors for process 1
H Address Interface Hold Uptime SRTT RTO Q Seq
(sec) (ms) Cnt Num
0 192.168.12.1 Fa0/0 10 00:02:47 30 200 0 3
SPADES#traceroute 1.1.1.1
Type escape sequence to abort.
Tracing the route to 1.1.1.1
1 192.168.24.4 44 msec 24 msec 24 msec
2 192.168.34.3 44 msec 36 msec 32 msec
3 192.168.13.1 [AS 100] 64 msec * 56 msec
SPADES#conf ter
SPADES(config)#router bgp 200
SPADES(config-router)#network 1.1.1.0 mask 255.255.255.0 backdoor
DIAMONDS#configure terminal
DIAMONDS(config)#router bgp 100
DIAMONDS(config-router)#network 2.2.2.0 mask 255.255.255.0 backdoor
SPADES#show ip route | include 1.1.1.0
D 1.1.1.0 [90/409600] via 192.168.12.1, 00:03:16, FastEthernet0/0
DIAMONDS#show ip route | include 2.2.2.0
D 2.2.2.0 [90/409600] via 192.168.12.2, 00:12:03, FastEthernet0/0
DIAMONDS#traceroute 2.2.2.2
Type escape sequence to abort.
Tracing the route to 2.2.2.2
1 192.168.12.2 20 msec * 36 msec
SCENARIO:
As a professional poker player you have won the WSOP (World Series of Poker) and now your financial problems are over you decide to start your own online poker room. The bluffing is over it's time to configure your own company network...you have setup your own AS (100) and are connected to a service provider who is using AS 300. You are connecting your network to another big online poker website to exchange network information but you are using EIGRPinstead of BGP to connect AS 100 and 200...the problem you face is that traffic from your AS towards AS 200 is being sent towards AS300 and not using the direct link between router Diamonds and Spades.
GOAL:
- All IP addresses have been preconfigured for you.
- All routers have a loopback interface:
Router Diamonds: L0: 1.1.1.1 /24
Router Spades: L0: 2.2.2.2 /24
Router Hearts: L0: 3.3.3.3 /24
Router Clubs: L0: 4.4.4.4 /24 - Configure EBGP between AS 100 and AS 300.
- Router Diamonds: Advertise the 1.1.1.0 /24 network in BGP.
- Configure IBGP on router Hearts and Clubs.
- Configure EBGP between AS 200 and AS 300.
- Router Diamonds: advertise the 1.1.1.0 /24 network in BGP.
- Router Spades: advertise the 2.2.2.0 /24 network in BGP.
- Ensure you can ping 2.2.2.2 from router Diamonds.
- Ensure you can ping 1.1.1.1 from router Spades.
- If you have any connectivity problems fix them by using next-hop-self or advertising the appropriate networks in BGP. Do not advertise the 192.168.12.X /24 network in any way.
- Configure EIGRP between router Diamonds and Spades:
Advertise the 192.168.12.0 /24 network.
Advertise the 1.1.1.0 /24 network.
Advertise the 2.2.2.0 /24 network.
Disable auto-summary - Ensure you have an EIGRP neighbor relationship between the 2 routers.
- Do a traceroute from router Spades to 1.1.1.1, which path is it taking?
- Use a BGP command to make sure that traffic from router Spades towards 1.1.1.1 is using the 192.168.12.X link and is not being sent through AS 300.
- When the link between router Diamonds and Spades fails it should use AS 300 to reach the 1.1.1.0 /24 network.
- Configure EBGP between AS 100 and AS 300.
HEARTS(config)#router bgp 300
HEARTS(config-router)#neighbor 192.168.13.1 remote-as 100
DIAMONDS#configure terminal
DIAMONDS(config)#router bgp 100
DIAMONDS(config-router)#neighbor 192.168.13.3 remote-as 300
*Mar 1 00:17:23.255: %BGP-5-ADJCHANGE: neighbor 192.168.13.3 Up
- Router Diamonds: Advertise the 1.1.1.0 /24 network in BGP.
- Configure IBGP on router Hearts and Clubs.
CLUBS#configure terminal
CLUBS(config)#router ospf 1
CLUBS(config-router)#network 4.4.4.4 0.0.0.0 area 0
CLUBS(config-router)#network 192.168.34.4 0.0.0.0 area 0
CLUBS(config-router)#router bgp 300
CLUBS(config-router)#neighbor 3.3.3.3 remote-as 300
CLUBS(config-router)#neighbor 3.3.3.3 update-source lo 0
HEARTS#configure terminal
HEARTS(config)#router ospf 1
HEARTS(config-router)#network 3.3.3.3 0.0.0.0 area 0
HEARTS(config-router)#network 192.168.34.3 0.0.0.0 area 0
*Mar 1 00:18:37.491: %OSPF-5-ADJCHG: Process 1, Nbr 4.4.4.4 on FastEthernet0/0 from LOADING to FULL, Loading Done
HEARTS(config-router)#router bgp 300
HEARTS(config-router)#neighbor 4.4.4.4 remote-as 300
HEARTS(config-router)#neighbor 4.4.4.4 update-source lo 0
*Mar 1 00:19:08.123: %BGP-5-ADJCHANGE: neighbor 4.4.4.4 Up
- Configure EBGP between AS 200 and AS 300.
CLUBS#conf terminal
CLUBS(config)#router bgp 300
CLUBS(config-router)#neighbor 192.168.24.2 remote-as 200
SPADES#configure terminal
SPADES(config)#router bgp 200
SPADES(config-router)#neighbor 192.168.24.4 remote-as 300
*Mar 1 00:24:41.475: %BGP-5-ADJCHANGE: neighbor 192.168.24.4 Up
- Router Spades: advertise the 2.2.2.0 /24 network in BGP.
SPADES(config-router)#network 2.2.2.0 mask 255.255.255.0
- Ensure you can ping 2.2.2.2 from router Diamonds.
- Ensure you can ping 1.1.1.1 from router Spades.
- If you have any connectivity problems fix them by using next-hop-self or advertising the appropriate networks in BGP. Do not advertise the 192.168.12.X /24 network in any way.
DIAMONDS#ping 2.2.2.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2.2.2.2, timeout is 2 seconds:
.....
Success rate is 0 percent (0/5)
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 1.1.1.1, timeout is 2 seconds:
.....
Success rate is 0 percent (0/5)
Fix This
SPADES(config)#router bgp 200
SPADES(config-router)#network 192.168.24.0 mask 255.255.255.0
DIAMONDS(config)#router bgp 100
DIAMONDS(config-router)#network 192.168.13.0 mask 255.255.255.0
HEARTS(config)#router bgp 300
HEARTS(config-router)#neighbor 4.4.4.4 next-hop-self
CLUBS(config)#router bgp 300
CLUBS(config-router)#neighbor 3.3.3.3 next-hop-selfVerify:
DIAMONDS#show ip route | inc 2.2.2
B 2.2.2.0 [20/0] via 192.168.13.3, 00:01:06
DIAMONDS#ping 2.2.2.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2.2.2.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 40/63/84 ms
SPADES#show ip route | include 1.1.1
B 1.1.1.0 [20/0] via 192.168.24.4, 00:11:01
SPADES#ping 1.1.1.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 1.1.1.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 48/65/84 ms
- Configure EIGRP between router Diamonds and Spades:
Advertise the 192.168.12.0 /24 network.
Advertise the 1.1.1.0 /24 network.
Advertise the 2.2.2.0 /24 network.
Disable auto-summary
DIAMONDS(config)#router eigrp 1
DIAMONDS(config-router)#no auto-summary
DIAMONDS(config-router)#network 192.168.12.0 255.255.255.0
DIAMONDS(config-router)#network 1.1.1.1 0.0.0.0
SPADES#configure terminal
SPADES(config)#router eigrp 1
SPADES(config-router)#no auto-summary
SPADES(config-router)#network 192.168.12.0 0.0.0.255
*Mar 1 01:45:22.659: %DUAL-5-NBRCHANGE: IP-EIGRP(0) 1: Neighbor 192.168.12.1 (FastEthernet0/0) is up: new adjacency
SPADES(config-router)#network 2.2.2.2 0.0.0.0
- Ensure you have an EIGRP neighbor relationship between the 2 routers.
IP-EIGRP neighbors for process 1
H Address Interface Hold Uptime SRTT RTO Q Seq
(sec) (ms) Cnt Num
0 192.168.12.1 Fa0/0 10 00:02:47 30 200 0 3
- Do a traceroute from router Spades to 1.1.1.1, which path is it taking?
Type escape sequence to abort.
Tracing the route to 1.1.1.1
1 192.168.24.4 44 msec 24 msec 24 msec
2 192.168.34.3 44 msec 36 msec 32 msec
3 192.168.13.1 [AS 100] 64 msec * 56 msec
SPADES#show ip route | include 1.1.1.0
B 1.1.1.0 [20/0] via 192.168.24.4, 00:25:48
DIAMONDS#show ip route | include 2.2.2.0
B 2.2.2.0 [20/0] via 192.168.13.3, 00:25:48
- Use a BGP command to make sure that traffic from router Spades towards 1.1.1.1 is using the 192.168.12.X link and is not being sent through AS 300.
SPADES(config)#router bgp 200
SPADES(config-router)#network 1.1.1.0 mask 255.255.255.0 backdoor
DIAMONDS#configure terminal
DIAMONDS(config)#router bgp 100
DIAMONDS(config-router)#network 2.2.2.0 mask 255.255.255.0 backdoor
D 1.1.1.0 [90/409600] via 192.168.12.1, 00:03:16, FastEthernet0/0
D 2.2.2.0 [90/409600] via 192.168.12.2, 00:12:03, FastEthernet0/0
DIAMONDS#traceroute 2.2.2.2
Type escape sequence to abort.
Tracing the route to 2.2.2.2
1 192.168.12.2 20 msec * 36 msec
- When the link between router Diamonds and Spades fails it should use AS 300 to reach the 1.1.1.0 /24 network.
DIAMONDS#interface fa 0/0
DIAMONDS(config-if)#shutdown
*Mar 1 02:44:17.459: %DUAL-5-NBRCHANGE: IP-EIGRP(0) 1: Neighbor 192.168.12.2 (FastEthernet0/0) is down: interface down
*Mar 1 02:44:19.399: %LINK-5-CHANGED: Interface FastEthernet0/0, changed state to administratively down
*Mar 1 02:44:20.399: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/0, changed state to down
DIAMONDS(config-if)#do show ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route
Gateway of last resort is not set
1.0.0.0/24 is subnetted, 1 subnets
C 1.1.1.0 is directly connected, Loopback0
C 192.168.13.0/24 is directly connected, FastEthernet0/1
2.0.0.0/24 is subnetted, 1 subnets
B 2.2.2.0 [200/0] via 192.168.13.3, 00:00:05
B 192.168.24.0/24 [20/0] via 192.168.13.3, 00:11:17
Backdor Command Sets AD To 200 !!!
DIAMONDS#ping 2.2.2.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2.2.2.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 52/65/84 ms
Success rate is 100 percent (5/5), round-trip min/avg/max = 52/65/84 ms
DIAMONDS#traceroute 2.2.2.2
Type escape sequence to abort.
Tracing the route to 2.2.2.2
1 192.168.13.3 24 msec 24 msec 24 msec
2 192.168.34.4 36 msec 40 msec 36 msec
3 192.168.24.2 [AS 200] 76 msec * 56 msec
##########################################################################################################
Subscribe to:
Posts (Atom)




