idnits 2.17.1 draft-ietf-idr-bgp-open-policy-05.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 seems to lack the recommended RFC 2119 boilerplate, even if it appears to use RFC 2119 keywords -- however, there's a paragraph with a matching beginning. Boilerplate error? (The document does seem to have the reference to RFC 2119 which the ID-Checklist requires). -- The document date (February 15, 2019) is 1869 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) == Outdated reference: A later version (-11) exists of draft-ietf-idr-route-leak-detection-mitigation-10 -- Obsolete informational reference (is this intentional?): RFC 5226 (Obsoleted by RFC 8126) Summary: 0 errors (**), 0 flaws (~~), 3 warnings (==), 2 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group A. Azimov 3 Internet-Draft E. Bogomazov 4 Intended status: Standards Track Qrator Labs 5 Expires: August 19, 2019 R. Bush 6 Internet Initiative Japan 7 K. Patel 8 Arrcus, Inc. 9 K. Sriram 10 US NIST 11 February 15, 2019 13 Route Leak Prevention using Roles in Update and Open messages 14 draft-ietf-idr-bgp-open-policy-05 16 Abstract 18 Route Leaks are the propagation of BGP prefixes which violate 19 assumptions of BGP topology relationships; e.g. passing a route 20 learned from one peer to another peer or to a transit provider, 21 passing a route learned from one transit provider to another transit 22 provider or to a peer. Today, approaches to leak prevention rely on 23 marking routes according to operator configuration options, with no 24 check that the configuration corresponds to that of the BGP neighbor, 25 or enforcement that the two BGP speakers agree on the relationship. 26 This document enhances BGP Open to establish agreement of the (peer, 27 customer, provider, RS, RS-client, internal) relationship of two 28 neighboring BGP speakers to enforce appropriate configuration on both 29 sides. Propagated routes are then marked with an iOTC attribute 30 according to agreed relationship allowing prevention of route leaks. 32 Requirements Language 34 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 35 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" are to 36 be interpreted as described in RFC 2119 [RFC2119] only when they 37 appear in all upper case. They may also appear in lower or mixed 38 case as English words, without normative meaning. 40 Status of This Memo 42 This Internet-Draft is submitted in full conformance with the 43 provisions of BCP 78 and BCP 79. 45 Internet-Drafts are working documents of the Internet Engineering 46 Task Force (IETF). Note that other groups may also distribute 47 working documents as Internet-Drafts. The list of current Internet- 48 Drafts is at https://datatracker.ietf.org/drafts/current/. 50 Internet-Drafts are draft documents valid for a maximum of six months 51 and may be updated, replaced, or obsoleted by other documents at any 52 time. It is inappropriate to use Internet-Drafts as reference 53 material or to cite them other than as "work in progress." 55 This Internet-Draft will expire on August 19, 2019. 57 Copyright Notice 59 Copyright (c) 2019 IETF Trust and the persons identified as the 60 document authors. All rights reserved. 62 This document is subject to BCP 78 and the IETF Trust's Legal 63 Provisions Relating to IETF Documents 64 (https://trustee.ietf.org/license-info) in effect on the date of 65 publication of this document. Please review these documents 66 carefully, as they describe your rights and restrictions with respect 67 to this document. Code Components extracted from this document must 68 include Simplified BSD License text as described in Section 4.e of 69 the Trust Legal Provisions and are provided without warranty as 70 described in the Simplified BSD License. 72 Table of Contents 74 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 75 2. Peering Relationships . . . . . . . . . . . . . . . . . . . . 3 76 3. BGP Role . . . . . . . . . . . . . . . . . . . . . . . . . . 4 77 4. Role capability . . . . . . . . . . . . . . . . . . . . . . . 4 78 5. Role correctness . . . . . . . . . . . . . . . . . . . . . . 5 79 5.1. Strict mode . . . . . . . . . . . . . . . . . . . . . . . 6 80 6. BGP Internal Only To Customer attribute . . . . . . . . . . . 6 81 7. Attribute or Community . . . . . . . . . . . . . . . . . . . 6 82 8. Compatibility with BGPsec . . . . . . . . . . . . . . . . . . 7 83 9. Additional Considerations . . . . . . . . . . . . . . . . . . 7 84 10. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 7 85 11. Security Considerations . . . . . . . . . . . . . . . . . . . 8 86 12. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 8 87 13. References . . . . . . . . . . . . . . . . . . . . . . . . . 8 88 13.1. Normative References . . . . . . . . . . . . . . . . . . 8 89 13.2. Informative References . . . . . . . . . . . . . . . . . 9 90 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 9 92 1. Introduction 94 This document specifies a new BGP Capability Code, [RFC5492] Sec 4, 95 which two BGP speakers MAY use to ensure that they MUST agree on 96 their relationship; i.e. customer and provider or peers. Either or 97 both MAY optionally be configured to require that this option be 98 exchanged for the BGP Open to succeed. 100 Also this document specifies a way to mark routes according to BGP 101 Roles established in OPEN message and a way to create double-boundary 102 filters for prevention of route leaks using the new BGP Path 103 Attribute. 105 For the purpose of this document, BGP route leaks are when a BGP 106 route was learned from transit provider or peer and is announced to 107 another provider or peer. See[RFC7908]. These are usually the 108 result of misconfigured or absent BGP route filtering or lack of 109 coordination between two BGP speakers. 111 [I-D.ietf-idr-route-leak-detection-mitigation] The mechanism proposed 112 in that draft provides the opportunity to detect route leaks made by 113 third parties but provides no mechanism to strongly prevent route 114 leak creation. 116 Also, route tagging which relies on operator maintained policy 117 configuration is too easily, and too often, misconfigured. 119 2. Peering Relationships 121 Despite uses of words such as "Customer," "Peer." etc. described 122 above are not business relationships, who pays whom, etc. These are 123 common terms to represent restrictions on BGP route propagation, 124 sometimes known as the Gao-Rexford model. 126 A Provider: MAY send to a customer all available prefixes. 128 A Customer: MAY send to a provider their own prefixes and prefixes 129 learned from any of their customers. A customer MUST NOT send to 130 a provider prefixes learned from peers, other providers, or RS. 132 A Route Server (RS) MAY send to a RS client all available prefixes. 134 A Route Server Client (RS-client) MAY send to an RS its own prefixes 135 and prefixes learned from its customers. A RS-client MUST NOT 136 send to an RS prefixes learned from peers, providers, or other RS. 138 A Peer: MAY send to a peer its own prefixes and prefixes learned 139 from its customers. A peer MUST NOT send to a peer prefixes 140 learned from other peers, providers, or RS. 142 An Internal: MAY send all available prefixes through internal link. 144 Of course, any BGP speaker may apply policy to reduce what is 145 announced, and a recipient may apply policy to reduce the set of 146 routes they accept. But violation of rules marked MUST NOT may 147 result in route leaks. While these peering relations cover 99% of 148 possible scenarios, their configuration isn't part of the BGP itself, 149 thus requiring configuration of communities and corresponding egress 150 prefix filters. The automation of this process may significantly 151 decrease number of configuration mistakes. 153 3. BGP Role 155 BGP Role is new configuration option that SHOULD be configured on 156 each BGP session. It reflects the real-world agreement between two 157 BGP speakers about their peering relationship. 159 Allowed Role values for eBGP sessions are: 161 o Provider - sender is a transit provider to neighbor; 163 o Customer - sender is customer of neighbor; 165 o RS - sender is route server at internet exchange point (IX) 167 o RS-client - sender is client of RS at internet exchange point (IX) 169 o Peer - sender and neighbor are peers; 171 o Internal - sender and neighbor are part of the same organization. 173 For iBGP sessions, only the Internal role MAY be configured. 175 Since BGP Role reflects the relationship between two BGP speakers, it 176 could also be used for more than route leak mitigation. 178 4. Role capability 180 The TLV (type, length, value) of the BGP Role capability are: 182 o Type - ; 184 o Length - 1 (octet); 186 o Value - integer corresponding to speaker' BGP Role. 188 +-------+---------------------+ 189 | Value | Role name | 190 +-------+---------------------+ 191 | 0 | Sender is Internal | 192 | 1 | Sender is Provider | 193 | 2 | Sender is RS | 194 | 3 | Sender is RS-Client | 195 | 4 | Sender is Customer | 196 | 5 | Sender is Peer | 197 +-------+---------------------+ 199 Table 1: Predefined BGP Role Values 201 5. Role correctness 203 Section 3 described how BGP Role is a reflection of the relationship 204 between two BGP speakers. But the mere presence of BGP Role doesn't 205 automatically guarantee role agreement between two BGP peers. 207 To enforce correctness, the BGP Role check is used with a set of 208 constrains on how speakers' BGP Roles MUST correspond. Of course, 209 each speaker MUST announce and accept the BGP Role capability in the 210 BGP OPEN message exchange. 212 If a speaker receives a BGP Role capability, it MUST check the value 213 of the received capability with its own BGP Role (if it is set). The 214 allowed pairings are (first a sender's Role, second the receiver's 215 Role): 217 +-------------+---------------+ 218 | Sender Role | Receiver Role | 219 +-------------+---------------+ 220 | Internal | Internal | 221 | Provider | Customer | 222 | Customer | Provider | 223 | RS | RS-Client | 224 | RS-Client | RS | 225 | Peer | Peer | 226 +-------------+---------------+ 228 Table 2: Allowed Role Capabilities 230 In case of any other pairs of roles, a speaker MUST send a Role 231 Mismatch Notification (code 2, sub-code ). 233 5.1. Strict mode 235 A new BGP configuration option "strict mode" is defined with values 236 of true or false. If set to true, then the speaker MUST refuse to 237 establish a BGP session with a neighbor which does not announce the 238 BGP Role capability in their OPEN message. If a speaker rejects a 239 connection, it MUST send a Connection Rejected Notification [RFC4486] 240 (Notification with error code 6, subcode 5). By default, strict mode 241 SHOULD be set to false for backward compatibility with BGP speakers 242 that do not yet support this mechanism. 244 6. BGP Internal Only To Customer attribute 246 The Internal Only To Customer (iOTC) attribute is a new optional, 247 non-transitive BGP Path attribute with the Type Code . This 248 attribute has zero length as it is used only as a flag. 250 There are four rules of iOTC attribute usage: 252 1. The iOTC attribute MUST be added to all incoming routes if the 253 receiver's Role is Customer, Peer, or RS-client; 255 2. Routes with the iOTC attribute set MUST NOT be announced by a 256 sender whose Role is Customer, Peer, or RS-client; 258 3. A sender MUST NOT include iOTC in UPDATE messages advertised to 259 eBGP neighbor if its Role isn't Internal. 261 4. If iOTC is contained in an UPDATE message from eBGP speaker and 262 receiver's Role isn't Internal then this attribute MUST be 263 removed. 265 These rules provide mechanism to strongly prevent route leak creation 266 by an AS. 268 7. Attribute or Community 270 Having the relationship hard set by agreement between the two peers 271 in BGP OPEN is critical; the routers enforce the relationship 272 irrespective of operator policy configuration errors. 274 Similarly, it is critical that the application of that relationship 275 on prefix propagation using iOTC is enforced by the router(s), and 276 minimally exposed to user mis-configuration. There is a question 277 whether the iOTC marking should be an attribute or a well-known 278 community. 280 There is a long and sordid history of mis-configurations inserting 281 incorrect communities, deleting communities, ignoring well-known 282 community markings etc. In this mechanism's case, an operator could, 283 for example, accidentally strip the well-known community on receipt. 285 As opposed to communities, BGP attributes may not be generally 286 modified or filtered by the operator. The router(s) enforce them. 287 This is the desired property for the iOTC marking. Hence, this 288 document specifies iOTC as an attribute. 290 8. Compatibility with BGPsec 292 As the iOTC attribute is non-transitive, it is not seen by or signed 293 by BGPsec [RFC8205]. 295 9. Additional Considerations 297 As the BGP Role reflects the peering relationship between neighbors, 298 it can also have other uses. As an example, BGP Role might affect 299 route priority, or be used to distinguish borders of a network if a 300 network consists of multiple ASs. 302 Though such uses may be worthwhile, they are not the goal of this 303 document. Note that such uses would require local policy control. 305 As BGP role configuration results in automatic creation of inbound/ 306 outbound filters, existence of roles should be treated as existence 307 of Import and Export policy. [RFC8212] 309 This document doesn't provide any security measures to check 310 correctness of iOTC usage if role isn't configured. 312 10. IANA Considerations 314 This document defines a new Capability Codes option [to be removed 315 upon publication: http://www.iana.org/assignments/capability-codes/ 316 capability-codes.xhtml] [RFC5492], named "BGP Role", assigned value 317 . The length of this capability is 1. 319 The BGP Role capability includes a Value field, for which IANA is 320 requested to create and maintain a new sub-registry called "BGP Role 321 Value". Assignments consist of Value and corresponding Role name. 322 Initially this registry is to be populated with the data in Table 1. 323 Future assignments may be made by a standard action 324 procedure[RFC5226]. 326 This document defines new subcode, "Role Mismatch", assigned value 327 in the OPEN Message Error subcodes registry [to be removed 328 upon publication: http://www.iana.org/assignments/bgp-parameters/bgp- 329 parameters.xhtml#bgp-parameters-6] [RFC4271]. 331 This document defines a new optional, non-transitive BGP Path 332 Attributes option, named "Internal Only To Customer", assigned value 333 [To be removed upon publication: 334 http://www.iana.org/assignments/bgp-parameters/bgp- 335 parameters.xhtml#bgp-parameters-2] [RFC4271]. The length of this 336 attribute is 0. 338 11. Security Considerations 340 This document proposes a mechanism for prevention of route leaks that 341 are the result of BGP policy mis-configuration. 343 Deliberate sending of a known conflicting BGP Role could be used to 344 sabotage a BGP connection. This is easily detectable. 346 BGP Role is disclosed only to an immediate BGP neighbor, so it will 347 not itself reveal any sensitive information to third parties. 349 12. Acknowledgments 351 The authors wish to thank Douglas Montgomery, Brian Dickson, Andrei 352 Robachevsky and Daniel Ginsburg for their contributions to a variant 353 of this work. 355 13. References 357 13.1. Normative References 359 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 360 Requirement Levels", BCP 14, RFC 2119, 361 DOI 10.17487/RFC2119, March 1997, 362 . 364 [RFC4271] Rekhter, Y., Ed., Li, T., Ed., and S. Hares, Ed., "A 365 Border Gateway Protocol 4 (BGP-4)", RFC 4271, 366 DOI 10.17487/RFC4271, January 2006, 367 . 369 [RFC4486] Chen, E. and V. Gillet, "Subcodes for BGP Cease 370 Notification Message", RFC 4486, DOI 10.17487/RFC4486, 371 April 2006, . 373 [RFC5492] Scudder, J. and R. Chandra, "Capabilities Advertisement 374 with BGP-4", RFC 5492, DOI 10.17487/RFC5492, February 375 2009, . 377 13.2. Informative References 379 [I-D.ietf-idr-route-leak-detection-mitigation] 380 Sriram, K. and A. Azimov, "Methods for Detection and 381 Mitigation of BGP Route Leaks", draft-ietf-idr-route-leak- 382 detection-mitigation-10 (work in progress), October 2018. 384 [RFC5226] Narten, T. and H. Alvestrand, "Guidelines for Writing an 385 IANA Considerations Section in RFCs", RFC 5226, 386 DOI 10.17487/RFC5226, May 2008, 387 . 389 [RFC7908] Sriram, K., Montgomery, D., McPherson, D., Osterweil, E., 390 and B. Dickson, "Problem Definition and Classification of 391 BGP Route Leaks", RFC 7908, DOI 10.17487/RFC7908, June 392 2016, . 394 [RFC8205] Lepinski, M., Ed. and K. Sriram, Ed., "BGPsec Protocol 395 Specification", RFC 8205, DOI 10.17487/RFC8205, September 396 2017, . 398 [RFC8212] Mauch, J., Snijders, J., and G. Hankins, "Default External 399 BGP (EBGP) Route Propagation Behavior without Policies", 400 RFC 8212, DOI 10.17487/RFC8212, July 2017, 401 . 403 Authors' Addresses 405 Alexander Azimov 406 Qrator Labs 408 Email: a.e.azimov@gmail.com 410 Eugene Bogomazov 411 Qrator Labs 413 Email: eb@qrator.net 415 Randy Bush 416 Internet Initiative Japan 418 Email: randy@psg.com 419 Keyur Patel 420 Arrcus, Inc. 422 Email: keyur@arrcus.com 424 Kotikalapudi Sriram 425 US NIST 427 Email: ksriram@nist.gov