Skip to main content

OSPF - Part 5: Analysis of OSPF Link State Update (LSU) - Link State Advertisement (LSA) Packet Structure. Common LSA Types

This article explains how OSPF uses Link State Advertisement (LSA) to exchange information about the network topology between routers. When a router receives an LSA, it is stored in the Link-State DataBase (LSDB). Once the LSDBs between routers are in sync, OSPF uses the Shortest Path First (SPF) algorithm to calculate the best routes for each network. It is important to understand that LSAs are information about a route that is transported inside Link State Update (LSU) packets.

Each single Link State Update (LSU) packet can contain one or more LSAs inside it and when an LSU is sent between OSPF routers, it floods the LSA information through the network.

Below is a complete list of articles covering our OSPF Series:

- Part 5 (This article): Analysis of OSPF Link State Update (LSU) - Link State Advertisement (LSA) Packet Structure. Common LSA Types.

It is very important for any network engineer to understand how LSAs are contained within an LSU. We’ll use the example below, where an OSPF router sends an LSU to the OSPF Designated Router (DR) containing LSA information about a new network:

OSPF Link State Update (LSU) packet containing a Link State Advertisement (LSA)

Figure 1. OSPF Link State Multicast Update (LSU) packet containing a Link State Advertisement (LSA)

As shown above, LSAs are contained within LSUs, which are all part of an OSPF packet encapsulated within an Ethernet frame (assuming an Ethernet network).

Our diagram of the LSU/LSA packet structure is confirmed by capturing an OSPF Ethernet frame below. We’ve highlighted each section (LSA, LSU, OSPF Header) using the same colors:

OSPF Link State Update and List State Advertisement within an Ethernet frame

Figure 2. OSPF Link State Update and List State Advertisement within an Ethernet frame

Notice that the destination IP address is multicast address 224.0.0.6, as expected since routers send updates to the Designated Router (DR) using this multicast address. This is also analyzed under the Working Inside a Single Area section in our article How OSPF Protocol Works & Basic Concepts: OSPF Neighbor, Topology & Routing Table, OSPF Areas & Router Roles, Theory & Overview

Most Popular OSPF LSA Types

OSPF currently defines 11 different LSA types, however, despite the large variety of LSAs only around half of them are commonly found in OSPF networks. Table 1 below shows the most popular LSA types, the type of OSPF routers (DR, ABR, ASBR etc) that generate them along with their function and the OSPF areas they affect:

LSA

Generated by

Function

Flooding Map

Type 1

Normal Area Routers

Advertising router's interface
and status to neighbors

Intra-Area
(Area of origin)

Type 2

DR

Advertising DRs direct
connected neighbors

Intra-Area
(Area of origin)

Type 3

ABR

Advertising ABRs areas
summary

Inter-Area
(Multiple Areas)

Type 4

ABR

Advertising the presence
of ASBRs

Inter-Area
(Multiple Areas)

Type 5

ASBR

Advertising external routes
to internet

Inter-Area
(Multiple Areas)

Type 7

ASBR

Advertising external routes
to internet to NSSA areas

Inter-Area
(Multiple Areas)

Table 1. Most often used LSA Types, router origin type, their function and Areas affected

Looking at the OSPF packet captured with our network analyzer, we can now understand that the specific LSA was a Type-3 LSA (LS Type: Summary-LSA IP network 3) which means it was generated by an ABR OSPF router.

Link State Advertisement (LSA) Packet Structure (Within a Link State Update - LSU)

Each LSA packet consists of a header and a body that contains all the information needed to exchange network information within an OSPF network. The diagram below shows the structure of an OSPF LSA packet:

OSPF LSA Packet structure and fields

Figure 3. OSPF LSA Packet structure and fields

The LSA header is a 20 byte (32x5 = 160 bits) section that consists of the following fields:

  • LS Age (2 Bytes): Time passed since the LSA was generated (in seconds).
  • Options (1 Byte): Indicates the OSPF features and options the origin can support.
  • LS Type (1 Byte): Defines the LSA type (all types will be explained later).
  • Link State ID (4 Bytes): Identifies the network link between OSPF routers (usually IP address).
  • Advertising Router (4 Bytes): Indicates the origin router’s ID.
  • LS Sequence Number (4 Bytes): A specific digit on each LSA packet to filter old and repeated
  • LS Checksum (2 Bytes): A certain digit given to LS to compare and detect errors.
  • Length (2 Bytes): Represents LSA packet length.

The LSA body varies in size according to the LS type and the details it identifies, LSA types are explained in great detail in our upcoming article.

This article explained OSPF Link State Update (LSA) packets and showed how they contain Link State Advertisements (LSAs). We also analyzed OSPF LSU & LSAs packet structure and explained each field in an OSPF LSA packet. Finally, we spoke about the most common LSA Types, router origin type (ABR, ASBR, DR etc), their function and Areas affected. Read more on OSPF by visiting any of the below articles:

- Part 5 - (This article) Analysis of OSPF Link State Update (LSU) - Link State Advertisement (LSA) Packet Structure. Common LSA Types 

Your IP address:

18.227.183.204

All-in-one protection for Microsoft 365

All-in-one protection for Microsoft 365

FREE Hyper-V & VMware Backup

FREE Hyper-V & VMware Backup

Wi-Fi Key Generator

Generate/Crack any
WEP, WPA, WPA2 Key!

Network and Server Monitoring

Network and Server Monitoring

Follow Firewall.cx

Cisco Password Crack

Decrypt Cisco Type-7 Passwords on the fly!

Decrypt Now!

Bandwidth Monitor

Zoho Netflow Analyzer Free Download

Free PatchManager

Free PatchManager

EventLog Analyzer

ManageEngine Eventlog Analyzer

Security Podcast

Hornet-Security-The-Swarm-Podcast

Firewall Analyzer

zoho firewall analyzer