idnits 2.17.1 draft-ietf-ospf-ospfv3-segment-routing-extensions-20.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (December 3, 2018) is 1969 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) == Unused Reference: 'ALGOREG' is defined on line 827, but no explicit reference was found in the text == Unused Reference: 'I-D.ietf-spring-segment-routing-mpls' is defined on line 842, but no explicit reference was found in the text -- Possible downref: Non-RFC (?) normative reference: ref. 'ALGOREG' == Outdated reference: A later version (-27) exists of draft-ietf-ospf-segment-routing-extensions-26 == Outdated reference: A later version (-22) exists of draft-ietf-spring-segment-routing-mpls-16 Summary: 0 errors (**), 0 flaws (~~), 5 warnings (==), 2 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Open Shortest Path First IGP P. Psenak, Ed. 3 Internet-Draft Cisco Systems, Inc. 4 Intended status: Standards Track S. Previdi, Ed. 5 Expires: June 6, 2019 Individual 6 December 3, 2018 8 OSPFv3 Extensions for Segment Routing 9 draft-ietf-ospf-ospfv3-segment-routing-extensions-20 11 Abstract 13 Segment Routing (SR) allows a flexible definition of end-to-end paths 14 within IGP topologies by encoding paths as sequences of topological 15 sub-paths, called "segments". These segments are advertised by the 16 link-state routing protocols (IS-IS and OSPF). 18 This draft describes the OSPFv3 extensions required for Segment 19 Routing with MPLS data plane. 21 Requirements Language 23 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 24 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 25 document are to be interpreted as described in [RFC2119]. 27 Status of This Memo 29 This Internet-Draft is submitted in full conformance with the 30 provisions of BCP 78 and BCP 79. 32 Internet-Drafts are working documents of the Internet Engineering 33 Task Force (IETF). Note that other groups may also distribute 34 working documents as Internet-Drafts. The list of current Internet- 35 Drafts is at https://datatracker.ietf.org/drafts/current/. 37 Internet-Drafts are draft documents valid for a maximum of six months 38 and may be updated, replaced, or obsoleted by other documents at any 39 time. It is inappropriate to use Internet-Drafts as reference 40 material or to cite them other than as "work in progress." 42 This Internet-Draft will expire on June 6, 2019. 44 Copyright Notice 46 Copyright (c) 2018 IETF Trust and the persons identified as the 47 document authors. All rights reserved. 49 This document is subject to BCP 78 and the IETF Trust's Legal 50 Provisions Relating to IETF Documents 51 (https://trustee.ietf.org/license-info) in effect on the date of 52 publication of this document. Please review these documents 53 carefully, as they describe your rights and restrictions with respect 54 to this document. Code Components extracted from this document must 55 include Simplified BSD License text as described in Section 4.e of 56 the Trust Legal Provisions and are provided without warranty as 57 described in the Simplified BSD License. 59 Table of Contents 61 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 62 2. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 3 63 3. Segment Routing Identifiers . . . . . . . . . . . . . . . . . 4 64 3.1. SID/Label Sub-TLV . . . . . . . . . . . . . . . . . . . . 4 65 4. Segment Routing Capabilities . . . . . . . . . . . . . . . . 4 66 5. OSPFv3 Extended Prefix Range TLV . . . . . . . . . . . . . . 5 67 6. Prefix SID Sub-TLV . . . . . . . . . . . . . . . . . . . . . 7 68 7. Adjacency Segment Identifier (Adj-SID) . . . . . . . . . . . 10 69 7.1. Adj-SID Sub-TLV . . . . . . . . . . . . . . . . . . . . . 11 70 7.2. LAN Adj-SID Sub-TLV . . . . . . . . . . . . . . . . . . . 12 71 8. Elements of Procedure . . . . . . . . . . . . . . . . . . . . 13 72 8.1. Intra-area Segment routing in OSPFv3 . . . . . . . . . . 13 73 8.2. Inter-area Segment routing in OSPFv3 . . . . . . . . . . 14 74 8.3. Segment Routing for External Prefixes . . . . . . . . . . 15 75 8.4. Advertisement of Adj-SID . . . . . . . . . . . . . . . . 16 76 8.4.1. Advertisement of Adj-SID on Point-to-Point Links . . 16 77 8.4.2. Adjacency SID on Broadcast or NBMA Interfaces . . . . 16 78 9. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 16 79 9.1. OSPFv3 Extended-LSA TLV Registry . . . . . . . . . . . . 16 80 9.2. OSPFv3 Extended-LSA Sub-TLV registry . . . . . . . . . . 16 81 10. Security Considerations . . . . . . . . . . . . . . . . . . . 17 82 11. Contributors . . . . . . . . . . . . . . . . . . . . . . . . 17 83 12. References . . . . . . . . . . . . . . . . . . . . . . . . . 18 84 12.1. Normative References . . . . . . . . . . . . . . . . . . 18 85 12.2. Informative References . . . . . . . . . . . . . . . . . 20 86 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 20 88 1. Introduction 90 Segment Routing (SR) allows a flexible definition of end-to-end paths 91 within IGP topologies by encoding paths as sequences of topological 92 sub-paths, called "segments". These segments are advertised by the 93 link-state routing protocols (IS-IS and OSPF). Prefix segments 94 represent an ECMP-aware shortest-path to a prefix (or a node), as per 95 the state of the IGP topology. Adjacency segments represent a hop 96 over a specific adjacency between two nodes in the IGP. A prefix 97 segment is typically a multi-hop path while an adjacency segment, in 98 most cases, is a one-hop path. SR's control-plane can be applied to 99 both IPv6 and MPLS data-planes, and does not require any additional 100 signalling (other than IGP extensions). The IPv6 data plane is out 101 of the scope of this specification - OSPFv3 extension for SR with 102 IPv6 data plane will be specified in a separate document. When used 103 in MPLS networks, SR paths do not require any LDP or RSVP-TE 104 signalling. However, SR can interoperate in the presence of LSPs 105 established with RSVP or LDP. 107 There are additional segment types, e.g., Binding SID defined in 108 [RFC8402]. 110 This draft describes the OSPFv3 extensions required for Segment 111 Routing with MPLS data plane. 113 Segment Routing architecture is described in [RFC8402]. 115 Segment Routing use cases are described in [RFC7855]. 117 2. Terminology 119 This section lists some of the terminology used in this document: 121 ABR - Area Border Router 123 Adj-SID - Adjacency Segment Identifier 125 AS - Autonomous System 127 ASBR - Autonomous System Boundary Router 129 IS-IS - Intermediate System to Intermediate System 131 LDP - Label Distribution Protocol 133 LSP - Label Switched Path 135 MPLS - Multi Protocol Label Switching 137 OSPF - Open Shortest Path First 139 SPF - Shortest Path First 141 RSVP - Resource Reservation Protocol 143 SID - Segment Identifier 144 SR - Segment Routing 146 SRGB - Segment Routing Global Block 148 SRLB - Segment Routing Local Block 150 SRMS - Segment Routing Mapping Server 152 TLV - Type Length Value 154 3. Segment Routing Identifiers 156 Segment Routing defines various types of Segment Identifiers (SIDs): 157 Prefix-SID, Adjacency-SID, LAN Adjacency SID, and Binding SID. 159 3.1. SID/Label Sub-TLV 161 The SID/Label Sub-TLV appears in multiple TLVs or Sub-TLVs defined 162 later in this document. It is used to advertise the SID or label 163 associated with a prefix or adjacency. The SID/Label Sub-TLV has 164 following format: 166 0 1 2 3 167 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 168 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 169 | Type | Length | 170 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 171 | SID/Label (variable) | 172 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 174 where: 176 Type: 7 178 Length: Either 3 or 4 octets 180 SID/Label: If length is set to 3, then the 20 rightmost bits 181 represent a label. If length is set to 4, then the value 182 represents a 32-bit SID. 184 The receiving router MUST ignore the SID/Label Sub-TLV if the 185 length is other than 3 or 4. 187 4. Segment Routing Capabilities 189 Segment Routing requires some additional router capabilities to be 190 advertised to other routers in the area. 192 These SR capabilities are advertised in the OSPFv3 Router Information 193 Opaque LSA (defined in [RFC7770]) and specified in 194 [I-D.ietf-ospf-segment-routing-extensions]. 196 5. OSPFv3 Extended Prefix Range TLV 198 In some cases it is useful to advertise attributes for a range of 199 prefixes. The Segment Routing Mapping Server, which is described in 200 [I-D.ietf-spring-segment-routing-ldp-interop], is an example of where 201 a single advertisement is needed to advertise SIDs for multiple 202 prefixes from a contiguous address range. 204 The OSPFv3 Extended Prefix Range TLV is defined for this purpose. 206 The OSPFv3 Extended Prefix Range TLV is a top-level TLV of the 207 following LSAs defined in [RFC8362]: 209 E-Intra-Area-Prefix-LSA 211 E-Inter-Area-Prefix-LSA 213 E-AS-External-LSA 215 E-Type-7-LSA 217 Multiple OSPFv3 Extended Prefix Range TLVs MAY be advertised in each 218 LSA mentioned above. The OSPFv3 Extended Prefix Range TLV has the 219 following format: 221 0 1 2 3 222 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 223 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 224 | Type | Length | 225 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 226 | Prefix Length | AF | Range Size | 227 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 228 | Flags | Reserved | 229 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 230 | Address Prefix (variable) | 231 | ... | 232 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 233 | Sub-TLVs (variable) | 234 +- -+ 235 | | 237 where: 239 Type: 9 240 Length: Variable, in octets, dependent on Sub-TLVs. 242 Prefix length: Length of prefix in bits. 244 AF: Address family for the prefix. 246 AF: 0 - IPv4 unicast 248 AF: 1 - IPv6 unicast 250 Range size: Represents the number of prefixes that are covered by 251 the advertisement. The Range Size MUST NOT exceed the number of 252 prefixes that could be satisfied by the prefix length without 253 including: 255 Addresses from the IPv4 multicast address range (224.0.0.0/3), 256 if the AF is IPv4 unicast 258 Addresses other than the IPv6 unicast addresses, if the AF is 259 IPv6 unicast 261 Flags: Reserved. MUST be zero when sent and are ignored when 262 received. 264 Reserved: SHOULD be set to 0 on transmission and MUST be ignored 265 on reception. 267 Address Prefix: 269 For the address family IPv4 unicast, the prefix itself is 270 encoded as a 32-bit value. The default route is represented by 271 a prefix of length 0. 273 For the address family IPv6 unicast, the prefix, encoded as an 274 even multiple of 32-bit words, padded with zeroed bits as 275 necessary. This encoding consumes ((PrefixLength + 31) / 32) 276 32-bit words. 278 Prefix encoding for other address families is beyond the scope 279 of this specification. 281 If the OSPFv3 Extended Prefix Range TLVs advertising the exact same 282 range appears in multiple LSAs of the same type, originated by the 283 same OSPFv3 router, the LSA with the numerically smallest Instance ID 284 MUST be used and subsequent instances of the OSPFv3 Extended Prefix 285 Range TLVs MUST be ignored. 287 6. Prefix SID Sub-TLV 289 The Prefix SID Sub-TLV is a Sub-TLV of the following OSPFv3 TLVs as 290 defined in [RFC8362] and in Section 5: 292 Intra-Area Prefix TLV 294 Inter-Area Prefix TLV 296 External Prefix TLV 298 OSPFv3 Extended Prefix Range TLV 300 It MAY appear more than once in the parent TLV and has the following 301 format: 303 0 1 2 3 304 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 305 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 306 | Type | Length | 307 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 308 | Flags | Algorithm | Reserved | 309 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 310 | SID/Index/Label (variable) | 311 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 312 where: 314 Type: 4 316 Length: 7 or 8 octets, dependent on the V-flag 318 Flags: Single octet field. The following flags are defined: 320 0 1 2 3 4 5 6 7 321 +--+--+--+--+--+--+--+--+ 322 | |NP|M |E |V |L | | | 323 +--+--+--+--+--+--+--+--+ 324 where: 326 NP-Flag: No-PHP flag. If set, then the penultimate hop MUST 327 NOT pop the Prefix-SID before delivering packets to the node 328 that advertised the Prefix-SID. 330 M-Flag: Mapping Server Flag. If set, the SID was advertised by 331 a Segment Routing Mapping Server as described in 332 [I-D.ietf-spring-segment-routing-ldp-interop]. 334 E-Flag: Explicit-Null Flag. If set, any upstream neighbor of 335 the Prefix-SID originator MUST replace the Prefix-SID with the 336 Explicit-NULL label (0 for IPv4, 2 for IPv6) before forwarding 337 the packet. 339 V-Flag: Value/Index Flag. If set, then the Prefix-SID carries 340 an absolute value. If not set, then the Prefix-SID carries an 341 index. 343 L-Flag: Local/Global Flag. If set, then the value/index 344 carried by the Prefix-SID has local significance. If not set, 345 then the value/index carried by this Sub-TLV has global 346 significance. 348 Other bits: Reserved. These MUST be zero when sent and are 349 ignored when received. 351 Reserved: SHOULD be set to 0 on transmission and MUST be ignored 352 on reception. 354 Algorithm: Single octet identifying the algorithm the Prefix-SID 355 is associated with as defined in 356 [I-D.ietf-ospf-segment-routing-extensions]. 358 A router receiving a Prefix-SID from a remote node and with an 359 algorithm value that such remote node has not advertised in the 360 SR-Algorithm Sub-TLV [I-D.ietf-ospf-segment-routing-extensions] 361 MUST ignore the Prefix-SID Sub-TLV. 363 SID/Index/Label: According to the V-Flag and L-Flag, it contains: 365 V-flag is set to 0 and L-flag is set to 0: The SID/Index/Label 366 field is a 4 octet index defining the offset in the SID/Label 367 space advertised by this router 369 V-flag is set to 1 and L-flag is set to 1: The SID/Index/Label 370 field is a 3 octet local label where the 20 rightmost bits are 371 used for encoding the label value. 373 All other combinations of V-flag and L-flag are invalid and any 374 SID advertisement received with an invalid setting for V and L 375 flags MUST be ignored. 377 If an OSPFv3 router advertises multiple Prefix-SIDs for the same 378 prefix, topology, and algorithm, all of them MUST be ignored. 380 When calculating the outgoing label for the prefix, the router MUST 381 take into account, as described below, the E, NP, and M flags 382 advertised by the next-hop router if that router advertised the SID 383 for the prefix. This MUST be done regardless of whether the next-hop 384 router contributes to the best path to the prefix. 386 The NP-Flag (No-PHP) MUST be set and the E-flag MUST be clear for 387 Prefix-SIDs allocated to prefixes that are propagated between areas 388 by an ABR based on intra-area or inter-area reachability, unless the 389 advertised prefix is directly attached to such ABR. 391 The NP-Flag (No-PHP) MUST be set and the E-flag MUST be clear for 392 Prefix-SIDs allocated to redistributed prefixes, unless the 393 redistributed prefix is directly attached to the advertising 394 Autonomous System Boundary Router (ASBR). 396 If the NP-Flag is not set, then any upstream neighbor of the Prefix- 397 SID originator MUST pop the Prefix-SID. This is equivalent to the 398 penultimate hop popping mechanism used in the MPLS dataplane. If the 399 NP-flag is not set, then the received E-flag is ignored. 401 If the NP-flag is set then: 403 If the E-flag is not set, then any upstream neighbor of the 404 Prefix-SID originator MUST keep the Prefix-SID on top of the 405 stack. This is useful when the originator of the Prefix-SID needs 406 to stitch the incoming packet into a continuing MPLS LSP to the 407 final destination. This could occur at an Area Border Router 408 (prefix propagation from one area to another) or at an AS Boundary 409 Router (prefix propagation from one domain to another). 411 If the E-flag is set, then any upstream neighbor of the Prefix-SID 412 originator MUST replace the Prefix-SID with an Explicit-NULL 413 label. This is useful, e.g., when the originator of the Prefix- 414 SID is the final destination for the related prefix and the 415 originator wishes to receive the packet with the original EXP 416 bits. 418 When the M-Flag is set, the NP-flag and the E-flag MUST be ignored on 419 reception. 421 As the Mapping Server does not specify the originator of a prefix 422 advertisement, it is not possible to determine PHP behavior solely 423 based on the Mapping Server advertisement. However, PHP behavior 424 SHOULD be done in following cases: 426 The Prefix is intra-area type and the downstream neighbor is the 427 originator of the prefix. 429 The Prefix is inter-area type and the downstream neighbor is an 430 ABR, which is advertising prefix reachability and is setting the 431 LA-bit in the Prefix Options as described in [RFC8362]. 433 The Prefix is external type and the downstream neighbor is an 434 ASBR, which is advertising prefix reachability and is setting the 435 LA-bit in the Prefix Options as described in [RFC8362]. 437 When a Prefix-SID is advertised in the OSPFv3 Extended Prefix Range 438 TLV, then the value advertised in the Prefix SID Sub-TLV is 439 interpreted as a starting SID/Label value. 441 Example 1: If the following router addresses (loopback addresses) 442 need to be mapped into the corresponding Prefix SID indexes: 444 Router-A: 2001:DB8::1/128, Prefix-SID: Index 1 445 Router-B: 2001:DB8::2/128, Prefix-SID: Index 2 446 Router-C: 2001:DB8::3/128, Prefix-SID: Index 3 447 Router-D: 2001:DB8::4/128, Prefix-SID: Index 4 449 then the Address Prefix field in the OSPFv3 Extended Prefix Range TLV 450 would be set to 2001:DB8::1, the Prefix Length would be set to 128, 451 the Range Size would be set to 4, and the Index value in the Prefix- 452 SID Sub-TLV would be set to 1. 454 Example 2: If the following prefixes need to be mapped into the 455 corresponding Prefix-SID indexes: 457 2001:DB8:1::0/120, Prefix-SID: Index 51 458 2001:DB8:1::100/120, Prefix-SID: Index 52 459 2001:DB8:1::200/120, Prefix-SID: Index 53 460 2001:DB8:1::300/120, Prefix-SID: Index 54 461 2001:DB8:1::400/120, Prefix-SID: Index 55 462 2001:DB8:1::500/120, Prefix-SID: Index 56 463 2001:DB8:1::600/120, Prefix-SID: Index 57 465 then the Prefix field in the OSPFv3 Extended Prefix Range TLV would 466 be set to 2001:DB8:1::0, the Prefix Length would be set to 120, the 467 Range Size would be set to 7, and the Index value in the Prefix-SID 468 Sub-TLV would be set to 51. 470 7. Adjacency Segment Identifier (Adj-SID) 472 An Adjacency Segment Identifier (Adj-SID) represents a router 473 adjacency in Segment Routing. 475 7.1. Adj-SID Sub-TLV 477 The Adj-SID Sub-TLV is an optional Sub-TLV of the Router-Link TLV as 478 defined in [RFC8362]. It MAY appear multiple times in the Router- 479 Link TLV. The Adj-SID Sub-TLV has the following format: 481 0 1 2 3 482 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 483 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 484 | Type | Length | 485 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 486 | Flags | Weight | Reserved | 487 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 488 | SID/Label/Index (variable) | 489 +---------------------------------------------------------------+ 491 where: 493 Type: 5 495 Length: 7 or 8 octets, dependent on the V flag. 497 Flags: Single octet field containing the following flags: 499 0 1 2 3 4 5 6 7 500 +-+-+-+-+-+-+-+-+ 501 |B|V|L|G|P| | 502 +-+-+-+-+-+-+-+-+ 504 where: 506 B-Flag: Backup Flag. If set, the Adj-SID refers to an 507 adjacency that is eligible for protection (e.g., using IPFRR or 508 MPLS-FRR) as described in section 3.5 of [RFC8402]. 510 The V-Flag: Value/Index Flag. If set, then the Adj-SID carries 511 an absolute value. If not set, then the Adj-SID carries an 512 index. 514 The L-Flag: Local/Global Flag. If set, then the value/index 515 carried by the Adj-SID has local significance. If not set, 516 then the value/index carried by this Sub-TLV has global 517 significance. 519 The G-Flag: Group Flag. When set, the G-Flag indicates that 520 the Adj-SID refers to a group of adjacencies (and therefore MAY 521 be assigned to other adjacencies as well). 523 P-Flag. Persistent flag. When set, the P-Flag indicates that 524 the Adj-SID is persistently allocated, i.e., the Adj-SID value 525 remains the same across router restart and/or interface flap. 527 Other bits: Reserved. These MUST be zero when sent and are 528 ignored when received. 530 Reserved: SHOULD be set to 0 on transmission and MUST be ignored 531 on reception. 533 Weight: Weight used for load-balancing purposes. The use of the 534 weight is defined in [RFC8402]. 536 SID/Index/Label: as described in Section 6. 538 An SR-capable router MAY allocate an Adj-SID for each of its 539 adjacencies and set the B-Flag when the adjacency is eligible for 540 protection by an FRR mechanism (IP or MPLS) as described in 541 [RFC8402]. 543 An SR-capable router MAY allocate more than one Adj-SID to an 544 adjacency. 546 An SR-capable router MAY allocate the same Adj-SID to different 547 adjacencies. 549 When the P-flag is not set, the Adj-SID MAY be persistent. When the 550 P-flag is set, the Adj-SID MUST be persistent. 552 7.2. LAN Adj-SID Sub-TLV 554 The LAN Adj-SID Sub-TLV is an optional Sub-TLV of the Router-Link 555 TLV. It MAY appear multiple times in the Router-Link TLV. It is 556 used to advertise a SID/Label for an adjacency to a non-DR router on 557 a broadcast, NBMA, or hybrid [RFC6845] network. 559 0 1 2 3 560 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 561 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 562 | Type | Length | 563 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 564 | Flags | Weight | Reserved | 565 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 566 | Neighbor ID | 567 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 568 | SID/Label/Index (variable) | 569 +---------------------------------------------------------------+ 571 where: 573 Type: 6 575 Length: 11 or 12 octets, dependent on V-flag. 577 Flags: same as in Section 7.1 579 Weight: Weight used for load-balancing purposes. The use of the 580 weight is defined in [RFC8402]. 582 Reserved: SHOULD be set to 0 on transmission and MUST be ignored 583 on reception. 585 Neighbor ID: The Router ID of the neighbor for which the LAN-Adj- 586 SID is advertised. 588 SID/Index/Label: as described in Section 6. 590 When the P-flag is not set, the Adj-SID MAY be persistent. When 591 the P-flag is set, the Adj-SID MUST be persistent. 593 8. Elements of Procedure 595 8.1. Intra-area Segment routing in OSPFv3 597 An OSPFv3 router that supports segment routing MAY advertise Prefix- 598 SIDs for any prefix to which it is advertising reachability (e.g., a 599 loopback IP address as described in Section 6). 601 A Prefix-SID can also be advertised by SR Mapping Servers (as 602 described in [I-D.ietf-spring-segment-routing-ldp-interop]). A 603 Mapping Server advertises Prefix-SIDs for remote prefixes that exist 604 in the OSPFv3 routing domain. Multiple Mapping Servers can advertise 605 Prefix-SIDs for the same prefix, in which case the same Prefix-SID 606 MUST be advertised by all of them. The SR Mapping Server could use 607 either area flooding scope or autonomous system flooding scope when 608 advertising Prefix SIDs for prefixes, based on the configuration of 609 the SR Mapping Server. Depending on the flooding scope used, the SR 610 Mapping Server chooses the OSPFv3 LSA type that will be used. If the 611 area flooding scope is needed, an E-Intra-Area-Prefix-LSA [RFC8362] 612 is used. If autonomous system flooding scope is needed, an E-AS- 613 External-LSA [RFC8362] is used. 615 When a Prefix-SID is advertised by the Mapping Server, which is 616 indicated by the M-flag in the Prefix-SID Sub-TLV (Section 6), the 617 route type as implied by the LSA type is ignored and the Prefix-SID 618 is bound to the corresponding prefix independent of the route type. 620 Advertisement of the Prefix-SID by the Mapping Server using an Inter- 621 Area Prefix TLV, External-Prefix TLV, or Intra-Area-Prefix TLV 622 [RFC8362] does not itself contribute to the prefix reachability. The 623 NU-bit MUST be set in the PrefixOptions field of the LSA which is 624 used by the Mapping Server to advertise SID or SID Range, which 625 prevents the advertisement from contributing to prefix reachability. 627 An SR Mapping Server MUST use the OSPFv3 Extended Prefix Range TLVs 628 when advertising SIDs for prefixes. Prefixes of different route- 629 types can be combined in a single OSPFv3 Extended Prefix Range TLV 630 advertised by an SR Mapping Server. 632 Area-scoped OSPFv3 Extended Prefix Range TLVs are propagated between 633 areas. Similar to propagation of prefixes between areas, an ABR only 634 propagates the OSPFv3 Extended Prefix Range TLV that it considers to 635 be the best from the set it received. The rules used to pick the 636 best OSPFv3 Extended Prefix Range TLV are described in Section 5. 638 8.2. Inter-area Segment routing in OSPFv3 640 In order to support SR in a multi-area environment, OSPFv3 MUST 641 propagate Prefix-SID information between areas. The following 642 procedure is used to propagate Prefix SIDs between areas. 644 When an OSPFv3 ABR advertises an Inter-Area-Prefix-LSA from an intra- 645 area prefix to all its connected areas, it will also include the 646 Prefix-SID Sub-TLV, as described in Section 6. The Prefix-SID value 647 will be set as follows: 649 The ABR will look at its best path to the prefix in the source 650 area and find the advertising router associated with the best path 651 to that prefix. 653 The ABR will then determine if such router advertised a Prefix-SID 654 for the prefix and use it when advertising the Prefix-SID to other 655 connected areas. 657 If no Prefix-SID was advertised for the prefix in the source area 658 by the router that contributes to the best path to the prefix, the 659 originating ABR will use the Prefix-SID advertised by any other 660 router when propagating the Prefix-SID for the prefix to other 661 areas. 663 When an OSPFv3 ABR advertises Inter-Area-Prefix-LSA LSAs from an 664 inter-area route to all its connected areas, it will also include the 665 Prefix-SID Sub-TLV, as described in Section 6. The Prefix-SID value 666 will be set as follows: 668 The ABR will look at its best path to the prefix in the backbone 669 area and find the advertising router associated with the best path 670 to that prefix. 672 The ABR will then determine if such router advertised a Prefix-SID 673 for the prefix and use it when advertising the Prefix-SID to other 674 connected areas. 676 If no Prefix-SID was advertised for the prefix in the backbone 677 area by the ABR that contributes to the best path to the prefix, 678 the originating ABR will use the Prefix-SID advertised by any 679 other router when propagating the Prefix-SID for the prefix to 680 other areas. 682 8.3. Segment Routing for External Prefixes 684 AS-External-LSAs are flooded domain wide. When an ASBR, which 685 supports SR, originates an E-AS-External-LSA, it SHOULD also include 686 a Prefix-SID Sub-TLV, as described in Section 6. The Prefix-SID 687 value will be set to the SID that has been reserved for that prefix. 689 When an NSSA [RFC3101] ABR translates an E-NSSA-LSA into an E-AS- 690 External-LSA, it SHOULD also advertise the Prefix-SID for the prefix. 691 The NSSA ABR determines its best path to the prefix advertised in the 692 translated E-NSSA-LSA and finds the advertising router associated 693 with that path. If the advertising router has advertised a Prefix- 694 SID for the prefix, then the NSSA ABR uses it when advertising the 695 Prefix-SID for the E-AS-External-LSA. Otherwise, the Prefix-SID 696 advertised by any other router will be used. 698 8.4. Advertisement of Adj-SID 700 The Adjacency Segment Routing Identifier (Adj-SID) is advertised 701 using the Adj-SID Sub-TLV as described in Section 7. 703 8.4.1. Advertisement of Adj-SID on Point-to-Point Links 705 An Adj-SID MAY be advertised for any adjacency on a P2P link that is 706 in neighbor state 2-Way or higher. If the adjacency on a P2P link 707 transitions from the FULL state, then the Adj-SID for that adjacency 708 MAY be removed from the area. If the adjacency transitions to a 709 state lower than 2-Way, then the Adj-SID advertisement MUST be 710 withdrawn from the area. 712 8.4.2. Adjacency SID on Broadcast or NBMA Interfaces 714 Broadcast, NBMA, or hybrid [RFC6845] networks in OSPFv3 are 715 represented by a star topology where the Designated Router (DR) is 716 the central point to which all other routers on the broadcast, NBMA, 717 or hybrid network connect. As a result, routers on the broadcast, 718 NBMA, or hybrid network advertise only their adjacency to the DR. 719 Routers that do not act as DR do not form or advertise adjacencies 720 with each other. They do, however, maintain 2-Way adjacency state 721 with each other and are directly reachable. 723 When Segment Routing is used, each router on the broadcast, NBMA, or 724 hybrid network MAY advertise the Adj-SID for its adjacency to the DR 725 using the Adj-SID Sub-TLV as described in Section 7.1. 727 SR-capable routers MAY also advertise a LAN-Adj-SID for other 728 neighbors (e.g., BDR, DR-OTHER) on the broadcast, NBMA, or hybrid 729 network using the LAN-Adj-SID Sub-TLV as described in Section 7.2. 731 9. IANA Considerations 733 This specification updates several existing OSPFv3 registries. 735 9.1. OSPFv3 Extended-LSA TLV Registry 737 Following values are allocated: 739 o 9 - OSPFv3 Extended Prefix Range TLV 741 9.2. OSPFv3 Extended-LSA Sub-TLV registry 743 o 4 - Prefix SID Sub-TLV 745 o 5 - Adj-SID Sub-TLV 746 o 6 - LAN Adj-SID Sub-TLV 748 o 7 - SID/Label Sub-TLV 750 10. Security Considerations 752 With the OSPFv3 segment routing extensions defined herein, OSPFv3 753 will now program the MPLS data plane [RFC3031]. Previously, LDP 754 [RFC5036] or another label distribution mechanism was required to 755 advertise MPLS labels and program the MPLS data plane. 757 In general, the same types of attacks that can be carried out on the 758 IP control plane can be carried out on the MPLS control plane 759 resulting in traffic being misrouted in the respective data planes. 760 However, the latter can be more difficult to detect and isolate. 762 Existing security extensions as described in [RFC5340] and [RFC8362] 763 apply to these segment routing extensions. While OSPFv3 is under a 764 single administrative domain, there can be deployments where 765 potential attackers have access to one or more networks in the OSPFv3 766 routing domain. In these deployments, stronger authentication 767 mechanisms such as those specified in [RFC4552] or [RFC7166] SHOULD 768 be used. 770 Implementations MUST assure that malformed TLV and Sub-TLV defined in 771 this document are detected and do not provide a vulnerability for 772 attackers to crash the OSPFv3 router or routing process. Reception 773 of a malformed TLV or Sub-TLV SHOULD be counted and/or logged for 774 further analysis. Logging of malformed TLVs and Sub-TLVs SHOULD be 775 rate-limited to prevent a Denial of Service (DoS) attack (distributed 776 or otherwise) from overloading the OSPFv3 control plane. 778 11. Contributors 780 The following people gave a substantial contribution to the content 781 of this document and should be considered as co-authors: 783 Clarence Filsfils 784 Cisco Systems, Inc. 785 Brussels 786 Belgium 788 Email: cfilsfil@cisco.com 790 Hannes Gredler 791 RtBrick Inc. 792 Austria 794 Email: hannes@rtbrick.com 796 Rob Shakir 797 Google, Inc. 798 1600 Amphitheatre Parkway 799 Mountain View, CA 94043 800 US 802 Email: robjs@google.com 804 Wim Henderickx 805 Nokia 806 Copernicuslaan 50 807 Antwerp 2018 808 BE 810 Email: wim.henderickx@nokia.com 812 Jeff Tantsura 813 Nuage Networks 814 US 816 Email: jefftant.ietf@gmail.com 818 Thanks to Acee Lindem for his substantial contribution to the content 819 of this document. 821 We would like to thank Anton Smirnov for his contribution as well. 823 12. References 825 12.1. Normative References 827 [ALGOREG] "IGP Algorithm Types", . 830 [I-D.ietf-ospf-segment-routing-extensions] 831 Psenak, P., Previdi, S., Filsfils, C., Gredler, H., 832 Shakir, R., Henderickx, W., and J. Tantsura, "OSPF 833 Extensions for Segment Routing", draft-ietf-ospf-segment- 834 routing-extensions-26 (work in progress), November 2018. 836 [I-D.ietf-spring-segment-routing-ldp-interop] 837 Bashandy, A., Filsfils, C., Previdi, S., Decraene, B., and 838 S. Litkowski, "Segment Routing interworking with LDP", 839 draft-ietf-spring-segment-routing-ldp-interop-15 (work in 840 progress), September 2018. 842 [I-D.ietf-spring-segment-routing-mpls] 843 Bashandy, A., Filsfils, C., Previdi, S., Decraene, B., 844 Litkowski, S., and R. Shakir, "Segment Routing with MPLS 845 data plane", draft-ietf-spring-segment-routing-mpls-16 846 (work in progress), November 2018. 848 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 849 Requirement Levels", BCP 14, RFC 2119, 850 DOI 10.17487/RFC2119, March 1997, 851 . 853 [RFC3031] Rosen, E., Viswanathan, A., and R. Callon, "Multiprotocol 854 Label Switching Architecture", RFC 3031, 855 DOI 10.17487/RFC3031, January 2001, 856 . 858 [RFC3101] Murphy, P., "The OSPF Not-So-Stubby Area (NSSA) Option", 859 RFC 3101, DOI 10.17487/RFC3101, January 2003, 860 . 862 [RFC5036] Andersson, L., Ed., Minei, I., Ed., and B. Thomas, Ed., 863 "LDP Specification", RFC 5036, DOI 10.17487/RFC5036, 864 October 2007, . 866 [RFC5340] Coltun, R., Ferguson, D., Moy, J., and A. Lindem, "OSPF 867 for IPv6", RFC 5340, DOI 10.17487/RFC5340, July 2008, 868 . 870 [RFC6845] Sheth, N., Wang, L., and J. Zhang, "OSPF Hybrid Broadcast 871 and Point-to-Multipoint Interface Type", RFC 6845, 872 DOI 10.17487/RFC6845, January 2013, 873 . 875 [RFC7770] Lindem, A., Ed., Shen, N., Vasseur, JP., Aggarwal, R., and 876 S. Shaffer, "Extensions to OSPF for Advertising Optional 877 Router Capabilities", RFC 7770, DOI 10.17487/RFC7770, 878 February 2016, . 880 [RFC8362] Lindem, A., Roy, A., Goethals, D., Reddy Vallem, V., and 881 F. Baker, "OSPFv3 Link State Advertisement (LSA) 882 Extensibility", RFC 8362, DOI 10.17487/RFC8362, April 883 2018, . 885 [RFC8402] Filsfils, C., Ed., Previdi, S., Ed., Ginsberg, L., 886 Decraene, B., Litkowski, S., and R. Shakir, "Segment 887 Routing Architecture", RFC 8402, DOI 10.17487/RFC8402, 888 July 2018, . 890 12.2. Informative References 892 [RFC4552] Gupta, M. and N. Melam, "Authentication/Confidentiality 893 for OSPFv3", RFC 4552, DOI 10.17487/RFC4552, June 2006, 894 . 896 [RFC7166] Bhatia, M., Manral, V., and A. Lindem, "Supporting 897 Authentication Trailer for OSPFv3", RFC 7166, 898 DOI 10.17487/RFC7166, March 2014, 899 . 901 [RFC7855] Previdi, S., Ed., Filsfils, C., Ed., Decraene, B., 902 Litkowski, S., Horneffer, M., and R. Shakir, "Source 903 Packet Routing in Networking (SPRING) Problem Statement 904 and Requirements", RFC 7855, DOI 10.17487/RFC7855, May 905 2016, . 907 Authors' Addresses 909 Peter Psenak (editor) 910 Cisco Systems, Inc. 911 Eurovea Centre, Central 3 912 Pribinova Street 10 913 Bratislava 81109 914 Slovakia 916 Email: ppsenak@cisco.com 918 Stefano Previdi (editor) 919 Individual 921 Email: stefano.previdi@net