summaryrefslogtreecommitdiffstats
path: root/tests/topotests/bgp_remove_private_as/r1/bgpd.conf
blob: 99536892bb2ecbc8dc10e8e3392972b94c0f052f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
router bgp 65001
 bgp router-id 192.0.2.1
 no bgp network import-check
 neighbor 203.0.113.1 remote-as 65002
 neighbor 203.0.113.1 description r2
 neighbor 203.0.113.1 timers 3 10
 neighbor 203.0.113.3 remote-as 5555
 neighbor 203.0.113.3 description r5
 neighbor 203.0.113.3 timers 3 10
!
 address-family ipv4 unicast
  network 100.64.0.0/32
  network 100.64.0.1/32
  network 100.64.0.2/32
  network 100.64.0.3/32
  network 100.64.0.4/32
  network 100.64.0.5/32
  neighbor 203.0.113.1 route-map set-as-paths out
  neighbor 203.0.113.3 route-map set-as-paths out
 exit-address-family
!
ip prefix-list match-0 seq 5 permit 100.64.0.0/32
ip prefix-list match-1 seq 5 permit 100.64.0.1/32
ip prefix-list match-2 seq 5 permit 100.64.0.2/32
ip prefix-list match-3 seq 5 permit 100.64.0.3/32
ip prefix-list match-4 seq 5 permit 100.64.0.4/32
!
! all private
! at r3/r4, as-path should only have r2's asn
route-map set-as-paths permit 10
 match ip address prefix-list match-0
 set as-path prepend 4200000000 4200000001 4200000002
!
! all private, include r3's asn 
! at r3/r4, as-path should only have r2's asn
route-map set-as-paths permit 20
 match ip address prefix-list match-1
 set as-path prepend 65003 4200000000 4200000001 4200000002 65003
!
! mix of private/public
route-map set-as-paths permit 30
 match ip address prefix-list match-2
 set as-path prepend 4200000000 1000 4200000001 2000 4200000002
!
! mix of private/public, include r3's asn multiple times
route-map set-as-paths permit 40
 match ip address prefix-list match-3
 set as-path prepend 65003 4200000000 1000 4200000001 2000 4200000002 65003
!
! all public
route-map set-as-paths permit 50
 match ip address prefix-list match-4
 set as-path prepend 1000 2000 2000 3000