Internet Routing, Ch 26
  1. Where do routing tables come from?
  2. Static routing: Established by the administrator, and is not changed by information from the network itself.
    1. Table may just be stored in a configuration file loaded at boot time. (Rare these days.)
    2. Table may be built with info from DHCP.
    3. Or some combination of these two.
    4. Network-related services may modify the table when they come up or down, but this would still be considered static routing.
      1. Bringing a network interface up or down.
      2. Starting or stopping a VPN service.
    5. Typical case: User machine with just a local net and default router.
    6. Routers connecting a small organization to its ISP may also be able to use static.
  3. Dynamic routing: Routing information propagates, and tables are updated as the network changes.
    1. Routers in the middle of large organizations, or in the middle of the public Internet, need dynamic routing.
    2. Autonomous Systems.
      1. A group of routers under the same administrative authority.
        In practice, a fairly large organization.
      2. A large corporation, ISP, or university.
        Google, Microsoft, Comcast, MIT
      3. Smaller organizations operate as part of their ISP's AS.
        Mississippi College, your house
      4. Very large companies, usually ISPs or other networking organizations, may divide themselves into multiple ASs.
      5. AS's have numbers.
    3. Routing information is spread in a two-level hierarchy.
      1. Within an AS, routing information is spread using an Interior Gateway Protocol (IGP).
        1. Each AS may choose its IGP, or possibly use static routing.
        2. Packets are routed between routers inside the AS.
        3. The protocol tries to pick a good route among the possible ones.
      2. Between AS's, routing information is spread using an Exterior Gateway Protocol (EGP).
        1. All AS's use the same EGP, Border Gateway Protocol (BGP).
        2. Packets are routed between AS's.
        3. Each AS exports only limited information about itself to the EGP.
        4. The protocol attempts to find some route, since it doesn't know enough about AS internals to compare.
  4. Routing Information Protocol (RIP)
    1. An IGP.
    2. Distance vector routing.
    3. Each router maintains a routing table with costs in hops.
    4. It periodically sends this information to its neighbors.
    5. Updates are sent as UDP packets.
      1. In v. 1, updates are broadcast.
      2. In v. 2, multicast is allowed so so only routers need to bother.
    6. A host may use a listen-only version.
    7. Extended version for IP6 addresses.
    8. Packet format
      1. The address family specifies the type of address, pretty much always IP4 (code 2). May also have a special code for extensions.
      2. The tag field distinguishes routes advertised by RIP from routes imported from another IGP or from an EGP.
      3. The packet is basically a copy of the routers routing table.
    9. RFC 2453.
    10. Security.
      1. Original version(s) were easily hackable by spoofing.
      2. Later versons allow routers to send password hashes to authenticate.
      3. Routers configured to know each others passwords; can ignore spoofed RIP messages.
      4. RFC 2082 and RFC 4822.
  5. Open Shortest Path First Protocol (OSPF)
    1. An IGP.
    2. Message are encapsulated directly in hardware packets.
    3. All messages are authenticated.
    4. Routes may be imported from an EGP or other external source.
    5. Uses broadcast to find neighbors (Hello protocol), but not to send routing data.
    6. Uses link-state rather than distance-vector.
      1. Each router is configured with a graph of the network, with link costs set administratively.
      2. Routers find the state of their interfaces and adjacent routers, and share with other routers.
      3. Each router can compute the shortest path to a destination locally using its graph plus the received state information.
    7. Network may be organized into a hierarchy.
      1. The network is divided into blocks of adjacent routers, called areas.
      2. Routers in an area send status updates to each other router in its area.
      3. Routers on the edges of areas, with connections to each, maintain state information for each area separately. These are called Area Border Routers, since they can move packets into or out of an area.
      4. The ABRs and other non-area routers form the backbone, which is treated as a special area.
      5. Routes within an area are computed by its routers.
      6. Packets between areas are routed to the backbone, through the backbone, then within the destination area.
    8. Areas reduce traffic, since routers in different areas don't need to update each other.
    9. RFC 2328 and Cisco wiki entry..
  6. IS-IS
    1. A protocol similar to OSPF, originally proprietary to Digital Equipment Corporation (DEC).
    2. Grew up together and shared many ideas.
    3. Eventually, DEC dissolved, and an IP version was defined.
    4. Largely unused for a long time while OSPF was used broadly, thereby accumulating crud. Now experiencing new interest because it is simpler and scales better.
  7. BGP
    1. Describes routes between ASs. Routes are from, to and through ASs, not routers.
    2. The administrators of an AS decide which routers
      1. will accept traffic from outside to a destination inside,
      2. will send traffic out of the AS,
      3. will accept outside traffic going through the AS and out another way.
    3. An AS is thereby classified as transit (will route traffic through) or stub (can or will not).
    4. These routers run the BGP. They communicate with other such routers in adjacent AS's.
    5. Communications is over TCP connections.
    6. A BGP reports to its neighbors
      1. Routes to or through its own AS that it is configured to report.
      2. Routes to other destinations that it builds with info from other routers.
      3. These routes link ASs; no AS internal information is transmitted.
    7. BGP uses some rules to choose relatively better routes, but it does not have enough information to determine an optimal route.
  8. Multicast.
    1. IP has always allowed for multicast.
      1. Not widely used in the internet as a whole.
      2. Sometimes used within an organization.
    2. Routing is difficult.
      1. Have to find all the recipients, which could be anywhere.
      2. Nodes which are not recipients can still send to one.
      3. Nodes can come and go at any time.
    3. Internet Group Message Protocol (IGMP) defines messages to control group membership.
    4. A host sends an IGMP message to a standard multicast address to join or leave a group.
    5. No established standard to determine routing. Three main approaches
      1. Flood-and-prune
        1. Used on LANs.
        2. When a multicast packet arrives, send it to all other destinations. To avoid cycles, packets are only forwarded away from the source node, according to the regular unicast routing table.
        3. If a router finds that no recipient actually wants the packets, it informs the upstream.
        4. The upstream will quit forwarding. If all its downstream don't want the packet either, it will notify its sender. Thus the tree is pruned.
      2. Configuration-and-tunneling
        1. Used to connect remote LANs.
        2. A router on each LAN is configured to know about the others.
        3. Uses hardware multicast locally, and tunnels for the router to each other site with needs it.
      3. Core-Based Discovery.
        1. Can be used for larger scale.
        2. Designate a core unicast router.
        3. Send a membership request to the core. Each router that passes it adds a multicast routing entry back to the sender.
        4. When reaching a router that is already participating, the sender is connected.
        5. When a non-participant sends to the multicast address, send to the core. When it first reaches a participating router, it is multicast from there.
    6. Protocols
      1. Distance Vector Multicast Routing Protocol (DVMRP).
        1. Used by former MBONE.
        2. Broadcasts locally, uses distance-vector to find routes between participating localities.
      2. Core Based Trees (CBT). Application of Core-based discovery.
      3. Protocol Independent Multicast — Sparse Mode (PIM-SM). Variation on CBT.
      4. Protocol Independent Multicast — Dense Mode (PIM-DM).
        1. For local areas.
        2. An application of flood-and-prune.
      5. Multicast Extensions to the Open Shortest Path First Protocol (MOSPF). Uses link-state like OSPF, so the multicast graph is essentially constructed by the administrator.