Contents of Routing Tables
The routing table consists of at least three information fields:
- the network id: i.e. the destination network id
- cost: i.e. the cost or metric of the path through which the packet is to be sent
- next hop: The next hop, or gateway, is the address of the next station to which the packet is to be sent on the way to its final destination
Depending on the application and implementation, it can also contain additional values that refine path selection:
- quality of service associated with the route. For example, the U flag indicates that an IP route is up.
- links to filtering criteria/access lists associated with the route
- interface: such as eth0 for the first Ethernet card, eth1 for the second Ethernet card, etc.
Routing tables are also a key aspect of certain security operations, such as unicast reverse path forwarding (uRPF). In this technique, which has several variants, the router also looks up, in the routing table, the source address of the packet. If there exists no route back to the source address, the packet is assumed to be malformed or involved in a network attack, and is dropped.
Network id | Cost | Next hop |
---|---|---|
........ | ........ | ........ |
........ | ........ | ........ |
Shown below is an example of what the table above could look like on an average computer connected to the internet via a home router:
Network Destination | Netmask | Gateway | Interface | Metric |
---|---|---|---|---|
0.0.0.0 | 0.0.0.0 | 192.168.0.1 | 192.168.0.100 | 10 |
127.0.0.0 | 255.0.0.0 | 127.0.0.1 | 127.0.0.1 | 1 |
192.168.0.0 | 255.255.255.0 | 192.168.0.100 | 192.168.0.100 | 10 |
192.168.0.100 | 255.255.255.255 | 127.0.0.1 | 127.0.0.1 | 10 |
192.168.0.255 | 255.255.255.255 | 192.168.0.100 | 192.168.0.100 | 10 |
- The columns Network Destination and Netmask together describe the Network id as mentioned earlier. For example, destination 192.168.0.0 and netmask 255.255.255.0 can be written as network id 192.168.0.0/24.
- The Gateway column contains the same information as the Next hop, i. e. it points to the gateway through which the network can be reached.
- The Interface indicates what locally available interface is responsible for reaching the gateway. In this example, gateway 192.168.0.1 (the internet router) can be reached through the local network card with address 192.168.0.100.
- Finally, the Metric indicates the associated cost of using the indicated route. This is useful for determining the efficiency of a certain route from two points in a network. In this example, it is more efficient to communicate with the computer itself through the use of address 127.0.0.1 (called “localhost”) than it would be through 192.168.0.100 (the IP address of the local network card).
Read more about this topic: Routing Table
Famous quotes containing the words contents of, contents and/or tables:
“Conversation ... is like the table of contents of a dull book.... All the greatest subjects of human thought are proudly displayed in it. Listen to it for three minutes, and you ask yourself which is more striking, the emphasis of the speaker or his shocking ignorance.”
—Stendhal [Marie Henri Beyle] (17831842)
“Yet to speak of the whole world as metaphor
Is still to stick to the contents of the mind
And the desire to believe in a metaphor.
It is to stick to the nicer knowledge of
Belief, that what it believes in is not true.”
—Wallace Stevens (18791955)
“Eddie Felson: Church of the Good Hustler.
Charlie: Looks more like a morgue to me. Those tables are the slabs they lay the stiffs on.
Eddie Felson: Ill be alive when I get out, Charlie.”
—Sydney Carroll, U.S. screenwriter, and Robert Rossen. Eddie Felson (Paul Newman)