Doc: BIRD example update

This commit is contained in:
Ondrej Zajicek (work) 2017-04-26 14:38:19 +02:00
parent 751fb2366c
commit a1de692a69

View file

@ -14,6 +14,15 @@ ipv6 table master6;
ipv4 table mcast4; ipv4 table mcast4;
ipv6 table mcast6; ipv6 table mcast6;
ipv4 table mtab4;
ipv6 table mtab6;
vpn4 table vpntab4;
vpn6 table vpntab6;
vpn4 table vpn4mc;
vpn6 table vpn6mc;
flow4 table flowtab4; flow4 table flowtab4;
flow6 table flowtab6; flow6 table flowtab6;
@ -55,6 +64,25 @@ protocol static static6 {
route 2001:db8:1:1::/64 via fe80::ec9b:67ff:fe60:fd5d % ve1; route 2001:db8:1:1::/64 via fe80::ec9b:67ff:fe60:fd5d % ve1;
} }
# VPNv4 routes with MPLS labels
protocol static statvpn4 {
vpn4;
route 10:10 10.20.0.0/24 via 192.168.1.2 mpls 210;
route 10:10 10.20.1.0/24 via 192.168.1.2 mpls 210;
route 10:20 10.20.0.0/24 via 192.168.1.2 mpls 220;
route 10:20 10.20.1.0/24 via 192.168.1.2 mpls 220;
}
protocol static statvpn6 {
vpn6;
route 10:10 2001:db8:20:10::/64 via 2001:db8:1:1::10 mpls 200/210;
route 10:10 2001:db8:20:11::/64 via 2001:db8:1:1::10 mpls 200/210;
route 10:20 2001:db8:20:10::/64 via 2001:db8:1:1::10 mpls 200/220;
route 10:20 2001:db8:20:11::/64 via 2001:db8:1:1::10 mpls 200/220;
}
# RFC 5575 flow specification # RFC 5575 flow specification
protocol static flowstat4 { protocol static flowstat4 {
flow4; flow4;
@ -70,7 +98,7 @@ protocol static flowstat4 {
length 2048..65535; length 2048..65535;
dscp = 63; dscp = 63;
fragment dont_fragment, is_fragment || !first_fragment; fragment dont_fragment, is_fragment || !first_fragment;
} drop; };
route flow4 { route flow4 {
dst 11.0.0.0/8; dst 11.0.0.0/8;
@ -78,27 +106,27 @@ protocol static flowstat4 {
sport > 0x5678 && < 0x9abc || 0xdef0 || 0x1234,0x5678,0x9abc..0xdef0; sport > 0x5678 && < 0x9abc || 0xdef0 || 0x1234,0x5678,0x9abc..0xdef0;
dport = 50; dport = 50;
tcp flags 0xabcd/0xbbdd; tcp flags 0xabcd/0xbbdd;
} drop; };
route flow4 { route flow4 {
dst 12.0.0.0/32; dst 12.0.0.0/32;
tcp flags ! 0 / 0x9999; tcp flags ! 0 / 0x9999;
} drop; };
route flow4 { route flow4 {
dst 220.0.254.0/24; dst 220.0.254.0/24;
tcp flags 0x99 / 0x9999; tcp flags 0x99 / 0x9999;
} drop; };
route flow4 { route flow4 {
dst 220.0.254.192/28; dst 220.0.254.192/28;
tcp flags !0xffff / 0xFFFF; tcp flags !0xffff / 0xFFFF;
} drop; };
route flow4 { route flow4 {
dst 15.0.0.0/8; dst 15.0.0.0/8;
tcp flags !0x9999/0x9999; tcp flags !0x9999/0x9999;
} drop; };
} }
protocol static flowstat6 { protocol static flowstat6 {
@ -113,7 +141,7 @@ protocol static flowstat6 {
tcp flags 0x03/0x0f, !0/0xff || 0x33/0x33; tcp flags 0x03/0x0f, !0/0xff || 0x33/0x33;
fragment !is_fragment || !first_fragment; fragment !is_fragment || !first_fragment;
label 0xaaaa/0xaaaa && 0x33/0x33; label 0xaaaa/0xaaaa && 0x33/0x33;
} drop; };
route flow6 { route flow6 {
dst fec0:1122:3344:5566::1/128; dst fec0:1122:3344:5566::1/128;
@ -122,7 +150,7 @@ protocol static flowstat6 {
dport = 50; dport = 50;
sport > 24 && < 30 || = 40 || = 50 || = 60 || >= 70 && <= 80; sport > 24 && < 30 || = 40 || = 50 || = 60 || >= 70 && <= 80;
tcp flags 0x3/0x3 && 0x0/0xc; tcp flags 0x3/0x3 && 0x0/0xc;
} drop; };
} }
@ -214,6 +242,52 @@ protocol bgp {
# next hop address 2001:db8:1:1::1; # next hop address 2001:db8:1:1::1;
}; };
# IPv4 with MPLS labels (1/4)
ipv4 mpls {
# explicit IPv4 table
table mtab4;
import all;
export all;
};
# IPv6 with MPLS labels (2/4)
ipv6 multicast {
# explicit IPv6 table
table mtab6;
import all;
export all;
# allows IPv4 next hops (6PE)
# extended next hop;
};
# VPNv4 with MPLS labels (1/128)
vpn4 mpls {
# connects to vpntab4 table by default
import all;
export all;
};
# VPNv6 with MPLS labels (2/128)
vpn6 mpls {
# connects to vpntab6 table by default
import all;
export all;
};
# VPNv4 multicast topology (1/129)
vpn4 multicast {
table vpn4mc;
import all;
export all;
};
# VPNv6 multicast topology (2/129)
vpn6 multicast {
table vpn6mc;
import all;
export all;
};
# IPv4 Flowspec (1/133) # IPv4 Flowspec (1/133)
flow4 { flow4 {
# connects to flowtab4 table by default # connects to flowtab4 table by default