Destination-based forwarding

Forwarding is based on destination address ranges. However, it may happen that ranges do not divide so nicely. Then … apply Longest Prefix Matching. When looking for forwarding table entry for given destination address, use longest address prefix that matches destination address.

Destination Address Range

Link interface

11001000 00010111 00010*** ********

0

11001000 00010111 00011000 ********

1

11001000 00010111 00011*** ********

2

Otherwise

3

The table above shows four destination address ranges. The first three ranges share the first twenty bits. The twenty first bit is the same for the second and third entries. However, the second entry is followed by wildcards and the third one is followed by three bits and then wildcards. The fourth entry is otherwise, which means that if a destination address does not match any prefix, this is the selected entry. In the example, a destination address matches the second and third entries, but the coincidence extends three more bits in the third entry. Thus, this is the final selection.

Question

Which interface will be selected in the router?

Destination addresses
Check answer
Project

  • University of Boras logo
  • UHI logo
  • Alcala University logo
  • Digital connextions logo

This resource was developed as part of an Erasmus+ project, funded with support from the European Commission under grant agreement 2016-1-SE01-KA203-22064.

The project was a collaboration between:

  Creative Commons License

This resource has been released under Creative Commons license CC-BY-SA 4.0.

Contact

  • University of Boras logo
  • UHI logo
  • Alcala University logo
  • Digital connextions logo

If you would like more information on this resource please contact:

  • Academic content – The University of Alcalá (https://www.uah.es/en/)
  • Technical resource development – The University of the Highlands and Islands Educational Development Unit - EDU (edu@uhi.ac.uk)
Disclaimer

  • University of Boras logo
  • UHI logo
  • Alcala University logo
  • Digital connextions logo

Except where otherwise noted, this website is licensed under Creative Commons license CC-BY-SA 4.0. All images used under permission remain the copyright of the license holder.

PDF

  • University of Boras logo
  • UHI logo
  • Alcala University logo
  • Digital connextions logo

Download a copy of this resource in PDF format.

You can also print individual pages by printing directly from the browser.

×