idnits 2.17.1 draft-ymbk-rpki-rtr-protocol-06.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- ** You're using the IETF Trust Provisions' Section 6.b License Notice from 12 Sep 2009 rather than the newer Notice from 28 Dec 2009. (See https://trustee.ietf.org/license-info/) -- The document has an IETF Trust Provisions (28 Dec 2009) Section 6.c(ii) Publication Limitation clause. If this document is intended for submission to the IESG for publication, this constitutes an error. 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 : ---------------------------------------------------------------------------- ** The abstract seems to contain references ([I-D.ietf-sidr-arch]), which it shouldn't. Please replace those with straight textual mentions of the documents in question. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year == Using lowercase 'not' together with uppercase 'MUST', 'SHALL', 'SHOULD', or 'RECOMMENDED' is not an accepted usage according to RFC 2119. Please use uppercase 'NOT' together with RFC 2119 keywords (if that is what you mean). Found 'MUST not' in this paragraph: Serial Number: A 32-bit monotonically increasing ordinal which wraps from 2^32-1 to 0. It denotes the logical version of a cache. A cache increments the value by one when it successfully updates its data from a parent cache or from primary RPKI data. As a cache is rcynicing, new incoming data, and implicit deletes, are marked with the new serial but MUST not be sent until the fetch is complete. A serial number is not commensurate between caches, nor need it be maintained across resets of the cache server. See [RFC1982] on DNS Serial Number Arithmetic for too much detail on serial number arithmetic. -- The document date (July 6, 2010) is 5043 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 (-13) exists of draft-ietf-sidr-arch-06 == Outdated reference: A later version (-09) exists of draft-ietf-sidr-repos-struct-01 Summary: 2 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 R. Bush 3 Internet-Draft IIJ 4 Intended status: Standards Track R. Austein 5 Expires: January 7, 2011 ISC 6 July 6, 2010 8 The RPKI/Router Protocol 9 draft-ymbk-rpki-rtr-protocol-06 11 Abstract 13 In order to formally validate the origin ASes of BGP announcements, 14 routers need a simple but reliable mechanism to receive RPKI 15 [I-D.ietf-sidr-arch] or analogous prefix origin data from a trusted 16 cache. This document describes a protocol to deliver validated 17 prefix origin data to routers over ssh. 19 Requirements Language 21 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 22 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 23 document are to be interpreted as described in RFC 2119 [RFC2119]. 25 Status of this Memo 27 This Internet-Draft is submitted to IETF in full conformance with the 28 provisions of BCP 78 and BCP 79. This document may not be modified, 29 and derivative works of it may not be created, and it may not be 30 published except as an Internet-Draft. 32 Internet-Drafts are working documents of the Internet Engineering 33 Task Force (IETF), its areas, and its working groups. Note that 34 other groups may also distribute working documents as Internet- 35 Drafts. 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 The list of current Internet-Drafts can be accessed at 43 http://www.ietf.org/ietf/1id-abstracts.txt. 45 The list of Internet-Draft Shadow Directories can be accessed at 46 http://www.ietf.org/shadow.html. 48 This Internet-Draft will expire on January 7, 2011. 50 Copyright Notice 52 Copyright (c) 2010 IETF Trust and the persons identified as the 53 document authors. All rights reserved. 55 This document is subject to BCP 78 and the IETF Trust's Legal 56 Provisions Relating to IETF Documents 57 (http://trustee.ietf.org/license-info) in effect on the date of 58 publication of this document. Please review these documents 59 carefully, as they describe your rights and restrictions with respect 60 to this document. Code Components extracted from this document must 61 include Simplified BSD License text as described in Section 4.e of 62 the Trust Legal Provisions and are provided without warranty as 63 described in the BSD License. 65 Table of Contents 67 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 4 68 2. Deployment Structure . . . . . . . . . . . . . . . . . . . . . 4 69 3. Operational Overview . . . . . . . . . . . . . . . . . . . . . 4 70 4. Protocol Data Units (PDUs) . . . . . . . . . . . . . . . . . . 5 71 4.1. Serial Notify . . . . . . . . . . . . . . . . . . . . . . 6 72 4.2. Serial Query . . . . . . . . . . . . . . . . . . . . . . . 6 73 4.3. Reset Query . . . . . . . . . . . . . . . . . . . . . . . 7 74 4.4. Cache Response . . . . . . . . . . . . . . . . . . . . . . 7 75 4.5. IPv4 Prefix . . . . . . . . . . . . . . . . . . . . . . . 8 76 4.6. IPv6 Prefix . . . . . . . . . . . . . . . . . . . . . . . 9 77 4.7. End of Data . . . . . . . . . . . . . . . . . . . . . . . 9 78 4.8. Cache Reset . . . . . . . . . . . . . . . . . . . . . . . 10 79 4.9. Error Report . . . . . . . . . . . . . . . . . . . . . . . 10 80 4.10. Fields of a PDU . . . . . . . . . . . . . . . . . . . . . 11 81 5. Protocol Sequences . . . . . . . . . . . . . . . . . . . . . . 12 82 5.1. Start or Restart . . . . . . . . . . . . . . . . . . . . . 12 83 5.2. Typical Exchange . . . . . . . . . . . . . . . . . . . . . 13 84 5.3. No Incremental Update Available . . . . . . . . . . . . . 14 85 5.4. Cache has No Data Available . . . . . . . . . . . . . . . 14 86 6. SSH Transport . . . . . . . . . . . . . . . . . . . . . . . . 15 87 7. Router-Cache Set-Up . . . . . . . . . . . . . . . . . . . . . 15 88 8. Deployment Scenarios . . . . . . . . . . . . . . . . . . . . . 16 89 9. Error Codes . . . . . . . . . . . . . . . . . . . . . . . . . 17 90 10. Security Considerations . . . . . . . . . . . . . . . . . . . 18 91 11. Glossary . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 92 12. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 19 93 13. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 19 94 14. References . . . . . . . . . . . . . . . . . . . . . . . . . . 20 95 14.1. Normative References . . . . . . . . . . . . . . . . . . . 20 96 14.2. Informative References . . . . . . . . . . . . . . . . . . 20 98 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . . 20 100 1. Introduction 102 In order to formally validate the origin ASes of BGP announcements, 103 routers need a simple but reliable mechanism to receive RPKI 104 [I-D.ietf-sidr-arch] or analogous formally validated prefix origin 105 data from a trusted cache. This document describes a protocol to 106 deliver validated prefix origin data to routers over ssh. 108 Section 2 describes the deployment structure and Section 3 then 109 presents an operational overview. The binary payloads of the 110 protocol are formally described in Section 4, and the expected PDU 111 sequences are described in Section 5. The transport protocol is 112 described in Section 6. Section 7 details how routers and caches are 113 configured to connect and authenticate. Section 8 describes likely 114 deployment scenarios. The traditional security and IANA 115 considerations end the document. 117 2. Deployment Structure 119 Deployment of the RPKI to reach routers has a three level structure 120 as follows: 122 Global RPKI: The authoritative data of the RPKI are published in a 123 distributed set of servers, RPKI publication repositories, e.g. 124 the IANA, RIRs, NIRs, and ISPs, see [I-D.ietf-sidr-repos-struct]. 126 Local Caches: A local set of one or more collected and verified non- 127 authoritative caches. A relying party, e.g. router or other 128 client, MUST have a formally authenticated trust relationship 129 with, and a secure transport channel to, any non-authoritative 130 cache(s) it uses. 132 Routers: A router fetches data from a local cache using the protocol 133 described in this document. It is said to be a client of the 134 cache. There are mechanisms for the router to assure itself of 135 the authenticity of the cache and to authenticate itself to the 136 cache. 138 3. Operational Overview 140 A router establishes and keeps open an authenticated connection to a 141 cache with which it has a client/server relationship. It is 142 configured with a semi-ordered list of caches, and establishes a 143 connection to the highest preference cache that accepts one. 145 Periodically, the router sends to the cache the serial number of the 146 highest numbered data record it has received from that cache, i.e. 147 the router's current serial number. When a router establishes a new 148 connection to a cache, or wishes to reset a current relationship, it 149 sends a Reset Query. 151 The Cache responds with all data records which have serial numbers 152 greater than that in the router's query. This may be the null set, 153 in which case the End of Data PDU is still sent. Note that 'greater' 154 must take wrap-around into account, see [RFC1982]. 156 When the router has received all data records from the cache, it sets 157 its current serial number to that of the serial number in the End of 158 Data PDU. 160 When the cache updates its database, it sends a Notify message to 161 every currently connected router. This is a hint that now would be a 162 good time for the router to poll for an update, but is only a hint. 163 The protocol requires the router to poll for updates periodically in 164 any case. 166 Strictly speaking, a router could track a cache simply by asking for 167 a complete data set every time it updates, but this would be very 168 inefficient. The serial number based incremental update mechanism 169 allows an efficient transfer of just the data records which have 170 changed since last update. As with any update protocol based on 171 incremental transfers, the router must be prepared to fall back to a 172 full transfer if for any reason the cache is unable to provide the 173 necessary incremental data. Unlike some incremental transfer 174 protocols, this protocol requires the router to make an explicit 175 request to start the fallback process; this is deliberate, as the 176 cache has no way of knowing whether the router has also established 177 sessions with other caches that may be able to provide better 178 service. 180 4. Protocol Data Units (PDUs) 182 The exchanges between the cache and the router are sequences of 183 exchanges of the following PDUs according to the rules described in 184 Section 5. 186 4.1. Serial Notify 188 The cache notifies the router that the cache has new data. 190 0 8 16 24 31 191 .-------------------------------------------. 192 | Protocol | PDU | | 193 | Version | Type | reserved = zero | 194 | 0 | 0 | | 195 +-------------------------------------------+ 196 | | 197 | Length=12 | 198 | | 199 +-------------------------------------------+ 200 | | 201 | Serial Number | 202 | | 203 `-------------------------------------------' 205 4.2. Serial Query 207 Serial Query: The router sends Serial Query to ask the cache for all 208 payload PDUs which have serial numbers higher than the serial number 209 in the Serial Query. 211 The cache replies to this query with a Cache Response PDU 212 (Section 4.4) if the cache has a record of the changes since the 213 serial number specified by the router. If there have been no changes 214 since the router last queried, the cache responds with an End Of Data 215 PDU. If the cache does not have the data needed to update the 216 router, perhaps because its records do not go back to the Serial 217 Number in the Serial Query, then it responds with a Cache Reset PDU 218 (Section 4.8). 220 0 8 16 24 31 221 .-------------------------------------------. 222 | Protocol | PDU | | 223 | Version | Type | reserved = zero | 224 | 0 | 1 | | 225 +-------------------------------------------+ 226 | | 227 | Length=12 | 228 | | 229 +-------------------------------------------+ 230 | | 231 | Serial Number | 232 | | 233 `-------------------------------------------' 235 4.3. Reset Query 237 Reset Query: The router tells the cache that it wants to receive the 238 total active, current, non-withdrawn, database. The cache responds 239 with a Cache Response PDU (Section 4.4). 241 0 8 16 24 31 242 .-------------------------------------------. 243 | Protocol | PDU | | 244 | Version | Type | reserved = zero | 245 | 0 | 2 | | 246 +-------------------------------------------+ 247 | | 248 | Length=8 | 249 | | 250 `-------------------------------------------' 252 4.4. Cache Response 254 Cache Response: The cache responds with zero or more payload PDUs. 255 When replying to a Serial Query request (Section 4.2), the cache 256 sends the set of all data records it has with serial numbers greater 257 than that sent by the client router. When replying to a Reset Query, 258 the cache sends the set of all data records it has; in this case the 259 withdraw/announce field in the payload PDUs MUST have the value 1 260 (announce). 262 0 8 16 24 31 263 .-------------------------------------------. 264 | Protocol | PDU | | 265 | Version | Type | reserved = zero | 266 | 0 | 3 | | 267 +-------------------------------------------+ 268 | | 269 | Length=8 | 270 | | 271 `-------------------------------------------' 273 4.5. IPv4 Prefix 275 0 8 16 24 31 276 .-------------------------------------------. 277 | Protocol | PDU | | 278 | Version | Type | Color | 279 | 0 | 4 | | 280 +-------------------------------------------+ 281 | | 282 | Length=20 | 283 | | 284 +-------------------------------------------+ 285 | | Prefix | Max | Data | 286 | Flags | Length | Length | Source | 287 | | 0..32 | 0..32 | RPKI/IRR | 288 +-------------------------------------------+ 289 | | 290 | IPv4 prefix | 291 | | 292 +-------------------------------------------+ 293 | | 294 | Autonomous System Number | 295 | | 296 `-------------------------------------------' 298 Due to the nature of the RPKI and the IRR, there can be multiple 299 identical IPvX PDUs. A router MUST be prepared to receive multiple 300 identical record announcements and MUST NOT consider a record to have 301 been deleted until it has received a corresponding number of 302 withdrawals or a reset is performed Hence the router will likely keep 303 an internal reference count on each IPvX PDU. 305 In the RPKI, nothing prevents a signing certificate from issuing two 306 identical ROAs, and nothing prohibits the existence of two identical 307 route: or route6: objects in the IRR. In this case there would be no 308 semantic difference between the objects, merely a process redundancy. 310 In the RPKI, there is also an actual need for what will appear to the 311 router as identical IPvX PDUs. This occurs when an upstream 312 certificate is being reissued or a site is changing providers, often 313 a 'make and break' situation. The ROA is identical in the router 314 sense, i.e. has the same {prefix, len, max-len, asn}, but has a 315 different validation path in the RPKI. This is important to the 316 RPKI, but not to the router. 318 The lowest order bit of the Flags field is 1 for an announcement and 319 0 for a withdrawal. 321 4.6. IPv6 Prefix 323 0 8 16 24 31 324 .-------------------------------------------. 325 | Protocol | PDU | | 326 | Version | Type | Color | 327 | 0 | 6 | | 328 +-------------------------------------------+ 329 | | 330 | Length=32 | 331 | | 332 +-------------------------------------------+ 333 | | Prefix | Max | Data | 334 | Flags | Length | Length | Source | 335 | | 0..128 | 0..128 | RPKI/IRR | 336 +-------------------------------------------+ 337 | | 338 +--- ---+ 339 | | 340 +--- IPv6 prefix ---+ 341 | | 342 +--- ---+ 343 | | 344 +-------------------------------------------+ 345 | | 346 | Autonomous System Number | 347 | | 348 `-------------------------------------------' 350 4.7. End of Data 352 End of Data: Cache tells router it has no more data for the request. 354 0 8 16 24 31 355 .-------------------------------------------. 356 | Protocol | PDU | | 357 | Version | Type | reserved = zero | 358 | 0 | 7 | | 359 +-------------------------------------------+ 360 | | 361 | Length=12 | 362 | | 363 +-------------------------------------------+ 364 | | 365 | Serial Number | 366 | | 367 `-------------------------------------------' 369 4.8. Cache Reset 371 The cache may respond to a Serial Query informing the router that the 372 cache cannot provide an incremental update starting from the serial 373 number specified by the router. The router must decide whether to 374 issue a Reset Query or switch to a different cache. 376 0 8 16 24 31 377 .-------------------------------------------. 378 | Protocol | PDU | | 379 | Version | Type | reserved = zero | 380 | 0 | 8 | | 381 +-------------------------------------------+ 382 | | 383 | Length=8 | 384 | | 385 `-------------------------------------------' 387 4.9. Error Report 389 This PDU is used by either party to report an error to the other. 391 The Error Number is described in Section 9. 393 If the error is not associated with any particular PDU, the Erroneous 394 PDU field should be empty and the Length of Encapsulated PDU field 395 should be zero. 397 The diagnostic text is optional, if not present the Length of Error 398 Text field should be zero. If error text is present, it SHOULD be a 399 string in US-ASCII, for maximum portability; if non-US-ASCII 400 characters are absolutely required, the error text MUST use UTF-8 401 encoding. 403 0 8 16 24 31 404 .-------------------------------------------. 405 | Protocol | PDU | | 406 | Version | Type | Error Number | 407 | 0 | 10 | | 408 +-------------------------------------------+ 409 | | 410 | Length | 411 | | 412 +-------------------------------------------+ 413 | | 414 | Length of Encapsulated PDU | 415 | | 416 +-------------------------------------------+ 417 | | 418 ~ Copy of Erroneous PDU ~ 419 | | 420 +-------------------------------------------+ 421 | | 422 | Length of Error Text | 423 | | 424 +-------------------------------------------+ 425 | | 426 | Arbitrary Text | 427 | of | 428 ~ Error Diagnostic Message ~ 429 | | 430 `-------------------------------------------' 432 4.10. Fields of a PDU 434 PDUs contain the following data elements: 436 Protocol Version: An ordinal, currently 0, denoting the version of 437 this protocol. 439 Serial Number: The serial number of the RPKI Cache when this ROA was 440 received from the cache's up-stream cache server or gathered from 441 the global RPKI. A cache increments its serial number when 442 completing an rcynic from a parent cache. See [RFC1982] on DNS 443 Serial Number Arithmetic for too much detail on serial number 444 arithmetic. 446 Length: A 32 bit ordinal which has as its value the count of the 447 bytes in the entire PDU, including the eight bytes of header which 448 end with the length field. 450 Color: An arbitrary 16 bit field that might be used in some way. 452 Flags: The lowest order bit of the Flags field is 1 for an 453 announcement and 0 for a withdrawal, whether this PDU announces a 454 new right to announce the prefix or withdraws a previously 455 announced right. A withdraw effectively deletes one previously 456 announced IPvX Prefix PDU with the exact same Prefix, Length, Max- 457 Len, ASN, Data Source, and Color. 459 Prefix Length: An ordinal denoting the shortest prefix allowed for 460 the prefix. 462 Max Length: An ordinal denoting the longest prefix allowed by the 463 prefix. This MUST NOT be less than the Prefix Length element. 465 Data Source: An ordinal denoting the source of the data, e.g. for 466 RPKI data, it is 0, for IRR data it is 1. 468 Prefix: The IPv4 or IPv6 prefix of the ROA. 470 Autonomous System Number: ASN allowed to announce this prefix, a 32 471 bit ordinal. 473 5. Protocol Sequences 475 The sequences of PDU transmissions fall into three conversations as 476 follows: 478 5.1. Start or Restart 480 Cache Router 481 ~ ~ 482 | <----- Reset Query -------- | R requests data 483 | | 484 | ----- Cache Response -----> | C confirms request 485 | ------- IPvX Prefix ------> | C sends zero or more 486 | ------- IPvX Prefix ------> | IPv4 and IPv6 Prefix 487 | ------- IPvX Prefix ------> | Payload PDUs 488 | ------ End of Data ------> | C sends End of Data 489 | | and sends new serial 490 ~ ~ 492 When a transport session is first established, the router sends a 493 Reset Query and the cache responds with a data sequence of all data 494 it contains. 496 This Reset Query sequence is also used when the router receives a 497 Cache Reset, chooses a new cache, or fears that it has otherwise lost 498 its way. 500 To limit the length of time a cache must keep the data necessary to 501 generate incremental updates, a router MUST send either a Serial 502 Query or a Reset Query no less frequently than once an hour. This 503 also acts as a keep alive at the application layer. 505 5.2. Typical Exchange 507 Cache Router 508 ~ ~ 509 | -------- Notify ----------> | (optional) 510 | | 511 | <----- Serial Query ------- | R requests data 512 | | 513 | ----- Cache Response -----> | C confirms request 514 | ------- IPvX Prefix ------> | C sends zero or more 515 | ------- IPvX Prefix ------> | IPv4 and IPv6 Prefix 516 | ------- IPvX Prefix ------> | Payload PDUs 517 | ------ End of Data ------> | C sends End of Data 518 | | and sends new serial 519 ~ ~ 521 The cache server SHOULD send a notify PDU with its current serial 522 number when the cache's serial changes, with the expectation that the 523 router MAY then issue a serial query earlier than it otherwise might. 524 This is analogous to DNS NOTIFY in [RFC1996]. The cache SHOULD rate 525 limit Serial Notifies to no more frequently than one per minute. 527 When the transport layer is up and either a timer has gone off in the 528 router, or the cache has sent a Notify, the router queries for new 529 data by sending a Serial Query, and the cache sends all data newer 530 than the serial in the Serial Query. 532 To limit the length of time a cache must keep old withdraws, a router 533 MUST send either a Serial Query or a Reset Query no less frequently 534 than once an hour. 536 5.3. No Incremental Update Available 538 Cache Router 539 ~ ~ 540 | <----- Serial Query ------ | R requests data 541 | ------- Cache Reset ------> | C cannot supply update 542 | | from specified serial 543 | <------ Reset Query ------- | R requests new data 544 | ----- Cache Response -----> | C confirms request 545 | ------- IPvX Prefix ------> | C sends zero or more 546 | ------- IPvX Prefix ------> | IPv4 and IPv6 Prefix 547 | ------- IPvX Prefix ------> | Payload PDUs 548 | ------ End of Data ------> | C sends End of Data 549 | | and sends new serial 550 ~ ~ 552 The cache may respond to a Serial Query with a Cache Reset, informing 553 the router that the cache cannot supply an incremental update from 554 the serial number specified by the router. This might be because the 555 cache has lost state, or because the router has waited too long 556 between polls and the cache has cleaned up old data that it no longer 557 believes it needs, or because the cache has run out of storage space 558 and had to expire some old data early. Regardless of how this state 559 arose, the cache replies with a Cache Reset to tell the router that 560 it cannot honor the request. When a router receives this, the router 561 SHOULD attempt to connect to any more preferred caches in its cache 562 list. If there are no more preferred caches it MUST issue a Reset 563 Query and get an entire new load from the cache. 565 5.4. Cache has No Data Available 567 Cache Router 568 ~ ~ 569 | <----- Serial Query ------ | R requests data 570 | ---- Error Report PDU ----> | C cannot supply update 571 ~ ~ 573 Cache Router 574 ~ ~ 575 | <----- Reset Query ------- | R requests data 576 | ---- Error Report PDU ----> | C cannot supply update 577 ~ ~ 579 The cache may respond to either a Serial Query or a Reset Query 580 informing the router that the cache cannot supply any update at all. 581 The most likely cause is that the cache has lost state, perhaps due 582 to a restart, and has not yet recovered. While it is possible that a 583 cache might go into such a state without dropping any of its active 584 sessions, a router is more likely to see this behavior when it 585 initially connects and issues a Reset Query while the cache is still 586 rebuilding its database. 588 When a router receives this kind of error, the router SHOULD attempt 589 to connect to any other caches in its cache list, in preference 590 order. If no other caches are available, the router MUST issue 591 periodic Reset Queries until it gets a new usable load from the 592 cache. 594 6. SSH Transport 596 The transport layer session between a router and a cache carries the 597 binary Protocol Data Units (PDUs) in a persistent SSH session. 599 To run over SSH, the client router first establishes an SSH transport 600 connection using the SSH transport protocol, and the client and 601 server exchange keys for message integrity and encryption. The 602 client then invokes the "ssh-userauth" service to authenticate the 603 application, as described in the SSH authentication protocol RFC 4252 604 [RFC4252]. Once the application has been successfully authenticated, 605 the client invokes the "ssh-connection" service, also known as the 606 SSH connection protocol. 608 After the ssh-connection service is established, the client opens a 609 channel of type "session", which results in an SSH session. 611 Once the SSH session has been established, the application invokes 612 the application transport as an SSH subsystem called "rpki-rtr". 613 Subsystem support is a feature of SSH version 2 (SSHv2) and is not 614 included in SSHv1. Running this protocol as an SSH subsystem avoids 615 the need for the application to recognize shell prompts or skip over 616 extraneous information, such as a system message that is sent at 617 shell start-up. 619 It is assumed that the router and cache have exchanged keys out of 620 band by some reasonably secured means. 622 7. Router-Cache Set-Up 624 A cache has the public authentication data for each router it is 625 configured to support. 627 A router may be configured to peer with a selection of caches, and a 628 cache may be configured to support a selection of routers. Each must 629 have the name of, and authentication data for, each each peer. In 630 addition, in a router, this list has a non-unique preference value 631 for each server in order of preference. The client router attempts 632 to establish a session with each potential serving cache in 633 preference order, and then starts to load data from the highest 634 preference cache to which it can connect and authenticate. The 635 router's list of caches has the following elements: 637 Preference: An ordinal denoting the router's preference to use that 638 cache, the lower the value the more preferred. 640 Name: The IP Address or fully qualified domain name of the cache. 642 Key: The public ssh key of the cache. 644 MyKey: The private ssh key of this client. 646 As caches can not be rigorously synchronous, a client which changes 647 servers can not combine data from different parent caches. 648 Therefore, when a lower preference cache becomes available, if 649 resources allow, it would be prudent for the client to start a new 650 buffer for that cache's data, and only switch to those data when that 651 buffer is fully up to date. 653 When a client loses connectivity to the cache it is currently using, 654 or otherwise decides to switch to a new cache, it SHOULD retain the 655 data from the previous cache and only switch to using the data from 656 the new cache once it has fully synchronized with it. It should do 657 this regardless of whether it has chosen a different cache or 658 established a new connection to the previous cache. However, a 659 configurable timer MUST be provided to bound how long it will retain 660 the "stale" data. 662 8. Deployment Scenarios 664 For illustration, we present three likely deployment scenarios. 666 Small End Site: The small multi-homed end site may wish to outsource 667 the RPKI cache to one or more of their upstream ISPs. They would 668 exchange authentication material with the ISP using some out of 669 band mechanism, and their router(s) would connect to one or more 670 up-streams' caches. The ISPs would likely deploy caches intended 671 for customer use separately from the caches with which their own 672 BGP speakers peer. 674 Large End Site: A larger multi-homed end site might run one or more 675 caches, arranging them in a hierarchy of client caches, each 676 fetching from a serving cache which is closer to the global RPKI. 677 They might configure fall-back peerings to up-stream ISP caches. 679 ISP Backbone: A large ISP would likely have one or more redundant 680 caches in each major PoP, and these caches would fetch from each 681 other in an ISP-dependent topology so as not to place undue load 682 on the global RPKI publication infrastructure. 684 Experience with large DNS cache deployments has shown that complex 685 topologies are ill-advised as it is easy to make errors in the graph, 686 e.g. not maintaining a loop-free condition. 688 Of course, these are illustrations and there are other possible 689 deployment strategies. It is expected that minimizing load on the 690 global RPKI servers will be a major consideration. 692 To keep load on global RPKI services from unnecessary peaks, it is 693 recommended that primary caches which load from the distributed 694 global RPKI not do so all at the same times, e.g. on the hour. 695 Choose a random time, perhaps the ISP's AS number modulo 60 and 696 jitter the inter-fetch timing. 698 9. Error Codes 700 This section contains a preliminary list of error codes. The authors 701 expect additions to this section during development of the initial 702 implementations. Eventually, these error codes will probably need to 703 reside in an IANA registry. 705 0: Reserved. 707 1: Internal Error: The party reporting the error experienced some 708 kind of internal error unrelated to protocol operation (ran out of 709 memory, a coding assertion failed, et cetera). 711 2: No Data Available: The cache believes itself to be in good 712 working order, but is unable to answer either a Serial Query or a 713 Reset Query because it has no useful data available at this time. 714 This is likely to be a temporary error, and most likely indicates 715 that the cache has not yet completed pulling down an initial 716 current data set from the global RPKI system after some kind of 717 event that invalidated whatever data it might have previously held 718 (reboot, network partition, etcetera). 720 10. Security Considerations 722 As this document describes a security protocol, many aspects of 723 security interest are described in the relevant sections. This 724 section points out issues which may not be obvious in other sections. 726 Cache Validation: In order for a collection of caches as described 727 in Section 8 to guarantee a consistent view, they need to be given 728 consistent trust anchors to use in their internal validation 729 process. Distribution of a consistent trust anchor is assumed to 730 be out of band. 732 Cache Peer Identification: The router initiates an ssh transport 733 session to a cache, which it identifies by either IP address or 734 fully qualified domain name. Be aware that a DNS or address 735 spoofing attack could make the correct cache unreachable. No 736 session would be established, as the authorization keys would not 737 match. 739 Transport Security: The RPKI relies on object, not server or 740 transport, trust. I.e. the IANA root trust anchor is distributed 741 to all caches through some out of band means, and can then be used 742 by each cache to validate certificates and ROAs all the way down 743 the tree. The inter-cache relationships are based on this object 744 security model, hence the inter-cache transport can be lightly 745 protected. 747 But this protocol document assumes that the routers can not do the 748 validation cryptography. Hence the last link, from cache to 749 router, is secured by server authentication and transport level 750 security. This is dangerous, as server authentication and 751 transport have very different threat models than object security. 753 So the strength of the trust relationship and the transport 754 between the router(s) and the cache(s) are critical. You're 755 betting your routing on this. 757 While we can not say the cache must be on the same LAN, if only 758 due to the issue of an enterprise wanting to off-load the cache 759 task to their upstream ISP(s), locality, trust, and control are 760 very critical issues here. The cache(s) really SHOULD be as 761 close, in the sense of controlled and protected (against DDoS, 762 MITM) transport, to the router(s) as possible. It also SHOULD be 763 topologically close so that a minimum of validated routing data 764 are needed to bootstrap a router's access to a cache. 766 11. Glossary 768 The following terms are used with special meaning: 770 Global RPKI: The authoritative data of the RPKI are published in a 771 distributed set of servers at the IANA, RIRs, NIRs, and ISPs, see 772 [I-D.ietf-sidr-repos-struct]. 774 Non-authorative Cache: A coalesced copy of the RPKI which is 775 periodically fetched/refreshed directly or indirectly from the 776 global RPKI using the [rcynic] protocol/tools 778 Cache: The rcynic system is used to gather the distributed data of 779 the RPKI into a validated cache. Trusting this cache further is a 780 matter between the provider of the cache and a relying party. 782 Serial Number: A 32-bit monotonically increasing ordinal which wraps 783 from 2^32-1 to 0. It denotes the logical version of a cache. A 784 cache increments the value by one when it successfully updates its 785 data from a parent cache or from primary RPKI data. As a cache is 786 rcynicing, new incoming data, and implicit deletes, are marked 787 with the new serial but MUST not be sent until the fetch is 788 complete. A serial number is not commensurate between caches, nor 789 need it be maintained across resets of the cache server. See 790 [RFC1982] on DNS Serial Number Arithmetic for too much detail on 791 serial number arithmetic. 793 12. IANA Considerations 795 This document requests the IANA to create a registry for PDU types. 797 This document requests the IANA to create a registry for Data Source 798 Codes. 800 This document requests the IANA to create a registry for Error Codes. 802 In addition, a registry for Version Numbers would be needed if new 803 Version Number is defined in a new RFC. 805 Note to RFC Editor: this section may be replaced on publication as an 806 RFC. 808 13. Acknowledgments 810 The authors wish to thank Steve Bellovin, Rex Fernando, Russ Housley, 811 Pradosh Mohapatra, Keyur Patel, Sandy Murphy, Megumi Ninomiya, Robert 812 Raszuk, John Scudder, Ruediger Volk, David Ward, and Bert Wijnen. 814 14. References 816 14.1. Normative References 818 [RFC1982] Elz, R. and R. Bush, "Serial Number Arithmetic", RFC 1982, 819 August 1996. 821 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 822 Requirement Levels", RFC 2119, BCP 14, March 1997. 824 [RFC4252] Ylonen, T. and C. Lonvick, "The Secure Shell (SSH) 825 Authentication Protocol", RFC 4252, January 2006. 827 [rcynic] Austein, R., "rcynic protocol", 828 . 830 14.2. Informative References 832 [I-D.ietf-sidr-arch] 833 Lepinski, M. and S. Kent, "An Infrastructure to Support 834 Secure Internet Routing", draft-ietf-sidr-arch-06 (work in 835 progress), March 2009. 837 [I-D.ietf-sidr-repos-struct] 838 Huston, G., Loomans, R., and G. Michaelson, "A Profile for 839 Resource Certificate Repository Structure", 840 draft-ietf-sidr-repos-struct-01 (work in progress), 841 October 2008. 843 [RFC1996] Vixie, P., "A Mechanism for Prompt Notification of Zone 844 Changes (DNS NOTIFY)", RFC 1996, August 1996. 846 Authors' Addresses 848 Randy Bush 849 Internet Initiative Japan, Inc. 850 5147 Crystal Springs 851 Bainbridge Island, Washington 98110 852 US 854 Phone: +1 206 780 0431 x1 855 Email: randy@psg.com 856 Rob Austein 857 Internet Systems Consortium 858 950 Charter Street 859 Redwood City, CA 94063 860 USA 862 Email: sra@isc.org