Session 3: OSPF and IGRP Flashcards
Is OSPF an interior or exterior gateway protocol? Also, what is the difference between the two?
Open Shortest Path First (OSPF) is the most commonly used Interior Gateway (IG) protocol today. IG is used inside an organization, while EG is used to connect organizations together.
What is Open Shortest Path First (OSPF) and how does it work?
OSPF is a simple and fast protocol which implements the Dijkstra algorithm. It is a fast and simple protocol which consists of a number of logical steps which are executed for each link state change or initialization.
1) At initialization it floods its link state information to all neighbors.
2) Each router collects all link state information and places it in local topology database
3) Run Dijkstra’s algorithm on database to find shortest path
4) From the shortest paths, a tree can be created which gives the routing table. This will be updated for each link state change
Link state changes are advertised using link state change advertisement (LSA) using a sequence number. These are also sent periodically to advertise that the node is still alive.
In addition the protocol also keeps track of link state age, which means a link will be considered dead if not heard from in a while.
What are the 4 possible outcomes for a received link state advertisement (LSA) with sequence number q sent by router Y?
I will look at my local table, checking if q is already present in my table.
1) If information where sequence number = q is already present in my table, this LSA is ignored as it means that I already have this information.
2) If no entry is present at all, add this entry as it must be a new node and propagate this information to neighbors except for Y.
3) If an entry is already present but with a lower sequence number, update local entry and propagate to neighbors except for Y.
4) If a local entry is present with a higher sequence number, send local entry back to Y, telling it that it has outdated information.
How is OSPF implemented in large networks?
As OSPF is a chatty protocol, it would be inefficient to always send all the LSAs to all possible nodes. For this reason, hierarchies can be created by using areas. Area 0 must always exist, and it is considered as the logical backbone for the network. The different areas are then self-contained and identified by a unique 32-bit ID. This results in 4 types of routers: internal, area border, backbone and AS boundary routers.
What are the five OSPF packets?
Type 1 - Hello: Exchange distance information
Type 2 - Database description packet (DBD): Allows for full self-database dump to a neighbor
Type 3 - Link-state-request (LSR): Request specific pieces of information from database
Type 4 - Link-state-update(LSU): transports LSA to neighbor routers
Type 5 - Link-state acknowledgement (LSAck): Acknowledges received LSA
What are the three authentication possibilities in the OSPF protocol?
Type 0: Null authentication (default)
Type 1: Password based, limited by the 64-bit field length in the OSPF header. Password is propagated in clear text. Simple packet sniffing defeats this, as password will be captured in clear text.
Type 2: Cryptographic authentication: Relies on a hared key and MD5 calculation. MD5 is pretty easy to crack these days…
Name two popular security mechanism in OSPF.
The fight-back mechanism makes safeguards against a number of attacks. What this does is if a router Y receives an LSA stating it is from itself, router Y will immediately advertise it’s actual LSA cancelling the fake one. Unfortunately this mechanism might lead to instability and hence DoS.
Another possible security mechanism is a check which makes sure that only bidirectionally advertised link is included in routing table calculations.
Name two possible attacks on OSPF.
1) Race attack. Here an attacker takes advantage of the fact that timestamps can differ by up to 15 minutes. This means that hehe can capture an LSA, and replay these to routers. In this case the routers where the genuine LSA was already received will treat this as a duplicate without triggering the fight-back. Routers where the genuine LSA was not received yet will become poisoned.
2) MaxAge attack. In this attack, an attacker can modify the age field in the LSA which is supposed to be decremented by 1 for each hop to a value near MaxAge. This means that not all routers will get this LSA, thus leading to routers losing routes. When this modified LSA reaches the victim the fight-back mechanism activates.