idnits 2.17.1 draft-ietf-opsawg-mud-acceptable-urls-00.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 : ---------------------------------------------------------------------------- ** The document seems to lack an IANA Considerations section. (See Section 2.2 of https://www.ietf.org/id-info/checklist for how to handle the case when there are no actions for IANA.) ** The document seems to lack a both a reference to RFC 2119 and the recommended RFC 2119 boilerplate, even if it appears to use RFC 2119 keywords. RFC 2119 keyword, line 290: '... The MUD-URL MUST always be an Absolute URI: see [RFC3986] section...' RFC 2119 keyword, line 296: '... in the MUD file SHOULD be a relative ...' RFC 2119 keyword, line 311: '...sulting two strings MUST be identical....' -- The draft header indicates that this document updates RFC8520, but the abstract doesn't seem to directly say this. It does mention RFC8520 though, so this could be OK. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (26 January 2021) is 1183 days in the past. Is this intentional? Checking references for intended status: Best Current Practice ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) No issues found here. Summary: 2 errors (**), 0 flaws (~~), 1 warning (==), 2 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 OPSAWG Working Group M. Richardson 3 Internet-Draft Sandelman Software Works 4 Updates: 8520 (if approved) W. Pan 5 Intended status: Best Current Practice Huawei Technologies 6 Expires: 30 July 2021 E. Lear 7 Cisco Systems 8 26 January 2021 10 Authorized update to MUD URLs 11 draft-ietf-opsawg-mud-acceptable-urls-00 13 Abstract 15 This document provides a way for an RFC8520 Manufacturer Usage 16 Description (MUD) definitions to declare what are acceptable 17 replacement MUD URLs for a device. 19 RFCEDITOR-please-remove: this document is being worked on at: 20 https://github.com/mcr/iot-mud-acceptable-urls 22 Status of This Memo 24 This Internet-Draft is submitted in full conformance with the 25 provisions of BCP 78 and BCP 79. 27 Internet-Drafts are working documents of the Internet Engineering 28 Task Force (IETF). Note that other groups may also distribute 29 working documents as Internet-Drafts. The list of current Internet- 30 Drafts is at https://datatracker.ietf.org/drafts/current/. 32 Internet-Drafts are draft documents valid for a maximum of six months 33 and may be updated, replaced, or obsoleted by other documents at any 34 time. It is inappropriate to use Internet-Drafts as reference 35 material or to cite them other than as "work in progress." 37 This Internet-Draft will expire on 30 July 2021. 39 Copyright Notice 41 Copyright (c) 2021 IETF Trust and the persons identified as the 42 document authors. All rights reserved. 44 This document is subject to BCP 78 and the IETF Trust's Legal 45 Provisions Relating to IETF Documents (https://trustee.ietf.org/ 46 license-info) in effect on the date of publication of this document. 47 Please review these documents carefully, as they describe your rights 48 and restrictions with respect to this document. Code Components 49 extracted from this document must include Simplified BSD License text 50 as described in Section 4.e of the Trust Legal Provisions and are 51 provided without warranty as described in the Simplified BSD License. 53 Table of Contents 55 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 56 2. Updating MUD URLs vs Updating MUD files . . . . . . . . . . . 3 57 2.1. Updating the MUD file in place . . . . . . . . . . . . . 3 58 2.1.1. Adding capabilities . . . . . . . . . . . . . . . . . 3 59 2.1.2. Removing capabilities . . . . . . . . . . . . . . . . 4 60 2.1.3. Significant changes to protocols . . . . . . . . . . 5 61 2.2. Motivation for updating MUD URLs . . . . . . . . . . . . 5 62 3. Threat model for MUD URLs . . . . . . . . . . . . . . . . . . 5 63 3.1. Trust on First Use (TOFU): leveraging the manufacturer 64 signature . . . . . . . . . . . . . . . . . . . . . . . . 5 65 3.2. Concerns about same-signer mechanism . . . . . . . . . . 6 66 4. Outline of proposed mechanism . . . . . . . . . . . . . . . . 6 67 5. Changes to RFC8520 . . . . . . . . . . . . . . . . . . . . . 6 68 6. Privacy Considerations . . . . . . . . . . . . . . . . . . . 8 69 7. Security Considerations . . . . . . . . . . . . . . . . . . . 8 70 7.1. Updating files vs Updating MUD URLs . . . . . . . . . . . 9 71 8. References . . . . . . . . . . . . . . . . . . . . . . . . . 9 72 8.1. Normative References . . . . . . . . . . . . . . . . . . 9 73 8.2. Informative References . . . . . . . . . . . . . . . . . 9 74 Appendix A. Appendices . . . . . . . . . . . . . . . . . . . . . 10 75 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 10 77 1. Introduction 79 [RFC8520] provides a standardized way to describe how a specific 80 purpose device makes use of Internet resources and associated 81 suggested network behavior, which are describled in a MUD file hosted 82 in its manufacture's server. By providing a MUD URL, the network 83 manager can locate this MUD file. MUD URLs can come from a number of 84 sources: 86 * IDevID Extensions 88 * DHCP option 90 * LLDP TLV 92 * [I-D.richardson-opsawg-securehomegateway-mud] proposes to scan 93 them from QRcodes. 95 The IDevID mechanism provides a URL that is asserted 96 cryptographically by a manufacturer. However, it is difficult for 97 manufacturers to update the IDevID of a device which is already in a 98 box. 100 The DHCP and LLDP mechanisms are not signed, but are asserted by the 101 device. A firmware update may update what MUD URL is emitted. 102 Sufficiently well targetted malware could also change the MUD URL. 104 The QRcode mechanism is usually done via paper/stickers, and is 105 typically not under the control of the device itself at all. 107 While MUD files may include signatures, it is not mandatory to check 108 them, and there is not a clear way to connect the entity which signed 109 the MUD file to the device itself. A malicious device does not need 110 to make up a MUD file if there is already an available, and already 111 trusted MUD file which it can use to impersonate the device. 113 One defense against this is to not trust MUD URLs which are different 114 from the one that was placed in an IDevID. Or if the initial MUD URL 115 was not taken from an IDevID, it could be trusted on first use. But, 116 if the MUD controller has locked down the URL, then updates to the 117 URL are difficult to do. 119 2. Updating MUD URLs vs Updating MUD files 121 There are two ways in which a manufacturer can change what the is 122 processed by the MUD controller: they can change what is in the MUD 123 file (update-in-place), and or they change which file is processed by 124 the MUD controller by changing the URL (updated-url). 126 2.1. Updating the MUD file in place 128 One option is for the manufacturer to never change the MUD URL due to 129 firmware updates. The published description is updated whenever the 130 behaviour of the firmware changes. 132 2.1.1. Adding capabilities 134 For situations where new capabilities are added to the firmware, the 135 MUD file will detail the new access that the new firmware requires. 136 This may involve new incoming or outgoing connections that should be 137 authorized. Devices which have been upgraded to the new firmware 138 will make use of the new features. Devices which have not been 139 upgraded to the new firmware may have new connections that are 140 authorized, but which the device does not use (outgoing connections), 141 or for which the device is not prepared to respond to (new incoming 142 connections). 144 It is possible that older versions of the firmware have 145 vulnerabilities which were not easily exploitable due to the MUD file 146 preventing particular kinds of access. As an example, an older 147 firmware could have a no credentials required (or default 148 credentials) access via telnet on port 23 or HTTP on port 80. The 149 MUD file protected the device such that it could either not be 150 accessed at all, or access was restricted to connections from a 151 controller only. 153 Useful and needed upgrades to the firmware could add credentials to 154 that service, permitting it to be opened up for more general access. 155 The new MUD file would provide for such access, but when combined 156 with the weak security of the old firmware, results in a compromised 157 device. 159 While there is an argument that old firmware was insecure and should 160 be replaced, it is often the case that the upgrade process involves 161 downtime, or can introduce risks due to needed evaluations not having 162 been completed yet. As an example: moving vehicles (cars, airplanes, 163 etc.) should not perform upgrades while in motion! It is probably 164 undesireable to perform any upgrade to an airplane outside of its 165 service facility. The owner of a vehicle may desire to only perform 166 software upgrades when they are at home, and could make other 167 arrangements for transporation, rather than when parked at a remote 168 cabin. The situation for upgrades of medical devices has even more 169 considerations involving regulatory compliance. 171 2.1.2. Removing capabilities 173 For situations where existing capabilities prove to be a problem and 174 are to be turned off or removed in subsequent versions of the 175 firmware, the MUD file will be updated to disallow connections that 176 previously were allowed. 178 In this case, the new MUD file will forbid some connection which the 179 old firmware still expects to do. As explained in the previous 180 section, upgrades may not always occur immediately upon release of 181 the new firmware. 183 In this case the old device will be performing unwanted connections, 184 and the MUD controller when be alerting the device owner that the 185 device is mis-behaving. This causes a false positive situation (see 186 [boycrieswolf]), leading to real security issues being ignored. This 187 is a serious issue as documented also in [boywolfinfosec], and 188 [falsemalware]. 190 2.1.3. Significant changes to protocols 192 [I-D.reddy-opsawg-mud-tls] suggests MUD definitions to allow 193 examination of TLS protocol details. Such a profile may be very 194 specific to the TLS library which is shipped in a device. Changes to 195 the library (including bug fixes) may cause significant changes to 196 the profile, requiring changes to the profile described in the MUD 197 file. Such changes are likely neither forward nor backward 198 compatible with other versions, and in place updates to MUD files are 199 therefore not indicated. 201 2.2. Motivation for updating MUD URLs 203 While many small tweaks to a MUD file can be done in place, the 204 situation described above, particularly when it comes to removing 205 capabilities will suggests that changes to the MUD URL. A strategy 206 for doing this securely is needed, and the rest of this document 207 provides a mechanism to do this securely. 209 3. Threat model for MUD URLs 211 Only the DHCP and LLDP MUD URL mechanisms are sufficiently close to 212 the firmware version that they can be easily updated when the 213 firmware is updated. Because of that sensitivity, they may also be 214 easily changed by malware! 216 There are mitigating mechanisms which may be enough to deal with this 217 problem when MUD files are signed by the manufacturer. 219 While [RFC8520] has established a mechanism for signing of MUD files, 220 the document does not define a way for a MUD controller to determine 221 who should sign the MUD file for a particular device. 223 [RFC8520] leaves this for a local policy. There are any number of 224 processes that could be used, but they require coordination of many 225 players. It is expected that each industrial vertical will work out 226 supply chain arrangements or other heuristics. 228 3.1. Trust on First Use (TOFU): leveraging the manufacturer signature 230 Many MUD controllers currently use a Trust on First Use (TOFU) 231 mechanism. The first time a signature from a particular device-type 232 is verified, the identity of the signing authority is recorded. It 233 is pinned. Subsequent updates to that MUD file must be signed by the 234 same entity in order to be accepted. 236 Based upon this process, an update to the MUD URL would be valid if 237 the new MUD file was signed by the same entity that signed the 238 previous entry. This mechanism permits a replacement URL to be any 239 URL that the same manufacturer can provide. 241 3.2. Concerns about same-signer mechanism 243 There is still a potential threat: a manufacturer which has many 244 products may have a MUD definition for another product that has the 245 privileges that the malware desires. 247 The malware could simply change the expressed MUD URL to that of the 248 other product, and it will be accepted by the MUD controller as 249 valid. 251 This works as long as manufacturers use a single key to sign all 252 products. Some manufacturers could sign each product with a 253 different key. Possibly, all the keys are collected into a single 254 PKI, signed by a common certification authority. In this case, the 255 question as to whether the MUD controller should pin the end-entity 256 (EE) certificate, or the CA certificate. Pinning the EE certificate 257 defends against malware that changes the product type, but keeps the 258 manufacturer from being able to cycle the validity of the End-Entity 259 Certificate for cryptographic hygiene reasons. Pinning the CA 260 certificate allows the EE certificate to change, but may not defend 261 against product type changes. 263 It is possible to invent policy mechanisms that would link the EE 264 certificate to a value that is in the MUD file. This could be a 265 policy OID, or could involve some content in a subjectAltName. 266 Future work could go in this direction. This document proposes a 267 simpler solution. 269 4. Outline of proposed mechanism 271 The document proposes to limit what MUD URLs are considered valid 272 from the device, limiting new MUD URLs to be variations of the 273 initial (presumed to be secure) URL. 275 5. Changes to RFC8520 277 The first MUD file which is defined for a device can come from an 278 IDevID (which is considered more secure), or via Trust on First Use 279 with DHCP or LLDP or another mechanism. 281 This first, initially trusted, MUD file will be called the "root" MUD 282 file. 284 MUD files contain a self-referential MUD-URL attribute that point to 285 a MUD file located on the vendor's web site. While the IDevID, DHCP 286 and LLDP mechanisms only transmit a URL, there are some newer, not 287 yet standardized proposals that would fetch an entire MUD file from 288 the device, such as [I-D.jimenez-t2trg-mud-coap]. 290 The MUD-URL MUST always be an Absolute URI: see [RFC3986] section 291 4.3. 293 The URL found in the MUD-URL attribute is to be called the canonical 294 MUD URL for the device. 296 The MUD-SIGNATURE attribute in the MUD file SHOULD be a relative URI 297 (see [RFC3986] section 4.2) with the (hierarchical) base URL for this 298 reference being the MUD-URL attribute. 300 Subsequent MUD files are considered valid if: 302 * have the same initial Base-URI as the MUD-URL, but may have a 303 different final part 305 * they are signed by the same End Entity (same trusted CA and same 306 SubjectAltName) as the "root" MUD file. 308 Section 5.2 of [RFC3986] details many cases for calculating the Base- 309 URI. The test is simplified to: remove everything to the right of 310 the last (rightmost) "/" in the URL of "root" MUD file URL, and the 311 proposed new URL. The resulting two strings MUST be identical. 313 For as a simple example, if the "root" mud-url is 314 http://example.com/hello/there/file.json then any URL that starts 315 with http://example.com/hello/there/ would be acceptable, such as 316 http://example.com/hello/there/revision2.json. 318 Once the new MUD file is accepted, then it becomes the new "root" MUD 319 file, and any subsequent updates must be relative to the MUD-URL in 320 the new file. 322 This process allows a manufacturer to rework their file structure, to 323 change web server hostnames (such as when there is an acquisition or 324 merger), etc. so long as they retain the old structure long enough 325 for all devices to upgrade at least once. 327 (XXX: how should the trust anchor for the signature be updated when 328 there is Merger&Acquisition) 330 6. Privacy Considerations 332 The MUD URL contains sensitive model and even firmware revision 333 numbers. Thus the MUD URL identifies the make, model and revision of 334 a device. [RFC8520] already identifies this privacy concern, and 335 suggests use of TLS so that the HTTP requests that retrieve the MUD 336 file do not divulge that level of detail. However, it is possible 337 that even observing the traffic to that manufacturer may be 338 revealing, and [RFC8520] goes on to suggest use of a proxy as well. 340 7. Security Considerations 342 Prior to the standardization of the process in this document, if a 343 device was infiltrated by malware, and said malware wished to make 344 accesses beyond what the current MUD file allowed, the the malware 345 would have to: 347 1. arrange for an equivalent MUD file to be visible somewhere on the 348 Internet 350 2. depend upon the MUD-manager either not checking signatures, or 352 3. somehow get the manufacturer to sign the alternate MUD 354 4. announce this new URL via DHCP or LLDP, updating the MUD-manager 355 with the new permissions. 357 One way to accomplish (3) is to leverage the existence of MUD files 358 created by the manufacturer for different classes of devices. Such 359 files would already be signed by the same manufacturer, eliminating 360 the need to spoof a signature. 362 With the standardization of the process in this document, then the 363 attacker can no longer point to arbitrary MUD files in step 4, but 364 can only make use of MUD files that the manufacturer has already 365 provided for this device. 367 Manufacturers are advised to maintain an orderly layout of MUD files 368 in their web servers, with each unique producting having its own 369 directory/pathname. 371 The process described updates only MUD-managers and the processes 372 that manufacturers use to manage the location of their MUD files. 374 A manufacturer which has not managed their MUD files in the the way 375 described here can deploy new directories of per-product MUD files, 376 and then can update the existing MUD files in place to point to the 377 new URLs using the MUD-URL attribute. 379 There is therefore no significant flag day: MUD managers may 380 implement the new policy without significant concern about backwards 381 compatibility. 383 7.1. Updating files vs Updating MUD URLs 385 Device developers need to consider whether to make a change by 386 updating a MUD file, or updating the MUD URL. 388 MUD URLs can only be updated by shipping a new firmware. It is 389 reasonable to update the MUD URL whenever a new firmware release 390 causes new connectivity to be required. The updated mechanism 391 defined in this document makes this a secure operation, and there is 392 no practical limitation on the number of files that a web server can 393 hold. 395 In place updates to a MUD file should be restricted to cases where it 396 turns out that the description was inaccurate: a missing connection, 397 an inadvertent one authorized, or just incorrect information. 399 Developers should be aware that many enterprise web sites use 400 outsourced content distribution networks, and MUD controllers are 401 likely to cache files for some time. Changes to MUD files will take 402 some time to propogate through the various caches. An updated MUD 403 URL will however, not experience any cache issues, but can not be 404 deployed with a firmware update. 406 8. References 408 8.1. Normative References 410 [RFC3986] Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform 411 Resource Identifier (URI): Generic Syntax", STD 66, 412 RFC 3986, DOI 10.17487/RFC3986, January 2005, 413 . 415 [RFC8520] Lear, E., Droms, R., and D. Romascanu, "Manufacturer Usage 416 Description Specification", RFC 8520, 417 DOI 10.17487/RFC8520, March 2019, 418 . 420 8.2. Informative References 422 [boycrieswolf] 423 "The Boy Who Cried Wolf", 18 January 2020, 424 . 426 [boywolfinfosec] 427 "Security Alerts - A Case of the Boy Who Cried Wolf?", 18 428 January 2020, . 431 [falsemalware] 432 "False malware alerts cost organizations $1.27M annually, 433 report says", 18 January 2020, 434 . 438 [I-D.jimenez-t2trg-mud-coap] 439 Jimenez, J., "Using MUD on CoAP environments", Work in 440 Progress, Internet-Draft, draft-jimenez-t2trg-mud-coap-00, 441 9 March 2020, . 444 [I-D.reddy-opsawg-mud-tls] 445 Reddy.K, T., Wing, D., and B. Anderson, "MUD (D)TLS 446 profiles for IoT devices", Work in Progress, Internet- 447 Draft, draft-reddy-opsawg-mud-tls-05, 31 August 2020, 448 . 451 [I-D.richardson-opsawg-securehomegateway-mud] 452 Richardson, M., Latour, J., and H. Gharakheili, "On 453 loading MUD URLs from QR codes", Work in Progress, 454 Internet-Draft, draft-richardson-opsawg-securehomegateway- 455 mud-05, 8 September 2020, . 459 Appendix A. Appendices 461 Authors' Addresses 463 Michael Richardson 464 Sandelman Software Works 466 Email: mcr+ietf@sandelman.ca 468 Wei Pan 469 Huawei Technologies 471 Email: william.panwei@huawei.com 472 Eliot Lear 473 Cisco Systems 475 Email: lear@cisco.com