Project

General

Profile

LSDB DataSet » History » Revision 16

Revision 15 (Alexander Lane, 04/29/2025 08:15 PM) → Revision 16/17 (Davide Pesavento, 05/09/2025 04:56 PM)

# LSA TLV encoding for NLSR-to-NLSR and NLSR-to-NLSRC (LSDB DataSet) communication 

 LSDB datasets are published in the namespace `/$ROUTER_NAME/lsdb` `/$ROUTER_NAME/lsdb/` and `/localhost/lsdb`. `/localhost/lsdb`: 

 ## LSAs 

 All LSAs have 3 fields in common represented by an **LsaInfo** block: 

     LsaInfo := LSA-TYPE TLV-LENGTH 
                  Name 
                  SequenceNumber 
                  ExpirationTime 

     SequenceNumber := SEQUENCE-NUMBER-TYPE TLV-LENGTH 
                         NonNegativeInteger nonNegativeInteger 

 ExpirationTime(Point) is the time according to the sender when the LSA will expire. 

 ## Adjacency LSAs 

 All Adjacency LSAs in the LSDB are published as a [[NFD:StatusDataset|Status Dataset]] at `/$ROUTER_NAME/lsdb/adjacencies` 
 and `/localhost/lsdb/adjacencies`. `/localhost/lsdb/adjacencies` 

     AdjacencyLsa := ADJACENCY-LSA-TYPE TLV-LENGTH 
                       LsaInfo 
                       Adjacency+ 

     Adjacency := ADJACENCY-TYPE TLV-LENGTH 
                    Name 
                    Uri 
                    Cost 

 ## Coordinate LSAs 

 All Coordinate LSAs in the LSDB are published as a [[NFD:StatusDataset|Status Dataset]] at `/$ROUTER_NAME/lsdb/coordinates` 
 and `/localhost/lsdb/coordinates`. `/localhost/lsdb/coordinates` 

     CoordinateLsa := COORDINATE-LSA-TYPE TLV-LENGTH 
                        LsaInfo 
                        HyperbolicRadius 
                        HyperbolicAngle+ 

     Double := DOUBLE-TYPE TLV-LENGTH(=8) 
                 double-precision floating-point number in binary64 format as defined in IEEE 754 


     HyperbolicRadius := HYPERBOLIC-RADIUS-TYPE TLV-LENGTH 
                           Double                       

     HyperbolicAngle := HYPERBOLIC-ANGLE-TYPE TLV-LENGTH 
                          Double 

 ## Name LSAs 

 All Name LSAs in the LSDB are published as a [[NFD:StatusDataset|Status Dataset]] at `/$ROUTER_NAME/lsdb/names` 
 and `/localhost/lsdb/names`. `/localhost/lsdb/names` 

     NameLsa      := NAME-LSA-TYPE TLV-LENGTH 
                     
                  LsaInfo 
                     
                  PrefixInfo* 

     PrefixInfo := PREFIX-INFO-TYPE TLV-LENGTH 
                     
                  Name 
                     
                  Cost 

 ## TLV-TYPE assignments 

 Type                                          | Assigned value      | Assigned value (hex) 
 ------------------------------------------- | ----------------- | -------------------- 
 LsaInfo                                       | 128                 | 0x80 
 SequenceNumber                                | 130                 | 0x82 
 AdjacencyLsa                                  | 131                 | 0x83 
 Adjacency                                     | 132                 | 0x84 
 CoordinateLsa                                 | 133                 | 0x85 
 Double                                        | 134                 | 0x86 
 HyperbolicRadius                              | 135                 | 0x87 
 HyperbolicAngle                               | 136                 | 0x88 
 NameLsa                                       | 137                 | 0x89 
 LsdbStatus                                    | 138                 | 0x8A 
 ExpirationTime                                | 139                 | 0x8B 
 Cost                                          | 140                 | 0x8C 
 Uri                                           | 141                 | 0x8D 
 PrefixInfo                                    | 146                 | 0x92 

 See [[Routing_Table_Dataset|Routing (See Routing Table Dataset]] Dataset for other assignments. assignments: https://redmine.named-data.net/projects/nlsr/wiki/Routing_Table_Dataset)