idnits 2.17.1 draft-ietf-dots-data-channel-17.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 : ---------------------------------------------------------------------------- ** There are 22 instances of too long lines in the document, the longest one being 8 characters in excess of 72. ** The abstract seems to contain references ([I-D.ietf-netmod-acl-model], [I-D.ietf-dots-signal-channel]), 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 == Line 459 has weird spacing: '...er-port ine...' == Line 460 has weird spacing: '...er-port ine...' == Line 542 has weird spacing: '...warding ide...' -- The document date (July 17, 2018) is 2103 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) -- Looks like a reference, but probably isn't: '1' on line 1936 -- Looks like a reference, but probably isn't: '6' on line 1936 -- Looks like a reference, but probably isn't: '17' on line 1936 -- Looks like a reference, but probably isn't: '58' on line 1936 == Outdated reference: A later version (-41) exists of draft-ietf-dots-signal-channel-20 == Outdated reference: A later version (-21) exists of draft-ietf-netmod-acl-model-19 ** Obsolete normative reference: RFC 5246 (Obsoleted by RFC 8446) ** Obsolete normative reference: RFC 7230 (Obsoleted by RFC 9110, RFC 9112) ** Obsolete normative reference: RFC 7525 (Obsoleted by RFC 9325) == Outdated reference: A later version (-18) exists of draft-ietf-dots-architecture-06 == Outdated reference: A later version (-22) exists of draft-ietf-dots-requirements-14 -- Obsolete informational reference (is this intentional?): RFC 4960 (Obsoleted by RFC 9260) -- Obsolete informational reference (is this intentional?): RFC 5389 (Obsoleted by RFC 8489) Summary: 5 errors (**), 0 flaws (~~), 8 warnings (==), 7 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 DOTS T. Reddy, Ed. 3 Internet-Draft McAfee 4 Intended status: Standards Track M. Boucadair, Ed. 5 Expires: January 18, 2019 Orange 6 K. Nishizuka 7 NTT Communications 8 L. Xia 9 Huawei 10 P. Patil 11 Cisco 12 A. Mortensen 13 Arbor Networks, Inc. 14 N. Teague 15 Verisign, Inc. 16 July 17, 2018 18 Distributed Denial-of-Service Open Threat Signaling (DOTS) Data Channel 19 Specification 20 draft-ietf-dots-data-channel-17 22 Abstract 24 The document specifies a Distributed Denial-of-Service Open Threat 25 Signaling (DOTS) data channel used for bulk exchange of data that 26 cannot easily or appropriately communicated through the DOTS signal 27 channel under attack conditions. 29 This is a companion document to the DOTS signal channel 30 specification. 32 Editorial Note (To be removed by RFC Editor) 34 Please update these statements with the RFC number to be assigned to 35 this document: 37 o "This version of this YANG module is part of RFC XXXX;" 39 o "RFC XXXX: Distributed Denial-of-Service Open Threat Signaling 40 (DOTS) Data Channel Specification"; 42 o reference: RFC XXXX 44 Please update these statements with the RFC number to be assigned to 45 the following documents: 47 o "RFC YYYY: Distributed Denial-of-Service Open Threat Signaling 48 (DOTS) Signal Channel Specification" (used to be 49 [I-D.ietf-dots-signal-channel]) 51 o "RFC ZZZZ: Network Access Control List (ACL) YANG Data Model" 52 (used to be [I-D.ietf-netmod-acl-model]) 54 Please update the "revision" date of the YANG module. 56 Status of This Memo 58 This Internet-Draft is submitted in full conformance with the 59 provisions of BCP 78 and BCP 79. 61 Internet-Drafts are working documents of the Internet Engineering 62 Task Force (IETF). Note that other groups may also distribute 63 working documents as Internet-Drafts. The list of current Internet- 64 Drafts is at https://datatracker.ietf.org/drafts/current/. 66 Internet-Drafts are draft documents valid for a maximum of six months 67 and may be updated, replaced, or obsoleted by other documents at any 68 time. It is inappropriate to use Internet-Drafts as reference 69 material or to cite them other than as "work in progress." 71 This Internet-Draft will expire on January 18, 2019. 73 Copyright Notice 75 Copyright (c) 2018 IETF Trust and the persons identified as the 76 document authors. All rights reserved. 78 This document is subject to BCP 78 and the IETF Trust's Legal 79 Provisions Relating to IETF Documents 80 (https://trustee.ietf.org/license-info) in effect on the date of 81 publication of this document. Please review these documents 82 carefully, as they describe your rights and restrictions with respect 83 to this document. Code Components extracted from this document must 84 include Simplified BSD License text as described in Section 4.e of 85 the Trust Legal Provisions and are provided without warranty as 86 described in the Simplified BSD License. 88 Table of Contents 90 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 91 2. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 5 92 3. DOTS Data Channel . . . . . . . . . . . . . . . . . . . . . . 6 93 3.1. Design Overview . . . . . . . . . . . . . . . . . . . . . 6 94 3.2. DOTS Server(s) Discovery . . . . . . . . . . . . . . . . 8 95 3.3. NAT Considerations . . . . . . . . . . . . . . . . . . . 8 96 3.4. DOTS Gateways . . . . . . . . . . . . . . . . . . . . . . 8 97 3.5. Detect and Prevent Infinite Loops . . . . . . . . . . . . 9 98 3.6. Stale Entries . . . . . . . . . . . . . . . . . . . . . . 10 99 4. DOTS Data Channel YANG Module . . . . . . . . . . . . . . . . 10 100 4.1. Tree Structure . . . . . . . . . . . . . . . . . . . . . 10 101 4.2. Filtering Fields . . . . . . . . . . . . . . . . . . . . 14 102 4.3. YANG Module . . . . . . . . . . . . . . . . . . . . . . . 21 103 5. Managing DOTS Clients . . . . . . . . . . . . . . . . . . . . 33 104 5.1. Registering DOTS Clients . . . . . . . . . . . . . . . . 33 105 5.2. Uregistering DOTS Clients . . . . . . . . . . . . . . . . 36 106 6. Managing DOTS Aliases . . . . . . . . . . . . . . . . . . . . 37 107 6.1. Create Aliases . . . . . . . . . . . . . . . . . . . . . 37 108 6.2. Retrieve Installed Aliases . . . . . . . . . . . . . . . 41 109 6.3. Delete Aliases . . . . . . . . . . . . . . . . . . . . . 43 110 7. Managing DOTS Filtering Rules . . . . . . . . . . . . . . . . 43 111 7.1. Retrieve DOTS Filtering Capabilities . . . . . . . . . . 43 112 7.2. Install Filtering Rules . . . . . . . . . . . . . . . . . 45 113 7.3. Retrieve Installed Filtering Rules . . . . . . . . . . . 48 114 7.4. Remove Filtering Rules . . . . . . . . . . . . . . . . . 49 115 8. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 50 116 9. Contributors . . . . . . . . . . . . . . . . . . . . . . . . 50 117 10. Security Considerations . . . . . . . . . . . . . . . . . . . 50 118 11. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 52 119 12. References . . . . . . . . . . . . . . . . . . . . . . . . . 52 120 12.1. Normative References . . . . . . . . . . . . . . . . . . 52 121 12.2. Informative References . . . . . . . . . . . . . . . . . 53 122 Appendix A. Sample Examples: Filtering Fragments . . . . . . . . 54 123 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 58 125 1. Introduction 127 A distributed denial-of-service (DDoS) attack is an attempt to make 128 machines or network resources unavailable to their intended users. 129 In most cases, sufficient scale can be achieved by compromising 130 enough end-hosts and using those infected hosts to perpetrate and 131 amplify the attack. The victim of such attack can be an application 132 server, a router, a firewall, an entire network, etc. 134 As discussed in [I-D.ietf-dots-requirements], the lack of a common 135 method to coordinate a real-time response among involved actors and 136 network domains inhibits the speed and effectiveness of DDoS attack 137 mitigation. From that standpoint, DDoS Open Threat Signaling (DOTS) 138 defines an architecture that allows a DOTS client to send requests to 139 a DOTS server for DDoS attack mitigation 140 [I-D.ietf-dots-architecture]. The DOTS approach is thus meant to 141 minimize the impact of DDoS attacks, thereby contributing to the 142 enforcement of more efficient defensive if not proactive security 143 strategies. To that aim, DOTS defines two channels: the signal and 144 the data channels (Figure 1). 146 +---------------+ +---------------+ 147 | | <------- Signal Channel ------> | | 148 | DOTS Client | | DOTS Server | 149 | | <======= Data Channel ======> | | 150 +---------------+ +---------------+ 152 Figure 1: DOTS Channels 154 The DOTS signal channel is used to carry information about a device 155 or a network (or a part thereof) that is under a DDoS attack. Such 156 information is sent by a DOTS client to an upstream DOTS server so 157 that appropriate mitigation actions are undertaken on traffic deemed 158 suspicious. The DOTS signal channel is further elaborated in 159 [I-D.ietf-dots-signal-channel]. 161 As for the DOTS data channel, it is used for infrequent bulk data 162 exchange between DOTS agents to significantly improve the 163 coordination of all the parties involved in the response to the 164 attack. Section 2 of [I-D.ietf-dots-architecture] mentions that the 165 DOTS data channel is used to perform the following tasks: 167 o Creating aliases for resources for which mitigation may be 168 requested. 170 A DOTS client may submit to its DOTS server a collection of 171 prefixes which it would like to refer to by an alias when 172 requesting mitigation. The DOTS server can respond to this 173 request with either a success or failure response (see Section 2 174 in [I-D.ietf-dots-architecture]). 176 Refer to Section 6 for more details. 178 o Filter management, which enables a DOTS client to request the 179 installation or withdrawal of traffic filters, dropping or rate- 180 limiting unwanted traffic, and permitting white-listed traffic. A 181 DOTS client is entitled to instruct filtering rules only on IP 182 resources that belong to its domain. 184 Sample use cases for populating black- or white-list filtering 185 rules are detailed hereafter: 187 * If a network resource (DOTS client) detects a potential DDoS 188 attack from a set of IP addresses, the DOTS client informs its 189 servicing DOTS gateway of all suspect IP addresses that need to 190 be blocked or black-listed for further investigation. The DOTS 191 client could also specify a list of protocols and port numbers 192 in the black-list rule. 194 The DOTS gateway then propagates the black-listed IP addresses 195 to a DOTS server which will undertake appropriate actions so 196 that traffic originated by these IP addresses to the target 197 network (specified by the DOTS client) is blocked. 199 * A network, that has partner sites from which only legitimate 200 traffic arrives, may want to ensure that the traffic from these 201 sites is not subjected to DDoS attack mitigation. The DOTS 202 client uses the DOTS data channel to convey the white-listed IP 203 prefixes of the partner sites to its DOTS server. 205 The DOTS server uses this information to white-list flows 206 originated by such IP prefixes and which reach the network. 208 Refer to Section 7 for more details. 210 2. Terminology 212 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 213 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 214 document are to be interpreted as described in [RFC2119]. 216 The reader should be familiar with the terms defined in 217 [I-D.ietf-dots-requirements]. 219 The terminology for describing YANG data modules is defined in 220 [RFC7950]. The meaning of the symbols in tree diagrams is defined in 221 [RFC8340]. 223 This document generalizes the notion of Access Control List (ACL) so 224 that it is not device-specific [I-D.ietf-netmod-acl-model]. As such, 225 this document defines an ACL as an ordered set of rules that is used 226 to filter traffic. Each rule is represented by an Access Control 227 Entry (ACE). ACLs communicated via the DOTS data channel are not 228 bound to a device interface. 230 For the sake of simplicity, all of the examples in this document use 231 "/restconf" as the discovered RESTCONF API root path. Many protocol 232 header lines and message-body text within examples throughout the 233 document are split into multiple lines for display purposes only. 234 When a line ends with backslash ('\') as the last character, the line 235 is wrapped for display purposes. It is to be considered to be joined 236 to the next line by deleting the backslash, the following line break, 237 and the leading whitespace of the next line. 239 3. DOTS Data Channel 241 3.1. Design Overview 243 Unlike the DOTS signal channel, which must remain operational even 244 when confronted with signal degradation due to packets loss, the DOTS 245 data channel is not expected to be fully operational at all times, 246 especially when a DDoS attack is underway. The requirements for a 247 DOTS data channel protocol are documented in 248 [I-D.ietf-dots-requirements]. 250 This specification does not require an order of DOTS signal and data 251 channel creations nor mandates a time interval between them. These 252 considerations are implementation- and deployment-specific. 254 As the primary function of the data channel is data exchange, a 255 reliable transport mode is required in order for DOTS agents to 256 detect data delivery success or failure. This document uses RESTCONF 257 [RFC8040] over TLS [RFC5246] over TCP as the DOTS data channel 258 protocol. The abstract layering of DOTS data channel is shown in 259 Figure 2. 261 +-------------------+ 262 | DOTS Data Channel | 263 +-------------------+ 264 | RESTCONF | 265 +-------------------+ 266 | TLS | 267 +-------------------+ 268 | TCP | 269 +-------------------+ 270 | IP | 271 +-------------------+ 273 Figure 2: Abstract Layering of DOTS Data Channel 275 The HTTP POST, PUT, PATCH, and DELETE methods are used to edit data 276 resources represented by DOTS data channel YANG data modules. These 277 basic edit operations allow the DOTS data channel running 278 configuration to be altered by a DOTS client. 280 DOTS data channel configuration information as well as state 281 information can be retrieved with the GET method. An HTTP status- 282 line header field is returned for each request to report success or 283 failure for RESTCONF operations (Section 5.4 of [RFC8040]). The 284 "error-tag" provides more information about encountered errors 285 (Section 7 of [RFC8040]). 287 DOTS clients perform the root resource discovery procedure discussed 288 in Section 3.1 of [RFC8040] to determine the root of the RESTCONF 289 API. After discovering the RESTCONF API root, a DOTS client uses 290 this value as the initial part of the path in the request URI, in any 291 subsequent request to the DOTS server. The DOTS server may support 292 the retrieval of the YANG modules it supports (Section 3.7 in 293 [RFC8040]). For example, a DOTS client may use RESTCONF to retrieve 294 the vendor-specific YANG modules supported by its DOTS server. 296 JavaScript Object Notation (JSON) [RFC8259] payload is used to 297 propagate the DOTS data channel specific payload messages that carry 298 request parameters and response information, such as errors. This 299 specification uses the encoding rules defined in [RFC7951] for 300 representing DOTS data channel configuration data using YANG 301 (Section 4) as JSON text. 303 A DOTS client registers itself to its DOTS server(s) in order to set 304 up DOTS data channel-related configuration data and receive state 305 data (i.e., non-configuration data) from the DOTS server(s) 306 (Section 5). Mutual authentication and coupling of signal and data 307 channels are specified in [I-D.ietf-dots-signal-channel]. 309 A single DOTS data channel between DOTS agents can be used to 310 exchange multiple requests and multiple responses. To reduce DOTS 311 client and DOTS server workload, DOTS clients SHOULD re-use the same 312 TLS session. While the communication to the DOTS server is 313 quiescent, the DOTS client MAY probe the server to ensure it has 314 maintained cryptographic state. Such probes can also keep alive 315 firewall and/or NAT bindings. A TLS heartbeat [RFC6520] verifies 316 that the DOTS server still has TLS state by returning a TLS message. 318 A DOTS server may detect conflicting filtering requests from distinct 319 DOTS clients which belong to the same domain. For example, a DOTS 320 client could request to blacklist a prefix by specifying the source 321 prefix, while another DOTS client could request to whitelist that 322 same source prefix, but both having the same destination prefix. It 323 is out of scope of this specification to recommend the behavior to 324 follow for handling conflicting requests (e.g., reject all, reject 325 the new request, notify an administrator for validation). DOTS 326 servers SHOULD support a configuration parameter to indicate the 327 behavior to follow when a conflict is detected. Section 7.2 328 specifies the behavior when no instruction is supplied to a DOTS 329 server. 331 How filtering rules instantiated on a DOTS server are translated into 332 network configurations actions is out of scope. 334 3.2. DOTS Server(s) Discovery 336 This document assumes that DOTS clients are provisioned with the 337 reachability information of their DOTS server(s) using a variety of 338 means (e.g., local configuration, or dynamic means such as DHCP). 339 The specification of such means are out of scope of this document. 341 Likewise, it is out of scope of this document to specify the behavior 342 to follow by a DOTS client to place its requests (e.g., contact all 343 servers, select one server among the list) when multiple DOTS servers 344 are provisioned. 346 3.3. NAT Considerations 348 In deployments where one or more translators (e.g., NAT44, NAT64, 349 NPTv6) are enabled between the client's network and the DOTS server, 350 DOTS data channel messages forwarded to a DOTS server must not 351 include internal IP addresses/prefixes and/or port numbers; external 352 addresses/prefixes and/or port numbers as assigned by the translator 353 MUST be used instead. This document does not make any recommendation 354 about possible translator discovery mechanisms. The following are 355 some (non-exhaustive) deployment examples that may be considered: 357 o Port Control Protocol (PCP) [RFC6887] or Session Traversal 358 Utilities for NAT (STUN) [RFC5389] may be used to retrieve the 359 external addresses/prefixes and/or port numbers. Information 360 retrieved by means of PCP or STUN will be used to feed the DOTS 361 data channel messages that will be sent to a DOTS server. 363 o A DOTS gateway may be co-located with the translator. The DOTS 364 gateway will need to update the DOTS messages, based upon the 365 local translator's binding table. 367 3.4. DOTS Gateways 369 When a server-domain DOTS gateway is involved in DOTS data channel 370 exchanges, the same considerations for manipulating the 'cdid' 371 (client domain identifier) parameter specified in 372 [I-D.ietf-dots-signal-channel] MUST be followed by DOTS agents. As a 373 reminder, 'cdid' is meant to assist the DOTS server to enforce some 374 policies (e.g., limit the number of filtering rules per DOTS client 375 or per DOTS client domain). A loop detect mechanism for DOTS 376 gateways is specified in Section 3.5. 378 If a DOTS gateway is involved, the DOTS gateway verifies that the 379 DOTS client is authorized to undertake a data channel action (e.g., 380 instantiate filtering rules). If the DOTS client is authorized, it 381 propagates the rules to the upstream DOTS server. Likewise, the DOTS 382 server verifies that the DOTS gateway is authorized to relay data 383 channel actions. For example, to create or purge filters, a DOTS 384 client sends its request to its DOTS gateway. The DOTS gateway 385 validates the rules in the request and proxies the requests 386 containing the filtering rules to its DOTS server. When the DOTS 387 gateway receives the associated response from the DOTS server, it 388 propagates the response back to the DOTS client. 390 3.5. Detect and Prevent Infinite Loops 392 In order to detect and prevent infinite loops, DOTS gateways MUST 393 support the procedure defined in Section 5.7.1 of [RFC7230]. In 394 particular, each intermediate DOTS gateway MUST check that none of 395 its own information (e.g., server names, literal IP addresses) is 396 present in the "Via" header of a DOTS message it receives: 398 o If it detects that its own information is present in the "Via" 399 header, the DOTS gateway MUST NOT forward the DOTS message. 400 Messages that cannot be forwarded because of a loop SHOULD be 401 logged with a "508 Loop Detected" status-line returned sent back 402 to the DOTS peer. The structure of the reported error is depicted 403 in Figure 3. 405 error-tag: loop-detected 406 error-type: transport, application 407 error-severity: error 408 error-info: : A copy of the Via header when 409 the loop was detected. 410 Description: An infinite loop has been detected when forwarding 411 a requests via a proxy. 413 Figure 3: Loop Detected Error 415 It is RECOMMENDED that DOTS clients and gateways support means to 416 alert administrators about loop errors so that appropriate actions 417 are undertaken. 419 o Otherwise, the DOTS agent MUST update or insert the "Via" header 420 by appending its own information. 422 Unless configured otherwise, DOTS gateways at the boundaries of a 423 DOTS client domain SHOULD remove the previous "Via" header 424 information after checking for a loop before forwarding. This 425 behavior is required for topology hiding purposes but also to 426 minimizing potential conflicts that may arise if overlapping 427 information is used in distinct DOTS domains (e.g., private IPv4 428 addresses, non globally unique aliases). 430 3.6. Stale Entries 432 In order to avoid stale entries, a lifetime is associated with alias 433 and filtering entries created by DOTS clients. Also, DOTS servers 434 may track the inactivity timeout of DOTS clients to detect stale 435 entries. 437 4. DOTS Data Channel YANG Module 439 4.1. Tree Structure 441 The DOTS data channel YANG module (ietf-dots-data-channel) allows a 442 DOTS client to manage aliases for resources for which mitigation may 443 be requested. Such aliases may be used in subsequent DOTS signal 444 channel exchanges to refer more efficiently to the resources under 445 attack. 447 The tree structure for the DOTS alias is depicted in Figure 4. 449 module: ietf-dots-data-channel 450 +--rw dots-data 451 +--rw dots-client* [cuid] 452 | +--rw cuid string 453 | +--rw cdid? string 454 | +--rw aliases 455 | | +--rw alias* [name] 456 | | +--rw name string 457 | | +--rw target-prefix* inet:ip-prefix 458 | | +--rw target-port-range* [lower-port upper-port] 459 | | | +--rw lower-port inet:port-number 460 | | | +--rw upper-port inet:port-number 461 | | +--rw target-protocol* uint8 462 | | +--rw target-fqdn* inet:domain-name 463 | | +--rw target-uri* inet:uri 464 | | +--ro pending-lifetime? int32 465 | +--rw acls 466 | ... 467 +--ro capabilities 468 ... 470 Figure 4: DOTS Alias Subtree 472 Also, the 'ietf-dots-data-channel' module allows DOTS clients to 473 manage filtering rules. Examples of filtering management in a DOTS 474 context include, but not limited to: 476 o Black-list management, which enables a DOTS client to inform a 477 DOTS server about sources from which traffic should be discarded. 479 o White-list management, which enables a DOTS client to inform a 480 DOTS server about sources from which traffic should always be 481 accepted. 483 o Filter management, which enables a DOTS client to request the 484 installation or withdrawal of traffic filters, dropping or rate- 485 limiting unwanted traffic and permitting white-listed traffic. 487 The tree structure for the DOTS filtering entries is depicted in 488 Figure 5. 490 Early versions of this document investigated to what extent 491 augmenting 'ietf-access-control-list' meet DOTS requirements, but 492 that design approach was abandoned because it does not support 493 meeting many of DOTS requirements, e.g., 495 o Retrieve a filtering entry (or all entries) created by a DOTS 496 client. 498 o Delete a filtering entry that was instantiated by a DOTS client. 500 DOTS filtering entries (i.e., Access Control List (ACL)) mimic the 501 structure specified in [I-D.ietf-netmod-acl-model]. Concretely, DOTS 502 agents are assumed to manipulate an ordered list of ACLs; each ACL 503 contains a separately ordered list of Access Control Entries (ACEs). 504 Each ACE has a group of match and a group of action criteria. 506 Once all the ACE entries have been iterated though with no match, 507 then all the following ACL's ACE entries are iterated through until 508 the first match at which point the specified action is applied. If 509 there is no match, then there is no action to be taken against the 510 packet. 512 module: ietf-dots-data-channel 513 +--rw dots-data 514 +--rw dots-client* [cuid] 515 | +--rw cuid string 516 | +--rw cdid? string 517 | +--rw aliases 518 | | ... 519 | +--rw acls 520 | +--rw acl* [name] 521 | +--rw name string 522 | +--rw type? ietf-acl:acl-type 523 | +--rw activation-type? enumeration 524 | +--ro pending-lifetime? int32 525 | +--rw aces 526 | +--rw ace* [name] 527 | +--rw name string 528 | +--rw matches 529 | | +--rw (l3)? 530 | | | +--:(ipv4) 531 | | | | ... 532 | | | +--:(ipv6) 533 | | | ... 534 | | +--rw (l4)? 535 | | +--:(tcp) 536 | | | ... 537 | | +--:(udp) 538 | | | ... 539 | | +--:(icmp) 540 | | ... 541 | +--rw actions 542 | | +--rw forwarding identityref 543 | | +--rw rate-limit? decimal64 544 | +--ro statistics 545 | +--ro matched-packets? yang:counter64 546 | +--ro matched-octets? yang:counter64 547 +--ro capabilities 548 ... 550 Figure 5: DOTS ACLs Subtree 552 Filtering rules instructed by a DOTS client assumes a default 553 direction: the destination is the DOTS client domain. 555 DOTS forwarding actions can be 'accept' (i.e., accept matching 556 traffic) or 'drop' (i.e., drop matching traffic without sending any 557 ICMP error message). Accepted traffic can be subject to rate 558 limiting 'rate-limit'. Note that 'reject' action (i.e., drop 559 matching traffic and send an ICMP error message to the source) is not 560 supported in 'ietf-dots-data-channel' because it is not appropriate 561 in the context of DDoS mitigation. Generating ICMP messages to 562 notify drops when mitigating a DDoS attack will exacerbate the DDoS 563 attack. Furthermore, these ICMP messages will be used by an attacker 564 as an explicit signal that the traffic is being blocked. 566 4.2. Filtering Fields 568 The 'ietf-dots-data-channel' module reuses the packet fields module 569 'ietf-packet-fields' [I-D.ietf-netmod-acl-model] which defines 570 matching on fields in the packet including IPv4, IPv6, and transport 571 layer fields. 573 Figure 6 shows the IPv4 match subtree. 575 module: ietf-dots-data-channel 576 +--rw dots-data 577 +--rw dots-client* [cuid] 578 | ... 579 | +--rw acls 580 | +--rw acl* [name] 581 | ... 582 | +--rw aces 583 | +--rw ace* [name] 584 | +--rw name string 585 | +--rw matches 586 | | +--rw (l3)? 587 | | | +--:(ipv4) 588 | | | | +--rw ipv4 589 | | | | +--rw dscp? inet:dscp 590 | | | | +--rw ecn? uint8 591 | | | | +--rw length? uint16 592 | | | | +--rw ttl? uint8 593 | | | | +--rw protocol? uint8 594 | | | | +--rw ihl? uint8 595 | | | | +--rw flags? bits 596 | | | | +--rw offset? uint16 597 | | | | +--rw identification? uint16 598 | | | | +--rw (destination-network)? 599 | | | | | +--:(destination-ipv4-network) 600 | | | | | +--rw destination-ipv4-network? 601 | | | | | inet:ipv4-prefix 602 | | | | +--rw (source-network)? 603 | | | | +--:(source-ipv4-network) 604 | | | | +--rw source-ipv4-network? 605 | | | | inet:ipv4-prefix 606 | | | +--:(ipv6) 607 | | | ... 608 | | +--rw (l4)? 609 | | ... 610 | +--rw actions 611 | | ... 612 | +--ro statistics 613 | ... 614 +--ro capabilities 615 ... 617 Figure 6: DOTS ACLs Subtree (IPv4 Match) 619 Figure 7 shows the IPv6 match subtree. 621 module: ietf-dots-data-channel 622 +--rw dots-data 623 +--rw dots-client* [cuid] 624 | ... 625 | +--rw acls 626 | +--rw acl* [name] 627 | ... 628 | +--rw aces 629 | +--rw ace* [name] 630 | +--rw name string 631 | +--rw matches 632 | | +--rw (l3)? 633 | | | +--:(ipv4) 634 | | | | ... 635 | | | +--:(ipv6) 636 | | | +--rw ipv6 637 | | | +--rw dscp? inet:dscp 638 | | | +--rw ecn? uint8 639 | | | +--rw length? uint16 640 | | | +--rw ttl? uint8 641 | | | +--rw protocol? uint8 642 | | | +--rw (destination-network)? 643 | | | | +--:(destination-ipv6-network) 644 | | | | +--rw destination-ipv6-network? 645 | | | | inet:ipv6-prefix 646 | | | +--rw (source-network)? 647 | | | | +--:(source-ipv6-network) 648 | | | | +--rw source-ipv6-network? 649 | | | | inet:ipv6-prefix 650 | | | +--rw flow-label? 651 | | | | inet:ipv6-flow-label 652 | | | +--rw fragment? empty 653 | | +--rw (l4)? 654 | | ... 655 | +--rw actions 656 | | ... 657 | +--ro statistics 658 | ... 659 +--ro capabilities 660 ... 662 Figure 7: DOTS ACLs Subtree (IPv6 Match) 664 Figure 8 shows the TCP match subtree. 666 module: ietf-dots-data-channel 667 +--rw dots-data 668 +--rw dots-client* [cuid] 669 | ... 670 | +--rw acls 671 | +--rw acl* [name] 672 | ... 673 | +--rw aces 674 | +--rw ace* [name] 675 | +--rw name string 676 | +--rw matches 677 | | +--rw (l3)? 678 | | | ... 679 | | +--rw (l4)? 680 | | +--:(tcp) 681 | | | +--rw tcp 682 | | | +--rw sequence-number? uint32 683 | | | +--rw acknowledgement-number? uint32 684 | | | +--rw data-offset? uint8 685 | | | +--rw reserved? uint8 686 | | | +--rw flags? bits 687 | | | +--rw window-size? uint16 688 | | | +--rw urgent-pointer? uint16 689 | | | +--rw options? uint32 690 | | | +--rw (source-port)? 691 | | | | +--:(source-port-range-or-operator) 692 | | | | +--rw source-port-range-or-operator 693 | | | | +--rw (port-range-or-operator)? 694 | | | | +--:(range) 695 | | | | | +--rw lower-port 696 | | | | | | inet:port-number 697 | | | | | +--rw upper-port 698 | | | | | inet:port-number 699 | | | | +--:(operator) 700 | | | | +--rw operator? 701 | | | | | operator 702 | | | | +--rw port 703 | | | | inet:port-number 704 | | | +--rw (destination-port)? 705 | | | +--:(destination-port-range-or-operator) 706 | | | +--rw destination-port-range-or-operator 707 | | | +--rw (port-range-or-operator)? 708 | | | +--:(range) 709 | | | | +--rw lower-port 710 | | | | | inet:port-number 711 | | | | +--rw upper-port 712 | | | | inet:port-number 713 | | | +--:(operator) 714 | | | +--rw operator? 715 | | | | operator 716 | | | +--rw port 717 | | | inet:port-number 718 | | +--:(udp) 719 | | | ... 720 | | +--:(icmp) 721 | | ... 722 | +--rw actions 723 | | ... 724 | +--ro statistics 725 | ... 726 +--ro capabilities 727 ... 729 Figure 8: DOTS ACLs Subtree (TCP Match) 731 Figure 9 shows the UDP and ICMP match subtree. 733 module: ietf-dots-data-channel 734 +--rw dots-data 735 +--rw dots-client* [cuid] 736 | ... 737 | +--rw acls 738 | +--rw acl* [name] 739 | ... 740 | +--rw aces 741 | +--rw ace* [name] 742 | +--rw name string 743 | +--rw matches 744 | | +--rw (l3)? 745 | | | ... 746 | | +--rw (l4)? 747 | | +--:(tcp) 748 | | | ... 749 | | +--:(udp) 750 | | | +--rw udp 751 | | | +--rw length? uint16 752 | | | +--rw (source-port)? 753 | | | | +--:(source-port-range-or-operator) 754 | | | | +--rw source-port-range-or-operator 755 | | | | +--rw (port-range-or-operator)? 756 | | | | +--:(range) 757 | | | | | +--rw lower-port 758 | | | | | | inet:port-number 759 | | | | | +--rw upper-port 760 | | | | | inet:port-number 761 | | | | +--:(operator) 762 | | | | +--rw operator? 763 | | | | | operator 764 | | | | +--rw port 765 | | | | inet:port-number 766 | | | +--rw (destination-port)? 767 | | | +--:(destination-port-range-or-operator) 768 | | | +--rw destination-port-range-or-operator 769 | | | +--rw (port-range-or-operator)? 770 | | | +--:(range) 771 | | | | +--rw lower-port 772 | | | | | inet:port-number 773 | | | | +--rw upper-port 774 | | | | inet:port-number 775 | | | +--:(operator) 776 | | | +--rw operator? 777 | | | | operator 778 | | | +--rw port 779 | | | inet:port-number 780 | | +--:(icmp) 781 | | +--rw icmp 782 | | +--rw type? uint8 783 | | +--rw code? uint8 784 | | +--rw rest-of-header? uint32 785 | +--rw actions 786 | | ... 787 | +--ro statistics 788 | ... 789 +--ro capabilities 790 ... 792 Figure 9: DOTS ACLs Subtree (UDP and ICMP Match) 794 DOTS implementations MUST support the following matching criteria: 796 match based on the IP header (IPv4 and IPv6), match based on the 797 transport header (TCP, UDP, and ICMP), and any combination 798 thereof. The same matching fields are used for both ICMP and 799 ICMPv6. 801 The following match fields MUST be supported by DOTS implementations 802 (Table 1): 804 ACL Mandatory Fields 805 Match 806 -------- ------------------------------------------------------------ 807 ipv4 length, protocol, flags, destination-ipv4-network, and 808 source-ipv4-network 809 ipv6 length, protocol, destination-ipv6-network, source- 810 ipv6-network, and fragment 811 tcp flags, source-port-range-or-operator, and destination-port- 812 range-or-operator 813 udp length, source-port-range-or-operator, and destination-port- 814 range-or-operator 815 icmp type and code 817 Table 1: Mandatory DOTS Channel Match Fields 819 Implementations MAY support other filtering match fields and actions. 820 The 'ietf-dots-data-channel' allows an implementation to expose its 821 filtering capabilities. The tree structure of the 'capabilities' is 822 shown in Figure 10. 824 module: ietf-dots-data-channel 825 +--rw dots-data 826 ... 827 +--ro capabilities 828 +--ro address-family* enumeration 829 +--ro forwarding-actions* identityref 830 +--ro rate-limit? boolean 831 +--ro transport-protocols* uint8 832 +--ro ipv4 833 | +--ro dscp? boolean 834 | +--ro ecn? boolean 835 | +--ro length? boolean 836 | +--ro ttl? boolean 837 | +--ro protocol? boolean 838 | +--ro ihl? boolean 839 | +--ro source-prefix? boolean 840 | +--ro destination-prefix? boolean 841 | +--ro fragment boolean 842 +--ro ipv6 843 | +--ro dscp? boolean 844 | +--ro ecn? boolean 845 | +--ro flow-label? boolean 846 | +--ro length? boolean 847 | +--ro protocol? boolean 848 | +--ro hoplimit? boolean 849 | +--ro source-prefix? boolean 850 | +--ro destination-prefix? boolean 851 | +--ro fragment boolean 852 +--ro tcp 853 | +--ro sequence-number? boolean 854 | +--ro acknowledgement-number? boolean 855 | +--ro data-offset? boolean 856 | +--ro reserved? boolean 857 | +--ro flags? boolean 858 | +--ro window-size? boolean 859 | +--ro urgent-pointer? boolean 860 | +--ro options? boolean 861 | +--ro source-port? boolean 862 | +--ro destination-port? boolean 863 | +--ro port-range? boolean 864 +--ro udp 865 | +--ro length? boolean 866 | +--ro source-port? boolean 867 | +--ro destination-port? boolean 868 | +--ro port-range? boolean 869 +--ro icmp 870 +--ro type? boolean 871 +--ro code? boolean 872 +--ro rest-of-header? boolean 874 Figure 10: Filtering Capabilities Sub-Tree 876 4.3. YANG Module 878 file "ietf-dots-data-channel@2018-05-15.yang" 880 module ietf-dots-data-channel { 881 yang-version 1.1; 882 namespace "urn:ietf:params:xml:ns:yang:ietf-dots-data-channel"; 883 prefix data-channel; 885 import ietf-access-control-list { 886 prefix ietf-acl; 887 } 888 import ietf-packet-fields { 889 prefix packet-fields; 890 } 891 import ietf-dots-signal-channel { 892 prefix dots-signal; 893 } 895 organization 896 "IETF DDoS Open Threat Signaling (DOTS) Working Group"; 897 contact 898 "WG Web: 899 WG List: 900 Editor: Konda, Tirumaleswar Reddy 901 903 Editor: Mohamed Boucadair 904 906 Author: Kaname Nishizuka 907 909 Author: Liang Xia 910 912 Author: Prashanth Patil 913 915 Author: Andrew Mortensen 916 918 Author: Nik Teague 919 921 Author: Jon Shallow 922 "; 923 description 924 "This module contains YANG definition for configuring 925 aliases for resources and filtering rules using DOTS 926 data channel. 928 Copyright (c) 2018 IETF Trust and the persons identified as 929 authors of the code. All rights reserved. 931 Redistribution and use in source and binary forms, with or 932 without modification, is permitted pursuant to, and subject 933 to the license terms contained in, the Simplified BSD License 934 set forth in Section 4.c of the IETF Trust's Legal Provisions 935 Relating to IETF Documents 936 (http://trustee.ietf.org/license-info). 938 This version of this YANG module is part of RFC XXXX; see 939 the RFC itself for full legal notices."; 941 revision 2018-05-15 { 942 description 943 "Initial revision."; 944 reference 945 "RFC XXXX: Distributed Denial-of-Service Open Threat 946 Signaling (DOTS) Data Channel Specification"; 947 } 948 grouping aliases { 949 description 950 "Top level container for aliases"; 951 list alias { 952 key "name"; 953 description 954 "List of aliases"; 955 leaf name { 956 type string; 957 description 958 "The name of the alias"; 959 } 960 uses dots-signal:target; 961 leaf pending-lifetime { 962 type int32; 963 units "minutes"; 964 config false; 965 description 966 "Indicates the pending validity lifetime of the alias 967 entry."; 968 } 969 } 970 } 972 grouping ports { 973 choice source-port { 974 container source-port-range-or-operator { 975 uses packet-fields:port-range-or-operator; 976 description 977 "Source port definition."; 978 } 979 description 980 "Choice of specifying the source port or referring to 981 a group of source ports."; 982 } 983 choice destination-port { 984 container destination-port-range-or-operator { 985 uses packet-fields:port-range-or-operator; 986 description 987 "Destination port definition."; 988 } 989 description 990 "Choice of specifying a destination port or referring 991 to a group of destination ports."; 992 } 993 description 994 "Choice of specifying a source or destination ports."; 995 } 996 grouping access-lists { 997 description 998 "Specifies the ordered set of Access Control Lists."; 999 list acl { 1000 key "name"; 1001 ordered-by user; 1002 description 1003 "An Access Control List (ACL) is an ordered list of 1004 Access Control Entries (ACE). Each Access Control Entry 1005 has a list of match criteria and a list of actions."; 1006 leaf name { 1007 type string { 1008 length "1..64"; 1009 } 1010 description 1011 "The name of the access list."; 1012 reference 1013 "RFC ZZZZ: Network Access Control List (ACL) 1014 YANG Data Model"; 1015 } 1016 leaf type { 1017 type ietf-acl:acl-type; 1018 description 1019 "Type of access control list. Indicates the primary intended 1020 type of match criteria (e.g., IPv4, IPv6) used in the list 1021 instance."; 1022 reference 1023 "RFC ZZZZ: Network Access Control List (ACL) 1024 YANG Data Model"; 1025 } 1026 leaf activation-type { 1027 type enumeration { 1028 enum "activate-when-mitigating" { 1029 value 1; 1030 description 1031 "The ACL is installed only when a mitigation is active. 1032 The ACL is specific to this DOTS client."; 1033 } 1034 enum "immediate" { 1035 value 2; 1036 description 1037 "The ACL is immediately activated."; 1038 } 1039 } 1040 description 1041 "Indicates whether an ACL is to be installed immediately 1042 or when a mitigation is active."; 1043 } 1044 leaf pending-lifetime { 1045 type int32; 1046 units "minutes"; 1047 config false; 1048 description 1049 "Indicates the pending validity lifetime of the alias 1050 entry."; 1051 } 1052 container aces { 1053 description 1054 "The Access Control Entries container contains 1055 a list of ACEs."; 1056 list ace { 1057 key "name"; 1058 ordered-by user; 1059 description 1060 "List of access list entries."; 1061 leaf name { 1062 type string { 1063 length "1..64"; 1064 } 1065 description 1066 "A unique name identifying this Access List 1067 Entry (ACE)."; 1068 reference 1069 "RFC ZZZZ: Network Access Control List (ACL) 1070 YANG Data Model"; 1071 } 1072 container matches { 1073 description 1074 "The rules in this set determine what fields will be 1075 matched upon before any action is taken on them. 1077 If no matches are defined in a particular container, 1078 then any packet will match that container. 1080 If no matches are specified at all in an ACE, then any 1081 packet will match the ACE."; 1082 reference 1083 "RFC ZZZZ: Network Access Control List (ACL) 1084 YANG Data Model"; 1086 choice l3 { 1087 container ipv4 { 1088 when "derived-from(../../../../type," + 1089 "'ietf-acl:ipv4-acl-type')"; 1090 uses packet-fields:acl-ip-header-fields; 1091 uses packet-fields:acl-ipv4-header-fields; 1092 description 1093 "Rule set that matches IPv4 header."; 1094 } 1095 container ipv6 { 1096 when "derived-from(../../../../type," + 1097 "'ietf-acl:ipv6-acl-type')"; 1098 uses packet-fields:acl-ip-header-fields; 1099 uses packet-fields:acl-ipv6-header-fields; 1100 leaf fragment { 1101 type empty; 1102 description 1103 "Handle IPv6 fragments. When this keyword 1104 is present, the match is about assessing 1105 whether a packet is a fragment (that is, 1106 a Fragment header is present)."; 1107 } 1108 description 1109 "Rule set that matches IPv6 header."; 1110 } 1111 description 1112 "Either IPv4 or IPv6."; 1113 } 1114 choice l4 { 1115 container tcp { 1116 uses packet-fields:acl-tcp-header-fields; 1117 uses ports; 1118 description 1119 "Rule set that matches TCP header."; 1120 } 1121 container udp { 1122 uses packet-fields:acl-udp-header-fields; 1123 uses ports; 1124 description 1125 "Rule set that matches UDP header."; 1126 } 1127 container icmp { 1128 uses packet-fields:acl-icmp-header-fields; 1129 description 1130 "Rule set that matches ICMP/ICMPv6 header."; 1131 } 1132 description 1133 "Can be TCP, UDP, or ICMP/ICMPv6"; 1134 } 1135 } 1136 container actions { 1137 description 1138 "Definitions of action for this ACE."; 1139 leaf forwarding { 1140 type identityref { 1141 base ietf-acl:forwarding-action; 1142 } 1143 mandatory true; 1144 description 1145 "Specifies the forwarding action per ACE."; 1146 reference 1147 "RFC ZZZZ: Network Access Control List (ACL) 1148 YANG Data Model"; 1149 } 1150 leaf rate-limit { 1151 when "../forwarding = 'ietf-acl:accept'" { 1152 description 1153 "rate-limit valid only when accept action is used"; 1154 } 1155 type decimal64 { 1156 fraction-digits 2; 1157 } 1158 description 1159 "rate-limit traffic"; 1160 } 1161 } 1162 container statistics { 1163 config false; 1164 description 1165 "Aggregate statistics."; 1166 uses ietf-acl:acl-counters; 1167 } 1168 } 1169 } 1170 } 1171 } 1173 container dots-data { 1174 description 1175 "Main container for DOTS data channel."; 1176 list dots-client { 1177 key "cuid"; 1178 description 1179 "List of DOTS clients."; 1180 leaf cuid { 1181 type string; 1182 description 1183 "A unique identifier that is randomly generated by 1184 a DOTS client to prevent request collisions."; 1185 reference 1186 "RFC YYYY: Distributed Denial-of-Service Open Threat 1187 Signaling (DOTS) Signal Channel Specification"; 1189 } 1190 leaf cdid { 1191 type string; 1192 description 1193 "A client domain identifier conveyed by a 1194 server-domain DOTS gateway to a remote DOTS server."; 1195 reference 1196 "RFC YYYY: Distributed Denial-of-Service Open Threat 1197 Signaling (DOTS) Signal Channel Specification"; 1198 } 1199 container aliases { 1200 description 1201 "Set of aliases that are bound to a DOTS client."; 1202 uses aliases; 1203 } 1204 container acls { 1205 description 1206 "Access lists that are bound to a DOTS client."; 1207 uses access-lists; 1208 } 1209 } 1210 container capabilities { 1211 config false; 1212 description 1213 "Match capabilities"; 1214 leaf-list address-family { 1215 type enumeration { 1216 enum "ipv4" { 1217 description 1218 "IPv4 is supported."; 1219 } 1220 enum "ipv6" { 1221 description 1222 "IPv6 is supported."; 1223 } 1224 } 1225 description 1226 "Indicates the IP address families supported by 1227 the DOTS server."; 1228 } 1229 leaf-list forwarding-actions { 1230 type identityref { 1231 base ietf-acl:forwarding-action; 1232 } 1233 description 1234 "Supported forwarding action(s)."; 1235 } 1236 leaf rate-limit { 1237 type boolean; 1238 description 1239 "Support of rate-limit action."; 1240 } 1241 leaf-list transport-protocols { 1242 type uint8; 1243 description 1244 "Upper-layer protocol associated with this mapping. 1246 Values are taken from the IANA protocol registry: 1247 https://www.iana.org/assignments/protocol-numbers/ 1248 protocol-numbers.xhtml 1250 For example, this field contains 6 (TCP) for a TCP 1251 mapping or 17 (UDP) for a UDP mapping."; 1252 } 1253 container ipv4 { 1254 description 1255 "Indicates IPv4 header fields that are supported to enforce 1256 ACLs."; 1257 leaf dscp { 1258 type boolean; 1259 description 1260 "Support of filtering based on DSCP."; 1261 } 1262 leaf ecn { 1263 type boolean; 1264 description 1265 "Support of filtering based on ECN."; 1266 } 1267 leaf length { 1268 type boolean; 1269 description 1270 "Support of filtering based on the Total Length."; 1271 } 1272 leaf ttl { 1273 type boolean; 1274 description 1275 "Support of filtering based on the TTL."; 1276 } 1277 leaf protocol { 1278 type boolean; 1279 description 1280 "Support of filtering based on protocol field."; 1281 } 1282 leaf ihl { 1283 type boolean; 1284 description 1285 "Support of filtering based on the Internet Header 1286 Length (IHL)."; 1287 } 1288 leaf source-prefix { 1289 type boolean; 1290 description 1291 "Support of filtering based on the source prefix."; 1292 } 1293 leaf destination-prefix { 1294 type boolean; 1295 description 1296 "Support of filtering based on the destination prefix."; 1297 } 1298 leaf fragment { 1299 type boolean; 1300 description 1301 "Indicates the capability of a DOTS server to 1302 enforce filters on IPv4 fragments."; 1303 } 1304 } 1305 container ipv6 { 1306 description 1307 "Indicates IPv6 header fields that are supported to enforce 1308 ACLs."; 1309 leaf dscp { 1310 type boolean; 1311 description 1312 "Support of filtering based on DSCP."; 1313 } 1314 leaf ecn { 1315 type boolean; 1316 description 1317 "Support of filtering based on ECN."; 1318 } 1319 leaf flow-label { 1320 type boolean; 1321 description 1322 "Support of filtering based on the Flow label."; 1323 } 1324 leaf length { 1325 type boolean; 1326 description 1327 "Support of filtering based on the Payload Length."; 1328 } 1329 leaf protocol { 1330 type boolean; 1331 description 1332 "Support of filtering based on the Next Header field."; 1334 } 1335 leaf hoplimit { 1336 type boolean; 1337 description 1338 "Support of filtering based on the Hop Limit."; 1339 } 1340 leaf source-prefix { 1341 type boolean; 1342 description 1343 "Support of filtering based on the source prefix."; 1344 } 1345 leaf destination-prefix { 1346 type boolean; 1347 description 1348 "Support of filtering based on the destination prefix."; 1349 } 1350 leaf fragment { 1351 type boolean; 1352 description 1353 "Indicates the capability of a DOTS server to 1354 enforce filters on IPv6 fragments."; 1355 } 1356 } 1357 container tcp { 1358 description 1359 "Set of TCP fields that are supported by the DOTS server 1360 to enfoce filters."; 1361 leaf sequence-number { 1362 type boolean; 1363 description 1364 "Support of filtering based on the TCP sequence number."; 1365 } 1366 leaf acknowledgement-number { 1367 type boolean; 1368 description 1369 "Support of filtering based on the TCP acknowledgement 1370 number."; 1371 } 1372 leaf data-offset { 1373 type boolean; 1374 description 1375 "Support of filtering based on the TCP data-offset."; 1376 } 1377 leaf reserved { 1378 type boolean; 1379 description 1380 "Support of filtering based on the TCP reserved field."; 1381 } 1382 leaf flags { 1383 type boolean; 1384 description 1385 "Support of filtering based on the TCP flags."; 1386 } 1387 leaf window-size { 1388 type boolean; 1389 description 1390 "Support of filtering based on the TCP window size."; 1391 } 1392 leaf urgent-pointer { 1393 type boolean; 1394 description 1395 "Support of filtering based on the TCP urgent pointer."; 1396 } 1397 leaf options { 1398 type boolean; 1399 description 1400 "Support of filtering based on the TCP options."; 1401 } 1402 leaf source-port { 1403 type boolean; 1404 description 1405 "Support of filtering based on the source port number."; 1406 } 1407 leaf destination-port { 1408 type boolean; 1409 description 1410 "Support of filtering based on the destination port 1411 number."; 1412 } 1413 leaf port-range { 1414 type boolean; 1415 description 1416 "Support of filtering based on a port range."; 1417 } 1418 } 1419 container udp { 1420 description 1421 "Set of UDP fields that are supported by the DOTS server 1422 to enforce filters."; 1423 leaf length { 1424 type boolean; 1425 description 1426 "Support of filtering based on the UDP length."; 1427 } 1428 leaf source-port { 1429 type boolean; 1430 description 1431 "Support of filtering based on the source port number."; 1432 } 1433 leaf destination-port { 1434 type boolean; 1435 description 1436 "Support of filtering based on the destination port 1437 number."; 1438 } 1439 leaf port-range { 1440 type boolean; 1441 description 1442 "Support of filtering based on a port range."; 1443 } 1444 } 1445 container icmp { 1446 description 1447 "Set of ICMP/ICMPv6 fields that are supported by the DOTS 1448 server to enforce filters."; 1449 leaf type { 1450 type boolean; 1451 description 1452 "Support of filtering based on the ICMP/ICMPv6 type."; 1453 } 1454 leaf code { 1455 type boolean; 1456 description 1457 "Support of filtering based on the ICMP/ICMPv6 code."; 1458 } 1459 leaf rest-of-header { 1460 type boolean; 1461 description 1462 "Support of filtering based on the ICMP four-bytes 1463 field."; 1464 } 1465 } 1466 } 1467 } 1468 } 1469 1471 5. Managing DOTS Clients 1473 5.1. Registering DOTS Clients 1475 In order to make use of DOTS data channel, a DOTS client MUST 1476 register to its DOTS server(s) by creating a DOTS client ('dots- 1477 client') resource. To that aim, DOTS clients SHOULD send a POST 1478 request (shown in Figure 11). 1480 POST /restconf/data/ietf-dots-data-channel:dots-data HTTP/1.1 1481 Host: {host}:{port} 1482 Content-Type: application/yang-data+json 1483 { 1484 "ietf-dots-data-channel:dots-client": [ 1485 { 1486 "cuid": "string" 1487 } 1488 ] 1489 } 1491 Figure 11: POST to Register 1493 The 'cuid' (client unique identifier) parameter is described below: 1495 cuid: A globally unique identifier that is meant to prevent 1496 collisions among DOTS clients. This attribute has the same 1497 meaning, syntax, and processing rules as the 'cuid' attribute 1498 defined in [I-D.ietf-dots-signal-channel]. 1500 DOTS clients MUST use the same 'cuid' for both signal and data 1501 channels. 1503 This is a mandatory attribute. 1505 In deployments where server-domain DOTS gateways are enabled, 1506 identity information about the origin source client domain SHOULD be 1507 supplied to the DOTS server. That information is meant to assist the 1508 DOTS server to enforce some policies. These policies can be enforced 1509 per-client, per-client domain, or both. Figure 12 shows an example 1510 of a request relayed by a server-domain DOTS gateway. 1512 POST /restconf/data/ietf-dots-data-channel:dots-data HTTP/1.1 1513 Host: {host}:{port} 1514 Content-Type: application/yang-data+json 1515 { 1516 "ietf-dots-data-channel:dots-client": [ 1517 { 1518 "cuid": "string", 1519 "cdid": "string" 1520 } 1521 ] 1522 } 1524 Figure 12: POST to Register (DOTS Gateway) 1526 A server-domain DOTS gateway SHOULD add the following attribute: 1528 cdid: This attribute has the same meaning, syntax, and processing 1529 rules as the 'cdid' attribute defined in 1530 [I-D.ietf-dots-signal-channel]. 1532 In deployments where server-domain DOTS gateways are enabled, 1533 'cdid' does not need to be inserted when relaying DOTS methods to 1534 manage aliases (Section 6) or filtering rules (Section 7). DOTS 1535 servers are responsible for maintaining the association between 1536 'cdid' and 'cuid' for policy enforcement purposes. 1538 This is an optional attribute. 1540 A request example to create a 'dots-client' resource is depicted in 1541 Figure 13. This request is relayed by a server-domain DOTS gateway 1542 as hinted by the presence of the 'cdid' attribute. 1544 POST /restconf/data/ietf-dots-data-channel:dots-data HTTP/1.1 1545 Host: {host}:{port} 1546 Content-Type: application/yang-data+json 1547 { 1548 "ietf-dots-data-channel:dots-client": [ 1549 { 1550 "cuid": "dz6pHjaADkaFTbjr0JGBpw", 1551 "cdid": "7eeaf349529eb55ed50113" 1552 } 1553 ] 1554 } 1556 Figure 13: POST to Register (DOTS gateway) 1558 DOTS servers MUST limit the number of 'dots-client' resources to be 1559 created by the same DOTS client to 1 per request. Requests with 1560 multiple 'dots-client' resources MUST be rejected by DOTS servers. 1561 To that aim, the DOTS server MUST rely on the same procedure to 1562 unambiguously identify a DOTS client as discussed in Section 4.4.1 of 1563 [I-D.ietf-dots-signal-channel]. 1565 The DOTS server indicates the result of processing the POST request 1566 using status-line codes. Status codes in the range "2xx" codes are 1567 success, "4xx" codes are some sort of invalid requests and "5xx" 1568 codes are returned if the DOTS server has erred or is incapable of 1569 accepting the creation of the 'dots-client' resource. In particular, 1571 o "201 Created" status-line is returned in the response, if the DOTS 1572 server has accepted the request. 1574 o "400 Bad Request" status-line is returned by the DOTS server, if 1575 the request does not include a 'cuid' parameter. The error-tag 1576 "missing-attribute" is used in this case. 1578 o "409 Conflict" status-line is returned to the requesting DOTS 1579 client, if the data resource already exists. The error-tag 1580 "resource-denied" is used in this case. 1582 Once a DOTS client registers itself to a DOTS server, it can 1583 create/delete/retrieve aliases (Section 6) and filtering rules 1584 (Section 7). 1586 A DOTS client MAY use the PUT request (Section 4.5 in [RFC8040]) to 1587 register a DOTS client within the DOTS server. An example is shown 1588 in Figure 14. 1590 PUT /restconf/data/ietf-dots-data-channel:dots-data\ 1591 /dots-client=dz6pHjaADkaFTbjr0JGBpw HTTP/1.1 1592 Host: {host}:{port} 1593 Content-Type: application/yang-data+json 1594 { 1595 "ietf-dots-data-channel:dots-client": [ 1596 { 1597 "cuid": "dz6pHjaADkaFTbjr0JGBpw" 1598 } 1599 ] 1600 } 1602 Figure 14: PUT to Register 1604 The DOTS gateway that inserted a 'cdid' in a PUT request, MUST strip 1605 the 'cdid' parameter in the corresponding response before forwarding 1606 the response to the DOTS client. 1608 5.2. Uregistering DOTS Clients 1610 A DOTS client de-registers from its DOTS server by deleting the 1611 'cuid' resource. Resources bound to this DOTS client will be deleted 1612 by the DOTS server. An example of de-register request is shown in 1613 Figure 15. 1615 DELETE /restconf/data/ietf-dots-data-channel:dots-data\ 1616 /dots-client=dz6pHjaADkaFTbjr0JGBpw HTTP/1.1 1617 Host: {host}:{port} 1619 Figure 15: De-register a DOTS Client 1621 6. Managing DOTS Aliases 1623 The following sub-sections define means for a DOTS client to create 1624 aliases (Section 6.1), retrieve one or a list of aliases 1625 (Section 6.2), and delete an alias (Section 6.3). 1627 6.1. Create Aliases 1629 A POST or PUT request is used by a DOTS client to create aliases, for 1630 resources for which a mitigation may be requested. Such aliases may 1631 be used in subsequent DOTS signal channel exchanges to refer more 1632 efficiently to the resources under attack. 1634 DOTS clients within the same domain can create different aliases for 1635 the same resource. 1637 The structure of POST requests used to create aliases is shown in 1638 Figure 16. 1640 POST /restconf/data/ietf-dots-data-channel:dots-data\ 1641 /dots-client=dz6pHjaADkaFTbjr0JGBpw HTTP/1.1 1642 Host: {host}:{port} 1643 Content-Type: application/yang-data+json 1644 { 1645 "ietf-dots-data-channel:aliases": { 1646 "alias": [ 1647 { 1648 "name": "string", 1649 "target-prefix": [ 1650 "string" 1651 ], 1652 "target-port-range": [ 1653 { 1654 "lower-port": integer, 1655 "upper-port": integer 1656 } 1657 ], 1658 "target-protocol": [ 1659 integer 1660 ], 1661 "target-fqdn": [ 1662 "string" 1663 ], 1664 "target-uri": [ 1665 "string" 1666 ] 1667 } 1668 ] 1669 } 1670 } 1672 Figure 16: POST to Create Aliases 1674 The parameters are described below: 1676 name: Name of the alias. 1678 This is a mandatory attribute. 1680 target-prefix: Prefixes are separated by commas. Prefixes are 1681 represented using Classless Inter-domain Routing (CIDR) notation 1682 [RFC4632]. As a reminder, the prefix length must be less than or 1683 equal to 32 (resp. 128) for IPv4 (resp. IPv6). 1685 The prefix list MUST NOT include broadcast, loopback, or multicast 1686 addresses. These addresses are considered as invalid values. In 1687 addition, the DOTS server MUST validate that these prefixes are 1688 within the scope of the DOTS client's domain. Other validation 1689 checks may be supported by DOTS servers. 1691 This is an optional attribute. 1693 target-port-range: A range of port numbers. 1695 The port range is defined by two bounds, a lower port number 1696 (lower-port) and an upper port number (upper-port). 1698 When only 'lower-port' is present, it represents a single port 1699 number. 1701 For TCP, UDP, Stream Control Transmission Protocol (SCTP) 1702 [RFC4960], or Datagram Congestion Control Protocol (DCCP) 1703 [RFC4340], the range of port numbers can be, for example, 1704 1024-65535. 1706 This is an optional attribute. 1708 target-protocol: A list of protocols. Values are taken from the 1709 IANA protocol registry [proto_numbers]. 1711 The value '0' has a special meaning for 'all protocols'. 1713 This is an optional attribute. 1715 target-fqdn: A list of Fully Qualified Domain Names (FQDNs). An 1716 FQDN is the full name of a resource, rather than just its 1717 hostname. For example, "venera" is a hostname, and 1718 "venera.isi.edu" is an FQDN [RFC1983]. 1720 How a name is passed to an underlying name resolution library is 1721 implementation- and deployment-specific. Nevertheless, once the 1722 name is resolved into one or multiple IP addresses, DOTS servers 1723 MUST apply the same validation checks as those for 'target- 1724 prefix'. 1726 This is an optional attribute. 1728 target-uri: A list of Uniform Resource Identifiers (URIs) 1729 [RFC3986]. 1731 The same validation checks used for 'target-fqdn' MUST be followed 1732 by DOTS servers to validate a target URI. 1734 This is an optional attribute. 1736 In POST or PUT requests, at least one of the 'target-prefix', 1737 'target-fqdn', or 'target-uri' attributes MUST be present. DOTS 1738 agents can safely ignore Vendor-Specific parameters they don't 1739 understand. 1741 Figure 17 shows a POST request to create an alias called "https1" for 1742 HTTPS servers with IP addresses 2001:db8:6401::1 and 2001:db8:6401::2 1743 listening on port number 443. 1745 POST /restconf/data/ietf-dots-data-channel:dots-data\ 1746 /dots-client=dz6pHjaADkaFTbjr0JGBpw HTTP/1.1 1747 Host: www.example.com 1748 Content-Type: application/yang-data+json 1749 { 1750 "ietf-dots-data-channel:aliases": { 1751 "alias": [ 1752 { 1753 "name": "https1", 1754 "target-protocol": [ 1755 6 1756 ], 1757 "target-prefix": [ 1758 "2001:db8:6401::1/128", 1759 "2001:db8:6401::2/128" 1760 ], 1761 "target-port-range": [ 1762 { 1763 "lower-port": 443 1764 } 1765 ] 1766 } 1767 ] 1768 } 1769 } 1771 Figure 17: Example of a POST to Create an Alias 1773 "201 Created" status-line MUST be returned in the response if the 1774 DOTS server has accepted the alias. 1776 "409 Conflict" status-line MUST be returned to the requesting DOTS 1777 client, if the request is conflicting with an existing alias name. 1778 The error-tag "resource-denied" is used in this case. 1780 If the request is missing a mandatory attribute or its contains an 1781 invalid or unknown parameter, "400 Bad Request" status-line MUST be 1782 returned by the DOTS server. The error-tag is set to "missing- 1783 attribute", "invalid-value", or "unknown-element" as a function of 1784 the encountered error. 1786 If the request is received via a server-domain DOTS gateway, but the 1787 DOTS server does not maintain a 'cdid' for this 'cuid' while a 'cdid' 1788 is expected to be supplied, the DOTS server MUST reply with "403 1789 Forbidden" status-line and the error-tag "access-denied". Upon 1790 receipt of this message, the DOTS client MUST register (Section 5). 1792 A DOTS client uses the PUT request to modify the aliases in the DOTS 1793 server. In particular, a DOTS client MUST update its alias entries 1794 upon change of the prefix indicated in the 'target-prefix'. 1796 A DOTS server MUST maintain an alias for at least 10080 minutes (1 1797 week). If no refresh request is seen from the DOTS client, the DOTS 1798 server removes expired entries. 1800 6.2. Retrieve Installed Aliases 1802 GET request is used to retrieve one or all installed aliases by a 1803 DOTS client from a DOTS server (Section 3.3.1 in [RFC8040]). If no 1804 'name' is included in the request, this is an indication that the 1805 request is about retrieving all aliases instantiated by the DOTS 1806 client. 1808 Figure 18 shows an example to retrieve all the aliases that were 1809 instantiated by the requesting DOTS client. The 'content' parameter 1810 and its permitted values are defined in Section 4.8.1 of [RFC8040]. 1812 GET /restconf/data/ietf-dots-data-channel:dots-data\ 1813 /dots-client=dz6pHjaADkaFTbjr0JGBpw\ 1814 /aliases?content=all HTTP/1.1 1815 Host: {host}:{port} 1816 Accept: application/yang-data+json 1818 Figure 18: GET to Retrieve All Installed Aliases 1820 Figure 19 shows an example of the response message body that includes 1821 all the aliases that are maintained by the DOTS server for the DOTS 1822 client identified by the 'cuid' parameter. 1824 { 1825 "ietf-dots-data-channel:aliases": { 1826 "alias": [ 1827 { 1828 "name": "Server1", 1829 "target-protocol": [ 1830 6 1831 ], 1832 "target-prefix": [ 1833 "2001:db8:6401::1/128", 1834 "2001:db8:6401::2/128" 1835 ], 1836 "target-port-range": [ 1837 { 1838 "lower-port": 443 1839 } 1840 ], 1841 "pending-lifetime": 3596 1842 }, 1843 { 1844 "name": "Server2", 1845 "target-protocol": [ 1846 6 1847 ], 1848 "target-prefix": [ 1849 "2001:db8:6401::10/128", 1850 "2001:db8:6401::20/128" 1851 ], 1852 "target-port-range": [ 1853 { 1854 "lower-port": 80 1855 } 1856 ], 1857 "pending-lifetime": 9869 1858 } 1859 ] 1860 } 1861 } 1863 Figure 19: An Example of Response Body 1865 Figure 20 shows an example of a GET request to retrieve the alias 1866 "Server2" that was instantiated by the DOTS client. 1868 GET /restconf/data/ietf-dots-data-channel:dots-data\ 1869 /dots-client=dz6pHjaADkaFTbjr0JGBpw\ 1870 /aliases/alias=Server2?content=all HTTP/1.1 1871 Host: {host}:{port} 1872 Accept: application/yang-data+json 1874 Figure 20: GET to Retrieve an Alias 1876 If an alias name ('name') is included in the request, but the DOTS 1877 server does not find that alias name for this DOTS client in its 1878 configuration data, it MUST respond with a "404 Not Found" status- 1879 line. 1881 6.3. Delete Aliases 1883 DELETE request is used to delete an alias maintained by a DOTS 1884 server. 1886 If the DOTS server does not find the alias name, conveyed in the 1887 DELETE request, in its configuration data for this DOTS client, it 1888 MUST respond with a "404 Not Found" status-line. 1890 The DOTS server successfully acknowledges a DOTS client's request to 1891 remove the alias using "204 No Content" status-line in the response. 1893 Figure 21 shows an example of a request to delete an alias. 1895 DELETE /restconf/data/ietf-dots-data-channel:dots-data\ 1896 /dots-client=dz6pHjaADkaFTbjr0JGBpw\ 1897 /aliases/alias=Server1 HTTP/1.1 1898 Host: {host}:{port} 1900 Figure 21: Delete an Alias 1902 7. Managing DOTS Filtering Rules 1904 The following sub-sections define means for a DOTS client to retrieve 1905 DOTS filtering capabilities (Section 7.1), create filtering rules 1906 (Section 7.2), retrieve active filtering rules (Section 7.3), and 1907 delete a filtering rule (Section 7.4). 1909 7.1. Retrieve DOTS Filtering Capabilities 1911 A DOTS client MAY send a GET request to retrieve the filtering 1912 capabilities supported by a DOTS server. Figure 22 shows an example 1913 of such request. 1915 GET /restconf/data/ietf-dots-data-channel:dots-data\ 1916 /capabilities HTTP/1.1 1917 Host: {host}:{port} 1918 Accept: application/yang-data+json 1920 Figure 22: GET to Retrieve the Capabilities of a DOTS Server 1922 A DOTS client which issued a GET request to retrieve the filtering 1923 capabilities supported by its DOTS server, SHOULD NOT request for 1924 filtering actions that are not supported by that DOTS server. 1926 Figure 23 shows an example of a response received from a DOTS server 1927 which only supports the mandatory filtering criteria listed in 1928 Section 4.1. 1930 Content-Type: application/yang-data+json 1931 { 1932 "ietf-dots-data-channel:capabilities": { 1933 "address-family": ["ipv4", "ipv6"], 1934 "forwarding-actions": ["drop", "accept"], 1935 "rate-limit": true, 1936 "transport-protocols": [1, 6, 17, 58], 1937 "ipv4": { 1938 "length": true, 1939 "protocol": true, 1940 "destination-prefix": true, 1941 "source-prefix": true, 1942 "fragment": true 1943 }, 1944 "ipv6": { 1945 "length": true, 1946 "protocol": true, 1947 "destination-prefix": true, 1948 "source-prefix": true, 1949 "fragment": true 1950 }, 1951 "tcp": { 1952 "flags": true, 1953 "source-port": true, 1954 "destination-port": true, 1955 "port-range": true 1956 }, 1957 "udp": { 1958 "length": true, 1959 "source-port": true, 1960 "destination-port": true, 1961 "port-range": true 1962 }, 1963 "icmp": { 1964 "type": true, 1965 "code": true 1966 } 1967 } 1968 } 1970 Figure 23: Reply to a GET Response with Filtering Capabilities 1972 7.2. Install Filtering Rules 1974 A POST or PUT request is used by a DOTS client to communicate 1975 filtering rules to a DOTS server. 1977 Figure 24 shows a POST request example to block traffic from 1978 192.0.2.0/24 and destined to 198.51.100.0/24. Other examples are 1979 discussed in Appendix A. 1981 POST /restconf/data/ietf-dots-data-channel:dots-data\ 1982 /dots-client=dz6pHjaADkaFTbjr0JGBpw HTTP/1.1 1983 Host: {host}:{port} 1984 Content-Type: application/yang-data+json 1985 { 1986 "ietf-dots-data-channel:acls": { 1987 "acl": [ 1988 { 1989 "name": "sample-ipv4-acl", 1990 "type": "ipv4-acl-type", 1991 "activation-type": "activate-when-mitigating", 1992 "aces": { 1993 "ace": [ 1994 { 1995 "name": "rule1", 1996 "matches": { 1997 "ipv4": { 1998 "destination-ipv4-network": "198.51.100.0/24", 1999 "source-ipv4-network": "192.0.2.0/24" 2000 } 2001 }, 2002 "actions": { 2003 "forwarding": "drop" 2004 } 2005 } 2006 ] 2007 } 2008 } 2009 ] 2010 } 2011 } 2013 Figure 24: POST to Install Filtering Rules 2015 The meaning of these parameters is as follows: 2017 name: The name of the access list. 2019 This is a mandatory attribute. 2021 type: Indicates the primary intended type of match criteria (e.g., 2022 IPv4, IPv6). It is set to 'ipv4-acl-type' in this example. 2024 This is an optional attribute. 2026 activation-type: Indicates whether an ACL has to be installed 2027 immediately or during mitigation time. If this attribute is not 2028 provided, the DOTS server MUST use 'activate-when-mitigating' as 2029 default value. Filters that are activated only when a mitigation 2030 is in progress MUST be bound to the DOTS client which created the 2031 filtering rule. 2033 This is an optional attribute. 2035 matches: Define criteria used to identify a flow on which to apply 2036 the rule. It can be "l3" (IPv4, IPv6) or "l4" (TCP, UDP, ..). 2037 The detailed match parameters are specified in Section 4. 2039 In this example, an IPv4 matching criteria is used. 2041 This is an optional attribute. 2043 destination-ipv4-network: The destination IPv4 prefix. DOTS servers 2044 MUST validate that these prefixes are within the scope of the DOTS 2045 client's domain. Other validation checks may be supported by DOTS 2046 servers. If this attribute is not provided, the DOTS server 2047 enforces the ACL on any destination IP address that belong to the 2048 DOTS client's domain. 2050 This is a mandatory attribute in requests with an 'activation- 2051 type' set to 'immediate'. 2053 source-ipv4-network: The source IPv4 prefix. 2055 This is an optional attribute. 2057 actions: Actions in the forwarding ACL category can be "drop" or 2058 "accept". The "accept" action is used to white-list traffic. The 2059 "drop" action is used to black-list traffic. 2061 Accepted traffic may be subject to "rate-limit"; the allowed 2062 traffic rate is represented in bytes per second indicated in IEEE 2063 floating point format [IEEE.754.1985]. 2065 This is a mandatory attribute. 2067 The DOTS server indicates the result of processing the POST request 2068 using the status-line header. Concretely, "201 Created" status-line 2069 MUST be returned in the response if the DOTS server has accepted the 2070 filtering rules. If the request is missing a mandatory attribute or 2071 contains an invalid or unknown parameter (e.g., a match field not 2072 supported by the DOTS server), "400 Bad Request" status-line MUST be 2073 returned by the DOTS server in the response. The error-tag is set to 2074 "missing-attribute", "invalid-value", or "unknown-element" as a 2075 function of the encountered error. 2077 If the request is received via a server-domain DOTS gateway, but the 2078 DOTS server does not maintain a 'cdid' for this 'cuid' while a 'cdid' 2079 is expected to be supplied, the DOTS server MUST reply with "403 2080 Forbidden" status-line and the error-tag "access-denied". Upon 2081 receipt of this message, the DOTS client MUST register (Figure 11). 2083 If the request is conflicting with an existing filtering installed by 2084 another DOTS client of the domain, the DOTS server returns "409 2085 Conflict" status-line to the requesting DOTS client. The error-tag 2086 "resource-denied" is used in this case. 2088 The "insert" query parameter (Section 4.8.5 of [RFC8040]) MAY be used 2089 to specify how an access control entry is inserted within an ACL and 2090 how an ACL is inserted within an ACL set. 2092 The DOTS client uses the PUT request to modify its filtering rules 2093 maintained by the DOTS server. In particular, a DOTS client MUST 2094 update its filtering entries upon change of the destination-prefix. 2095 How such change is detected is out of scope. 2097 A DOTS server MUST maintain a filtering rule for at least 10080 2098 minutes (1 week). If no refresh request is seen from the DOTS 2099 client, the DOTS server removes expired entries. Typically, a 2100 refresh request is a PUT request which echoes the content of a 2101 response to a GET request with all of the read-only parameters 2102 stripped out (e.g. pending-lifetime). 2104 7.3. Retrieve Installed Filtering Rules 2106 The DOTS client periodically queries the DOTS server to check the 2107 counters for installed filtering rules. GET request is used to 2108 retrieve filtering rules from a DOTS server. 2110 If the DOTS server does not find the access list name conveyed in the 2111 GET request in its configuration data for this DOTS client, it 2112 responds with a "404 Not Found" status-line. 2114 Figure 25 shows how to retrieve all the filtering rules that were 2115 instantiated by the DOTS client and the number of matches for the 2116 installed filtering rules. 2118 GET /restconf/data/ietf-dots-data-channel:dots-data\ 2119 /dots-client=dz6pHjaADkaFTbjr0JGBpw\ 2120 /acls?content=all HTTP/1.1 2121 Host: {host}:{port} 2122 Accept: application/yang-data+json 2124 Figure 25: GET to Retrieve the Configuration Data and State Data for 2125 the Filtering Rules 2127 Figure 26 shows how to retrieve "sample-ipv6-acl" filtering rule 2128 instantiated by the DOTS client, having 2129 "cuid=dz6pHjaADkaFTbjr0JGBpw", and the number of matches for the 2130 installed filtering rules. 2132 GET /restconf/data/ietf-dots-data-channel:dots-data\ 2133 /dots-client=dz6pHjaADkaFTbjr0JGBpw/acls\ 2134 /acl=sample-ipv6-acl?content=all HTTP/1.1 2135 Host: {host}:{port} 2136 Accept: application/yang-data+json 2138 Figure 26: GET to Retrieve the Configuration Data and State Data for 2139 a Filtering Rule 2141 7.4. Remove Filtering Rules 2143 DELETE request is used by a DOTS client to delete filtering rules 2144 from a DOTS server. 2146 If the DOTS server does not find the access list name carried in the 2147 DELETE request in its configuration data for this DOTS client, it 2148 MUST respond with a "404 Not Found" status-line. The DOTS server 2149 successfully acknowledges a DOTS client's request to withdraw the 2150 filtering rules using "204 No Content" status-line, and removes the 2151 filtering rules accordingly. 2153 Figure 27 shows an example of a request to remove the IPv4 ACL named 2154 "sample-ipv4-acl". 2156 DELETE /restconf/data/ietf-dots-data-channel:dots-data\ 2157 /dots-client=dz6pHjaADkaFTbjr0JGBpw/acls\ 2158 /acl=sample-ipv4-acl HTTP/1.1 2159 Host: {host}:{port} 2161 Figure 27: DELETE to Remove a Filtering Rule 2163 8. IANA Considerations 2165 This document requests IANA to register the following URI in the 2166 "IETF XML Registry" [RFC3688]: 2168 URI: urn:ietf:params:xml:ns:yang:ietf-dots-data-channel 2169 Registrant Contact: The IESG. 2170 XML: N/A; the requested URI is an XML namespace. 2172 This document requests IANA to register the following YANG module in 2173 the "YANG Module Names" registry [RFC7950]. 2175 name: ietf-dots-data-channel 2176 namespace: urn:ietf:params:xml:ns:yang:ietf-dots-data-channel 2177 prefix: data-channel 2178 reference: RFC XXXX 2180 9. Contributors 2182 The following individuals have contributed to this document: 2184 o Dan Wing, Email: dwing-ietf@fuggles.com 2186 o Jon Shallow, NCC Group, Email: jon.shallow@nccgroup.trust 2188 10. Security Considerations 2190 RESTCONF security considerations are discussed in [RFC8040]. In 2191 particular, DOTS agents MUST follow the security recommendations in 2192 Sections 2 and 12 of [RFC8040]. Also, DOTS agents MUST support the 2193 mutual authentication TLS profile discussed in Sections 7.1 and 8 of 2194 [I-D.ietf-dots-signal-channel]. YANG ACL-specific security 2195 considerations are discussed in [I-D.ietf-netmod-acl-model]. 2197 Authenticated encryption MUST be used for data confidentiality and 2198 message integrity. The interaction between the DOTS agents requires 2199 Transport Layer Security (TLS) with a cipher suite offering 2200 confidentiality protection and the guidance given in [RFC7525] MUST 2201 be followed to avoid attacks on TLS. 2203 An attacker may be able to inject RST packets, bogus application 2204 segments, etc., regardless of whether TLS authentication is used. 2205 Because the application data is TLS protected, this will not result 2206 in the application receiving bogus data, but it will constitute a DoS 2207 on the connection. This attack can be countered by using TCP-AO 2208 [RFC5925]. If TCP-AO is used, then any bogus packets injected by an 2209 attacker will be rejected by the TCP-AO integrity check and therefore 2210 will never reach the TLS layer. 2212 In order to prevent leaking internal information outside a client- 2213 domain, client-side DOTS gateways SHOULD NOT reveal the identity of 2214 internal DOTS clients (e.g., source IP address, client's hostname) 2215 unless explicitly configured to do so. 2217 DOTS servers MUST verify that requesting DOTS clients are entitled to 2218 enforce filtering rules on a given IP prefix. That is, only 2219 filtering rules on IP resources that belong to the DOTS client's 2220 domain MUST be authorized by a DOTS server. The exact mechanism for 2221 the DOTS servers to validate that the target prefixes are within the 2222 scope of the DOTS client's domain is deployment-specific. 2224 Rate-limiting DOTS requests, including those with new 'cuid' values, 2225 from the same DOTS client defends against DoS attacks that would 2226 result in varying the 'cuid' to exhaust DOTS server resources. Rate- 2227 limit policies SHOULD be enforced on DOTS gateways (if deployed) and 2228 DOTS servers. 2230 Applying resources quota per DOTS client and/or per DOTS client 2231 domain (e.g., limit the number of aliases and filters to be install 2232 by DOTS clients) prevents DOTS server resources to be aggressively 2233 used by some DOTS clients and ensures, therefore, DDoS mitigation 2234 usage fairness. Additionally, DOTS servers may limit the number of 2235 DOTS clients that can be enabled per domain. 2237 All data nodes defined in the YANG module which can be created, 2238 modified, and deleted (i.e., config true, which is the default) are 2239 considered sensitive. Write operations applied to these data nodes 2240 without proper protection can negatively affect network operations. 2241 Appropriate security measures are recommended to prevent illegitimate 2242 users from invoking DOTS data channel primitives. Nevertheless, an 2243 attacker who can access a DOTS client is technically capable of 2244 launching various attacks, such as: 2246 o Set an arbitrarily low rate-limit, which may prevent legitimate 2247 traffic from being forwarded (rate-limit). 2249 o Set an arbitrarily high rate-limit, which may lead to the 2250 forwarding of illegitimate DDoS traffic (rate-limit). 2252 o Communicate invalid aliases to the server (alias), which will 2253 cause the failure of associating both data and signal channels. 2255 o Set invalid ACL entries, which may prevent legitimate traffic from 2256 being forwarded. Likewise, invalid ACL entries may lead to 2257 forward DDoS traffic. 2259 11. Acknowledgements 2261 Thanks to Christian Jacquenet, Roland Dobbins, Roman Danyliw, Ehud 2262 Doron, Russ White, Gilbert Clark, and Nesredien Suleiman for the 2263 discussion and comments. 2265 12. References 2267 12.1. Normative References 2269 [I-D.ietf-dots-signal-channel] 2270 Reddy, T., Boucadair, M., Patil, P., Mortensen, A., and N. 2271 Teague, "Distributed Denial-of-Service Open Threat 2272 Signaling (DOTS) Signal Channel Specification", draft- 2273 ietf-dots-signal-channel-20 (work in progress), May 2018. 2275 [I-D.ietf-netmod-acl-model] 2276 Jethanandani, M., Huang, L., Agarwal, S., and D. Blair, 2277 "Network Access Control List (ACL) YANG Data Model", 2278 draft-ietf-netmod-acl-model-19 (work in progress), April 2279 2018. 2281 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 2282 Requirement Levels", BCP 14, RFC 2119, 2283 DOI 10.17487/RFC2119, March 1997, 2284 . 2286 [RFC3688] Mealling, M., "The IETF XML Registry", BCP 81, RFC 3688, 2287 DOI 10.17487/RFC3688, January 2004, 2288 . 2290 [RFC4632] Fuller, V. and T. Li, "Classless Inter-domain Routing 2291 (CIDR): The Internet Address Assignment and Aggregation 2292 Plan", BCP 122, RFC 4632, DOI 10.17487/RFC4632, August 2293 2006, . 2295 [RFC5246] Dierks, T. and E. Rescorla, "The Transport Layer Security 2296 (TLS) Protocol Version 1.2", RFC 5246, 2297 DOI 10.17487/RFC5246, August 2008, 2298 . 2300 [RFC7230] Fielding, R., Ed. and J. Reschke, Ed., "Hypertext Transfer 2301 Protocol (HTTP/1.1): Message Syntax and Routing", 2302 RFC 7230, DOI 10.17487/RFC7230, June 2014, 2303 . 2305 [RFC7525] Sheffer, Y., Holz, R., and P. Saint-Andre, 2306 "Recommendations for Secure Use of Transport Layer 2307 Security (TLS) and Datagram Transport Layer Security 2308 (DTLS)", BCP 195, RFC 7525, DOI 10.17487/RFC7525, May 2309 2015, . 2311 [RFC7951] Lhotka, L., "JSON Encoding of Data Modeled with YANG", 2312 RFC 7951, DOI 10.17487/RFC7951, August 2016, 2313 . 2315 [RFC8040] Bierman, A., Bjorklund, M., and K. Watsen, "RESTCONF 2316 Protocol", RFC 8040, DOI 10.17487/RFC8040, January 2017, 2317 . 2319 12.2. Informative References 2321 [I-D.ietf-dots-architecture] 2322 Mortensen, A., Andreasen, F., Reddy, T., 2323 christopher_gray3@cable.comcast.com, c., Compton, R., and 2324 N. Teague, "Distributed-Denial-of-Service Open Threat 2325 Signaling (DOTS) Architecture", draft-ietf-dots- 2326 architecture-06 (work in progress), March 2018. 2328 [I-D.ietf-dots-requirements] 2329 Mortensen, A., Moskowitz, R., and T. Reddy, "Distributed 2330 Denial of Service (DDoS) Open Threat Signaling 2331 Requirements", draft-ietf-dots-requirements-14 (work in 2332 progress), February 2018. 2334 [IEEE.754.1985] 2335 Institute of Electrical and Electronics Engineers, 2336 "Standard for Binary Floating-Point Arithmetic", August 2337 1985. 2339 [proto_numbers] 2340 "IANA, "Protocol Numbers"", 2011, 2341 . 2343 [RFC1983] Malkin, G., Ed., "Internet Users' Glossary", FYI 18, 2344 RFC 1983, DOI 10.17487/RFC1983, August 1996, 2345 . 2347 [RFC3986] Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform 2348 Resource Identifier (URI): Generic Syntax", STD 66, 2349 RFC 3986, DOI 10.17487/RFC3986, January 2005, 2350 . 2352 [RFC4340] Kohler, E., Handley, M., and S. Floyd, "Datagram 2353 Congestion Control Protocol (DCCP)", RFC 4340, 2354 DOI 10.17487/RFC4340, March 2006, 2355 . 2357 [RFC4960] Stewart, R., Ed., "Stream Control Transmission Protocol", 2358 RFC 4960, DOI 10.17487/RFC4960, September 2007, 2359 . 2361 [RFC5389] Rosenberg, J., Mahy, R., Matthews, P., and D. Wing, 2362 "Session Traversal Utilities for NAT (STUN)", RFC 5389, 2363 DOI 10.17487/RFC5389, October 2008, 2364 . 2366 [RFC5925] Touch, J., Mankin, A., and R. Bonica, "The TCP 2367 Authentication Option", RFC 5925, DOI 10.17487/RFC5925, 2368 June 2010, . 2370 [RFC6520] Seggelmann, R., Tuexen, M., and M. Williams, "Transport 2371 Layer Security (TLS) and Datagram Transport Layer Security 2372 (DTLS) Heartbeat Extension", RFC 6520, 2373 DOI 10.17487/RFC6520, February 2012, 2374 . 2376 [RFC6887] Wing, D., Ed., Cheshire, S., Boucadair, M., Penno, R., and 2377 P. Selkirk, "Port Control Protocol (PCP)", RFC 6887, 2378 DOI 10.17487/RFC6887, April 2013, 2379 . 2381 [RFC7950] Bjorklund, M., Ed., "The YANG 1.1 Data Modeling Language", 2382 RFC 7950, DOI 10.17487/RFC7950, August 2016, 2383 . 2385 [RFC8259] Bray, T., Ed., "The JavaScript Object Notation (JSON) Data 2386 Interchange Format", STD 90, RFC 8259, 2387 DOI 10.17487/RFC8259, December 2017, 2388 . 2390 [RFC8340] Bjorklund, M. and L. Berger, Ed., "YANG Tree Diagrams", 2391 BCP 215, RFC 8340, DOI 10.17487/RFC8340, March 2018, 2392 . 2394 Appendix A. Sample Examples: Filtering Fragments 2396 Figure 28 shows a POST request example issued by a DOTS client to its 2397 DOTS server to allow the traffic destined to 198.51.100.0/24 and UDP 2398 port number 53, but to drop all fragmented packets. The following 2399 ACEs are defined (in this order): 2401 o "drop-all-except-last-fragment" ACE: discards all fragments, 2402 except the last fragment. 2404 o "allow-dns-packets" ACE: accepts DNS packets destined to 2405 198.51.100.0/24. 2407 o "drop-last-fragment" ACE: drops the last fragment. 2409 The ACEs order is important to appropriately enforce the intended 2410 filtering policy. For example, if the ACEs order is "allow-dns- 2411 packets" ACE, "drop-all-except-last-fragment" ACE, and then "drop- 2412 last-fragment" ACE, the first fragment won't be dropped because it 2413 includes both L3 and L4 information and will therefore match the 2414 "allow-dns-packets" ACE. 2416 POST /restconf/data/ietf-dots-data-channel:dots-data\ 2417 /dots-client=dz6pHjaADkaFTbjr0JGBpw HTTP/1.1 2418 Host: {host}:{port} 2419 Content-Type: application/yang-data+json 2420 { 2421 "ietf-dots-data-channel:acls": { 2422 "acl": [ 2423 { 2424 "name": "dns-fragments", 2425 "type": "ipv4-acl-type", 2426 "aces": { 2427 "ace": [ 2428 { 2429 "name": "drop-all-except-last-fragment", 2430 "matches": { 2431 "ipv4": { 2432 "flags": "more" 2433 } 2434 }, 2435 "actions": { 2436 "forwarding": "drop" 2437 } 2438 } 2439 ] 2440 "ace": [ 2441 { 2442 "name": "allow-dns-packets", 2443 "matches": { 2444 "ipv4": { 2445 "destination-ipv4-network": "198.51.100.0/24" 2446 } 2447 "udp": { 2448 "destination-port": { 2449 "operator": "eq", 2450 "port": 53 2451 } 2452 }, 2453 "actions": { 2454 "forwarding": "accept" 2455 } 2456 } 2457 ] 2458 "ace": [ 2459 { 2460 "name": "drop-last-fragment", 2461 "matches": { 2462 "ipv4": { 2463 "flags": "" 2464 } 2465 }, 2466 "actions": { 2467 "forwarding": "drop" 2468 } 2469 } 2470 ] 2471 } 2472 } 2473 ] 2474 } 2475 } 2477 Figure 28: Filtering IPv4 Fragmented Packets 2479 Figure 29 shows a POST request example issued by a DOTS client to its 2480 DOTS server to allow the traffic destined to 2001:db8::/32 and UDP 2481 port number 53, but to drop all fragmented packets. The following 2482 ACEs are defined (in this order): 2484 o "drop-all-fragments" ACE: discards all fragments (including atomic 2485 fragments). That is, IPv6 packets which include a Fragment header 2486 (44) are dropped. 2488 o "allow-dns-packets" ACE: accepts DNS packets destined to 2489 2001:db8::/32. 2491 POST /restconf/data/ietf-dots-data-channel:dots-data\ 2492 /dots-client=dz6pHjaADkaFTbjr0JGBpw HTTP/1.1 2493 Host: {host}:{port} 2494 Content-Type: application/yang-data+json 2495 { 2496 "ietf-dots-data-channel:acls": { 2497 "acl": [ 2498 { 2499 "name": "dns-fragments", 2500 "type": "ipv6-acl-type", 2501 "aces": { 2502 "ace": [ 2503 { 2504 "name": "drop-all-fragments", 2505 "matches": { 2506 "ipv6": { 2507 "fragment": [null] 2508 } 2509 }, 2510 "actions": { 2511 "forwarding": "drop" 2512 } 2513 } 2514 ] 2515 "ace": [ 2516 { 2517 "name": "allow-dns-packets", 2518 "matches": { 2519 "ipv6": { 2520 "destination-ipv6-network": "2001:db8::/32" 2521 } 2522 "udp": { 2523 "destination-port": { 2524 "operator": "eq", 2525 "port": 53 2526 } 2527 } 2528 }, 2529 "actions": { 2530 "forwarding": "accept" 2531 } 2532 } 2533 ] 2534 } 2535 } 2536 ] 2537 } 2538 } 2540 Figure 29: Filtering IPv6 Fragmented Packets 2542 Authors' Addresses 2544 Tirumaleswar Reddy (editor) 2545 McAfee, Inc. 2546 Embassy Golf Link Business Park 2547 Bangalore, Karnataka 560071 2548 India 2550 Email: kondtir@gmail.com 2552 Mohamed Boucadair (editor) 2553 Orange 2554 Rennes 35000 2555 France 2557 Email: mohamed.boucadair@orange.com 2559 Kaname Nishizuka 2560 NTT Communications 2561 GranPark 16F 3-4-1 Shibaura, Minato-ku 2562 Tokyo 108-8118 2563 Japan 2565 Email: kaname@nttv6.jp 2567 Liang Xia 2568 Huawei 2569 101 Software Avenue, Yuhuatai District 2570 Nanjing, Jiangsu 210012 2571 China 2573 Email: frank.xialiang@huawei.com 2575 Prashanth Patil 2576 Cisco Systems, Inc. 2578 Email: praspati@cisco.com 2579 Andrew Mortensen 2580 Arbor Networks, Inc. 2581 2727 S. State St 2582 Ann Arbor, MI 48104 2583 United States 2585 Email: amortensen@arbor.net 2587 Nik Teague 2588 Verisign, Inc. 2589 United States 2591 Email: nteague@verisign.com