idnits 2.17.1 draft-ymbk-idr-bgp-open-policy-03.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 (March 13, 2017) is 2572 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-03 == Outdated reference: A later version (-23) exists of draft-ietf-sidr-bgpsec-protocol-15 -- Obsolete informational reference (is this intentional?): RFC 5226 (Obsoleted by RFC 8126) Summary: 0 errors (**), 0 flaws (~~), 4 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: September 14, 2017 R. Bush 6 Internet Initiative Japan 7 K. Patel 8 Arrcus, Inc. 9 K. Sriram 10 US NIST 11 March 13, 2017 13 Route Leak Prevention using Roles in Update and Open messages 14 draft-ymbk-idr-bgp-open-policy-03 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 without 24 any check that the configuration corresponds to that of the BGP 25 neighbor, or enforcement that the two BGP speakers agree on the 26 relationship. This document enhances BGP Open to establish agreement 27 of the (peer, customer, provider, 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 http://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 September 14, 2017. 57 Copyright Notice 59 Copyright (c) 2017 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 (http://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. Preamble . . . . . . . . . . . . . . . . . . . . . . . . . . 3 75 1.1. Peering Relationships . . . . . . . . . . . . . . . . . . 3 76 2. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 77 3. Role Definitions . . . . . . . . . . . . . . . . . . . . . . 3 78 4. BGP Role . . . . . . . . . . . . . . . . . . . . . . . . . . 4 79 5. Role capability . . . . . . . . . . . . . . . . . . . . . . . 5 80 6. Role correctness . . . . . . . . . . . . . . . . . . . . . . 5 81 6.1. Strict mode . . . . . . . . . . . . . . . . . . . . . . . 6 82 7. Restrictions on the Complex role . . . . . . . . . . . . . . 6 83 8. BGP Internal Only To Customer attribute . . . . . . . . . . . 6 84 9. Compatibility with BGPsec . . . . . . . . . . . . . . . . . . 7 85 10. Additional Considerations . . . . . . . . . . . . . . . . . . 7 86 11. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 7 87 12. Security Considerations . . . . . . . . . . . . . . . . . . . 8 88 13. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 8 89 14. References . . . . . . . . . . . . . . . . . . . . . . . . . 8 90 14.1. Normative References . . . . . . . . . . . . . . . . . . 8 91 14.2. Informative References . . . . . . . . . . . . . . . . . 9 92 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 9 94 1. Preamble 96 1.1. Peering Relationships 98 Despite uses of words such as "Customer," "Peer." etc. the intent is 99 not business relationships, who pays whom, etc. These are common 100 terms to represent restrictions on BGP propagation, some times known 101 as Gao/Rexford. E.g. if A is a "peer" of B and C, A does not 102 propagate B's prefixes to C. If D is a "customer" of E and F, D does 103 not propagate prefixes learned from E to F. 105 As the whole point of route leak detection and prevention is to 106 prevent vioation of these relationships, they are inescapable. 108 2. Introduction 110 This document specifies a new BGP Capability Code, [RFC5492] Sec 4, 111 which two BGP speakers MAY use to ensure that they MUST agree on 112 their relationship; i.e. customer and provider or peers. Either or 113 both may optionally be configured to require that this option be 114 exchanged for the BGP Open to succeed. 116 Also this document specifies a way to mark routes according to BGP 117 Roles established in OPEN and a way to create double-boundary filters 118 for prevention of route leaks via new BGP Path Attribute. 120 For the purpose of this document, BGP route leaks are when a BGP 121 route was learned from transit provider or peer and is announced to 122 another provider or peer. See 123 [I-D.ietf-grow-route-leak-problem-definition]. These are usually the 124 result of misconfigured or absent BGP route filtering or lack of 125 coordination between two BGP speakers. 127 [I-D.ietf-idr-route-leak-detection-mitigation] The mechanism proposed 128 in that draft provides the opportunity to detect route leaks made by 129 third parties but provides no support to strongly prevent route leak 130 creation. 132 Also, route tagging which relies on operator maintained policy 133 configuration is too easily and too often misconfigured. 135 3. Role Definitions 137 As many of these terms are used differently in various contexts, it 138 is worth being explicit. 140 A Provider: sends their own routes and (possibly) a subset of routes 141 learned from their other customers, peers, and transit providers 142 to their customer. 144 A Customer: accepts 'transit routes' from its provider(s) and 145 announces their own routes and the routes they have learned from 146 the transitive closure of their customers (AKA their 'customer 147 cone') to their provider(s). 149 A Peer: announces their routes and the routes from their customer 150 cone to other Peers. 152 An Internal: announces all routes, accepts all routes. 154 A Complex: BGP relationship is an attempt to allow those whose 155 policy may vary by prefix. It is aptly named and the authors 156 question its real utility. 158 Of course, any BGP speaker may apply policy to reduce what is 159 announced, and a recipient may apply policy to reduce the set of 160 routes they accept. 162 4. BGP Role 164 BGP Role is new mandatory configuration option. It reflects the 165 real-world agreement between two BGP speakers about their peering 166 relationship. 168 Allowed Role values are: 170 o Provider - sender is a transit provider to neighbor; 172 o Customer - sender is customer of neighbor; 174 o Peer - sender and neighbor are peers; 176 o Internal - sender and neighbor is part of same organization. This 177 includes but is not limited to situation when sender and neighbor 178 are in same AS. 180 o Complex - sender has a non-standard relationship and wants to use 181 manual per-prefix based role policies. 183 Since BGP Role reflects the relationship between two BGP speakers, it 184 could also be used for more than route leak mitigation. 186 5. Role capability 188 The TLV (type, length, value) of the BGP Role capability are: 190 o Type - ; 192 o Length - 1 (octet); 194 o Value - integer corresponding to speaker' BGP Role. 196 +--------+----------------------+ 197 | Value | Role name | 198 +--------+----------------------+ 199 | 0 | Undefined | 200 | 1 | Sender is Peer | 201 | 2 | Sender is Provider | 202 | 3 | Sender is Customer | 203 | 4 | Sender is Internal | 204 | 5 | Sender is Complex | 205 +--------+----------------------+ 207 Table 1: Predefined BGP Role Values 209 6. Role correctness 211 Section 4 described how BGP Role is a reflection of the relationship 212 between two BGP speakers. But the mere presence of BGP Role doesn't 213 automatically guarantee role agreement between two BGP peers. 215 To enforce correctness, the BGP Role check is used with a set of 216 constrains on how speakers' BGP Roles MUST corresponded. Of course, 217 each speaker MUST announce and accept the BGP Role capability in the 218 BGP OPEN message exchange. 220 If a speaker receives a BGP Role capability, it SHOULD check value of 221 the received capability with its own BGP Role. The allowed pairings 222 are (first a sender's Role, second the receiver's Role): 224 +--------------+----------------+ 225 | Sender Role | Receiver Role | 226 +--------------+----------------+ 227 | Peer | Peer | 228 | Provider | Customer | 229 | Customer | Provider | 230 | Internal | Internal | 231 | Complex | Complex | 232 +--------------+----------------+ 234 Table 2: Allowed Role Capabilities 236 In all other cases speaker MUST send a Role Mismatch Notification 237 (code 2, sub-code ). 239 6.1. Strict mode 241 A new BGP configuration option "strict mode" is defined with values 242 of true or false. If set to true, then the speaker MUST refuse to 243 establish a BGP session with peers which do not announce the BGP Role 244 capability in their OPEN message. If a speaker rejects a connection, 245 it MUST send a Connection Rejected Notification [RFC4486] 246 (Notification with error code 6, subcode 5). By default strict mode 247 SHOULD be set to false for backward compatibility with BGP speakers, 248 that do not yet support this mechanism. 250 7. Restrictions on the Complex role 252 The Complex role should be set only if the relationship between BGP 253 neighbors can not be described using simple Customer/Provider/Peer 254 roles. For a example, if neighbor is literal peer, but for some 255 prefixes it provides full transit; the complex role SHOULD be set on 256 both sides. In this case roles Customer/Provider/Peer should be set 257 on per-prefix basis, keeping the abstraction from filtering 258 mechanisms (Section 8). 260 If role is not Complex all per-prefix role settings MUST be ignored. 262 8. BGP Internal Only To Customer attribute 264 The Internal Only To Customer (iOTC) attribute is a new optional, 265 non-transitive BGP Path attribute with the Type Code . This 266 attribute has zero length as it is used only as a flag. 268 There are four rules for setting the iOTC attribute: 270 1. The iOTC attribute MUST be added to all incoming routes if the 271 receiver's Role is Customer or Peer; 273 2. The iOTC attribute MUST be added to all incoming routes if the 274 receiver's Role is Complex and the prefix Role is Customer or 275 Peer; 277 3. Routes with the iOTC attribute set MUST NOT be announced by a 278 sender whose Role is Customer or Peer; 280 4. Routes with the iOTC attribute set MUST NOT be announced if by a 281 sender whose Role is Complex and the prefix Role is Customer or 282 Peer; 284 These four rules provide mechanism that strongly prevents route leak 285 creation by an AS. 287 9. Compatibility with BGPsec 289 As the iOTC field is non-transitive, it is not seen by or signed by 290 BGPsec [I-D.ietf-sidr-bgpsec-protocol]. 292 10. Additional Considerations 294 As the BGP Role reflects the relationship between neighbors, it can 295 also have other uses. As an example, BGP Role might affect route 296 priority, or be used to distinguish borders of a network if a network 297 consists of multiple AS. 299 Though such uses may be worthwhile, they are not the goal of this 300 document. Note that such uses would require local policy control. 302 This document doesn't provide any security measures to check 303 correctness of per-prefix roles, so the Complex role should be used 304 with great caution. It is as dangerous as current BGP peering. 306 11. IANA Considerations 308 This document defines a new Capability Codes option [to be removed 309 upon publication: http://www.iana.org/assignments/capability-codes/ 310 capability-codes.xhtml] [RFC5492], named "BGP Role", assigned value 311 . The length of this capability is 1. 313 The BGP Role capability includes a Value field, for which IANA is 314 requested to create and maintain a new sub-registry called "BGP Role 315 Value". Assignments consist of Value and corresponding Role name. 316 Initially this registry is to be populated with the data in Table 1. 317 Future assignments may be made by a standard action procedure 318 [RFC5226]. 320 This document defines new subcode, "Role Mismatch", assigned value 321 in the OPEN Message Error subcodes registry [to be removed 322 upon publication: http://www.iana.org/assignments/bgp-parameters/bgp- 323 parameters.xhtml#bgp-parameters-6] [RFC4271]. 325 This document defines a new optional, non-transitive BGP Path 326 Attributes option, named "Internal Only To Customer", assigned value 327 [To be removed upon publication: 328 http://www.iana.org/assignments/bgp-parameters/bgp- 329 parameters.xhtml#bgp-parameters-2] [RFC4271]. The length of this 330 attribute is 0. 332 12. Security Considerations 334 This document proposes a mechanism for prevention of route leaks that 335 are the result of BGP policy misconfiguration. 337 Deliberate sending of a known conflicting BGP Role could be used to 338 sabotage a BGP connection. This is easily detectable. 340 BGP Role is disclosed only to an immediate BGP neighbor, so it will 341 not itself reveal any sensitive information to third parties. 343 13. Acknowledgments 345 The authors wish to thank Douglas Montgomery, Brian Dickson, and 346 Andrei Robachevsky for their contributions to a variant of this work. 348 14. References 350 14.1. Normative References 352 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 353 Requirement Levels", BCP 14, RFC 2119, 354 DOI 10.17487/RFC2119, March 1997, 355 . 357 [RFC4271] Rekhter, Y., Ed., Li, T., Ed., and S. Hares, Ed., "A 358 Border Gateway Protocol 4 (BGP-4)", RFC 4271, 359 DOI 10.17487/RFC4271, January 2006, 360 . 362 [RFC4486] Chen, E. and V. Gillet, "Subcodes for BGP Cease 363 Notification Message", RFC 4486, DOI 10.17487/RFC4486, 364 April 2006, . 366 [RFC5492] Scudder, J. and R. Chandra, "Capabilities Advertisement 367 with BGP-4", RFC 5492, DOI 10.17487/RFC5492, February 368 2009, . 370 14.2. Informative References 372 [I-D.ietf-grow-route-leak-problem-definition] 373 Sriram, K., Montgomery, D., McPherson, D., Osterweil, E., 374 and B. Dickson, "Problem Definition and Classification of 375 BGP Route Leaks", draft-ietf-grow-route-leak-problem- 376 definition-06 (work in progress), May 2016. 378 [I-D.ietf-idr-route-leak-detection-mitigation] 379 Sriram, K., Montgomery, D., Dickson, B., Patel, K., and A. 380 Robachevsky, "Methods for Detection and Mitigation of BGP 381 Route Leaks", draft-ietf-idr-route-leak-detection- 382 mitigation-03 (work in progress), May 2016. 384 [I-D.ietf-sidr-bgpsec-protocol] 385 Lepinski, M. and K. Sriram, "BGPsec Protocol 386 Specification", draft-ietf-sidr-bgpsec-protocol-15 (work 387 in progress), March 2016. 389 [RFC5226] Narten, T. and H. Alvestrand, "Guidelines for Writing an 390 IANA Considerations Section in RFCs", BCP 26, RFC 5226, 391 DOI 10.17487/RFC5226, May 2008, 392 . 394 Authors' Addresses 396 Alexander Azimov 397 Qrator Labs 399 Email: aa@qrator.net 401 Eugene Bogomazov 402 Qrator Labs 404 Email: eb@qrator.net 406 Randy Bush 407 Internet Initiative Japan 409 Email: randy@psg.com 410 Keyur Patel 411 Arrcus, Inc. 413 Email: keyur@arrcus.com 415 Kotikalapudi Sriram 416 US NIST 418 Email: ksriram@nist.gov