Subject: [Idr] RFC7752 : Decoding BGP-LS Link Protection Type TLV (1093) for OSPFv2

From: Mamud Hasan <[email-masked]>
Date: Fri, 23 Sep 2016 16:06:26 +0530

Respected Sir,
I was just go-through this specification and having doubt about decoding of
BGP-LS "Link Protection Type TLV (1093)" for carrying OSPFv2 Link
Protection Type value.

*According to this RFC7752,*

3.3.2.  Link Attribute TLVs

   Link Attribute TLVs are TLVs that may be encoded in the BGP-LS

   attribute with a Link NLRI.  Each 'Link Attribute' is a Type/Length/

   Value (TLV) triplet formatted as defined in Section 3.1.  The format

   and semantics of the Value fields in some Link Attribute TLVs

   correspond to the format and semantics of the Value fields in IS-IS

   Extended IS Reachability sub-TLVs, defined in [RFC5305] and

   [RFC5307].  *Other Link Attribute TLVs are defined in this document.*

*   Although the encodings for Link Attribute TLVs were originally*

*   defined for IS-IS, the TLVs can carry data sourced by either IS-IS or*

*   OSPF.*

BGP-LS Link Protection Type TLV

+++++++++++++++++++++++++++++++++++

   +-----------+---------------------+--------------+------------------------------+

   |  TLV Code | Description         |  IS-IS TLV     | Reference            |

   |   Point       |                               |   /Sub-TLV   |
(RFC/Section)      |

   +-----------+---------------------+--------------+-------------------------------+

   |1093       | Link Protection     |    22/20     | [RFC5307]/1.2         |

   |                 | Type                      |
|                                    |

   ------------------------------------------------------------------------------------

We can see above that For BGP-LS Link Protection Type (1093), it
follows references of *ISIS (RFC 5307) only*. But Link Protection
Decoding for ISIS and OSPF is not same (as shown below). For OSPFv2
there are extra 3 octet reserved field.

ISIS Link Protection Type Decoding: (rfc5307)

+++++++++++++++++++++++++++++++++++

   0                   1

       0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5

      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

      |Protection Cap |    Reserved     |

      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

 OSPF Link Protection Type Decoding: (rfc4203)

+++++++++++++++++++++++++++++++++++

     0                       1                                 2
                         3

    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1

   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   |Protection Cap |                    Reserved
                       |

   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

So my question is, what could be the coding of BGP-LS Link Protection
Type TLV (1093) for OSPFv2 ? Should it consider the extra 3 octet
reserved field and carry these reserved field value in this TLV ?

I will be grateful if receive response.

Thanks,

Mamud