Context: each router is connected to some finite number of other routers
RIB: Routing Information Base
Inputs:
Static routes (configured in text files)
iBGP
eBGP
OSPF
Output to Control Plane (software, in memory)
Routes are organized by prefix
e.g. 103.127.54.0/24
Can have a different route via each of the input types; there is a priority ordering between source for a route
Radix tree of paths to a prefix
Next hop router chosen by lookup prefix in the radix tree
ASNs: an array [ASNa, ASNb, ..., ASN_origin]
Origin AS should be consistent; only one AS should be advertising the prefix
Can add your own AS multiple times in the path to inflate length of the advertised path; this biases against a packet being sent down that path
FIB: Forwarding Information Base
Note: In Proj1 the FIB is the Linux kernel
Hardware FIB: RIB has information for next hop; this is used by FIB to take a prefix and send the packet out to a physical port corresponding to the next hop