idnits 2.17.1 draft-bryan-metalink-01.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- ** It looks like you're using RFC 3978 boilerplate. You should update this to the boilerplate described in the IETF Trust License Policy document (see https://trustee.ietf.org/license-info), which is required now. -- Found old boilerplate from RFC 3978, Section 5.1 on line 15. -- Found old boilerplate from RFC 3978, Section 5.5, updated by RFC 4748 on line 1693. -- Found old boilerplate from RFC 3979, Section 5, paragraph 1 on line 1704. -- Found old boilerplate from RFC 3979, Section 5, paragraph 2 on line 1711. -- Found old boilerplate from RFC 3979, Section 5, paragraph 3 on line 1717. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust Copyright Line does not match the current year -- The document seems to lack a disclaimer for pre-RFC5378 work, but may have content which was first submitted before 10 November 2008. If you have contacted all the original authors and they are all willing to grant the BCP78 rights to the IETF Trust, then this is fine, and you can ignore this comment. If not, you may need to add the pre-RFC5378 disclaimer. (See the Legal Provisions document at https://trustee.ietf.org/license-info for more information.) -- The document date (August 28, 2008) is 5692 days in the past. Is this intentional? -- Found something which looks like a code comment -- if you have code sections in the document, please surround them with '' and '' lines. Checking references for intended status: Experimental ---------------------------------------------------------------------------- ** Obsolete normative reference: RFC 1320 (Obsoleted by RFC 6150) ** Obsolete normative reference: RFC 2616 (Obsoleted by RFC 7230, RFC 7231, RFC 7232, RFC 7233, RFC 7234, RFC 7235) ** Obsolete normative reference: RFC 2818 (Obsoleted by RFC 9110) ** Obsolete normative reference: RFC 3023 (Obsoleted by RFC 7303) ** Obsolete normative reference: RFC 4634 (Obsoleted by RFC 6234) Summary: 6 errors (**), 0 flaws (~~), 1 warning (==), 8 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group A. Bryan, Ed. 3 Internet-Draft Metalinker Project 4 Intended status: Experimental August 28, 2008 5 Expires: March 1, 2009 7 The Metalink Download Description Format 8 draft-bryan-metalink-01 10 Status of this Memo 12 By submitting this Internet-Draft, each author represents that any 13 applicable patent or other IPR claims of which he or she is aware 14 have been or will be disclosed, and any of which he or she becomes 15 aware will be disclosed, in accordance with Section 6 of BCP 79. 17 Internet-Drafts are working documents of the Internet Engineering 18 Task Force (IETF), its areas, and its working groups. Note that 19 other groups may also distribute working documents as Internet- 20 Drafts. 22 Internet-Drafts are draft documents valid for a maximum of six months 23 and may be updated, replaced, or obsoleted by other documents at any 24 time. It is inappropriate to use Internet-Drafts as reference 25 material or to cite them other than as "work in progress." 27 The list of current Internet-Drafts can be accessed at 28 http://www.ietf.org/ietf/1id-abstracts.txt. 30 The list of Internet-Draft Shadow Directories can be accessed at 31 http://www.ietf.org/shadow.html. 33 This Internet-Draft will expire on March 1, 2009. 35 Abstract 37 This document specifies Metalink Documents, an XML-based download 38 description format. 40 Table of Contents 42 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 4 43 1.1. Examples . . . . . . . . . . . . . . . . . . . . . . . . . 4 44 1.2. Namespace and Version . . . . . . . . . . . . . . . . . . 5 45 1.3. Notational Conventions . . . . . . . . . . . . . . . . . . 5 46 2. Metalink Documents . . . . . . . . . . . . . . . . . . . . . . 6 47 3. Common Metalink Constructs . . . . . . . . . . . . . . . . . . 7 48 3.1. Text Constructs . . . . . . . . . . . . . . . . . . . . . 7 49 3.1.1. Text . . . . . . . . . . . . . . . . . . . . . . . . . 7 50 3.2. Date Constructs . . . . . . . . . . . . . . . . . . . . . 8 51 4. Metalink Element Definitions . . . . . . . . . . . . . . . . . 8 52 4.1. Container Elements . . . . . . . . . . . . . . . . . . . . 8 53 4.1.1. The "metalink:metalink" Element . . . . . . . . . . . 9 54 4.1.2. The "metalink:files" Element . . . . . . . . . . . . . 10 55 4.1.3. The "metalink:file" Element . . . . . . . . . . . . . 11 56 4.1.4. The "metalink:resources" Element . . . . . . . . . . . 12 57 4.1.5. The "metalink:verification" Element . . . . . . . . . 13 58 4.1.6. The "metalink:pieces" Element . . . . . . . . . . . . 13 59 4.2. Metadata Elements . . . . . . . . . . . . . . . . . . . . 14 60 4.2.1. The "metalink:copyright" Element . . . . . . . . . . . 14 61 4.2.2. The "metalink:description" Element . . . . . . . . . . 14 62 4.2.3. The "metalink:generator" Element . . . . . . . . . . . 15 63 4.2.4. The "metalink:hash" Element . . . . . . . . . . . . . 15 64 4.2.5. The "metalink:identity" Element . . . . . . . . . . . 16 65 4.2.6. The "metalink:language" Element . . . . . . . . . . . 17 66 4.2.7. The "metalink:license" Element . . . . . . . . . . . . 17 67 4.2.8. The "metalink:logo" Element . . . . . . . . . . . . . 17 68 4.2.9. The "metalink:origin" Element . . . . . . . . . . . . 17 69 4.2.10. The "metalink:os" Element . . . . . . . . . . . . . . 18 70 4.2.11. The "metalink:published" Element . . . . . . . . . . . 18 71 4.2.12. The "metalink:publisher" Element . . . . . . . . . . . 18 72 4.2.13. The "metalink:signature" Element . . . . . . . . . . . 19 73 4.2.14. The "metalink:size" Element . . . . . . . . . . . . . 19 74 4.2.15. The "metalink:type" Element . . . . . . . . . . . . . 19 75 4.2.16. The "metalink:updated" Element . . . . . . . . . . . . 20 76 4.2.17. The "metalink:url" Element . . . . . . . . . . . . . . 20 77 4.2.18. The "metalink:version" Element . . . . . . . . . . . . 21 78 5. Securing Metalink Documents . . . . . . . . . . . . . . . . . 22 79 5.1. Digital Signatures . . . . . . . . . . . . . . . . . . . . 22 80 5.2. Encryption . . . . . . . . . . . . . . . . . . . . . . . . 23 81 5.3. Signing and Encrypting . . . . . . . . . . . . . . . . . . 23 82 6. Extending Metalink . . . . . . . . . . . . . . . . . . . . . . 23 83 6.1. Extensions from Non-Metalink Vocabularies . . . . . . . . 24 84 6.2. Extensions to the Metalink Vocabulary . . . . . . . . . . 24 85 6.3. Processing Foreign Markup . . . . . . . . . . . . . . . . 24 86 6.4. Extension Elements . . . . . . . . . . . . . . . . . . . . 24 87 6.4.1. Simple Extension Elements . . . . . . . . . . . . . . 24 88 6.4.2. Structured Extension Elements . . . . . . . . . . . . 25 89 7. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 25 90 8. Security Considerations . . . . . . . . . . . . . . . . . . . 26 91 8.1. URIs . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 92 8.2. IRIs . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 93 8.3. Spoofing . . . . . . . . . . . . . . . . . . . . . . . . . 27 94 8.4. Encryption and Signing . . . . . . . . . . . . . . . . . . 27 95 9. References . . . . . . . . . . . . . . . . . . . . . . . . . . 27 96 9.1. Normative References . . . . . . . . . . . . . . . . . . . 27 97 9.2. Informative References . . . . . . . . . . . . . . . . . . 29 98 Appendix A. Contributors . . . . . . . . . . . . . . . . . . . . 30 99 Appendix B. RELAX NG Compact Schema . . . . . . . . . . . . . . . 31 100 Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34 101 Author's Address . . . . . . . . . . . . . . . . . . . . . . . . . 37 102 Intellectual Property and Copyright Statements . . . . . . . . . . 38 104 1. Introduction 106 Metalink is an XML-based document format that describes a file or 107 lists of files to be added to a download queue. Lists are composed 108 of a number of files, each with an extensible set of attached 109 metadata. For example, each file can have a description, checksum, 110 and list of URIs that it is available from. 112 The primary use case that Metalink addresses is the description of 113 downloadable content in a format so download agents can act 114 intelligently and recover from common errors with little or no user 115 interaction necessary. These errors can include multiple servers 116 going down and data corrupted in transmission. 118 1.1. Examples 120 A brief, single file Metalink Document: 122 123 124 125 126 127 ftp://ftp.example.com/example.ext 128 http://example.com/example.ext 129 http://example.com/example.ext.torrent 130 131 132 133 134 135 A more extensive, single file Metalink Document: 137 138 139 2008-05-15T12:23:23Z 140 141 142 Example 143 1.0 144 A description of the example file for 145 download. 146 147 83b1a04f18d6782cfe0407edadac377f 148 80bc95fd391772fa61c91ed68567f0980bb45fd9 149 150 151 152 ftp://ftp.example.com/example.ext 153 http://example.com/example.ext 154 http://example.com/example.ext.torrent 155 156 157 158 159 161 1.2. Namespace and Version 163 The XML Namespaces URI [REC-xml-names] for the XML data format 164 described in this specification is: 166 http://www.metalinker.org/ 168 For convenience, this data format may be referred to as "Metalink 169 3.0". This specification uses "Metalink" internally. 171 1.3. Notational Conventions 173 This specification describes conformance of Metalink Documents. 174 Additionally, it places some requirements on Metalink Processors. 176 This specification uses the namespace prefix "metalink:" for the 177 Namespace URI identified in Section 1.2, above. Note that the choice 178 of namespace prefix is arbitrary and not semantically significant. 180 Metalink is specified using terms from the XML Infoset 181 [REC-xml-infoset]. However, this specification uses a shorthand for 182 two common terms: the phrase "Information Item" is omitted when 183 naming Element Information Items and Attribute Information Items. 184 Therefore, when this specification uses the term "element," it is 185 referring to an Element Information Item in Infoset terms. Likewise, 186 when it uses the term "attribute," it is referring to an Attribute 187 Information Item. 189 Some sections of this specification are illustrated with fragments of 190 a non-normative RELAX NG Compact schema [RELAX-NG]. However, the 191 text of this specification provides the definition of conformance. A 192 complete schema appears in Appendix B. 194 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 195 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 196 document are to be interpreted as described in BCP 14, [RFC2119], as 197 scoped to those conformance targets. 199 2. Metalink Documents 201 This specification describes Metalink Documents. 203 A Metalink Document describes a file or group of files, how to access 204 them, and metadata that identifies them. Its root is the metalink: 205 metalink element. 207 namespace metalink = "http://www.metalinker.org" 208 start = metalinkMetalink 210 Metalink Documents are specified in terms of the XML Information Set, 211 serialized as XML 1.0 [REC-xml] and identified with the "application/ 212 metalink+xml" media type. Metalink Documents MUST be well-formed 213 XML. This specification does not define a DTD for Metalink 214 Documents, and hence does not require them to be valid (in the sense 215 used by XML). 217 Metalink allows the use of IRIs [RFC3987]. Every URI [RFC3986] is 218 also an IRI, so a URI may be used wherever below an IRI is named. 219 There is one special consideration: when an IRI that is not also a 220 URI is given for dereferencing, it MUST be mapped to a URI using the 221 steps in Section 3.1 of [RFC3987]. 223 Any element defined by this specification MAY have an xml:base 224 attribute [REC-xmlbase]. When xml:base is used in an Metalink 225 Document, it serves the function described in Section 5.1.1 of 226 [RFC3986], establishing the base URI (or IRI) for resolving any 227 relative references found within the effective scope of the xml:base 228 attribute. 230 Any element defined by this specification MAY have an xml:lang 231 attribute, whose content indicates the natural language for the 232 element and its descendents. The language context is only 233 significant for elements and attributes declared to be "Language- 234 Sensitive" by this specification. Requirements regarding the content 235 and interpretation of xml:lang are specified in XML 1.0 [REC-xml], 236 Section 2.12. 238 metalinkCommonAttributes = 239 attribute xml:base { metalinkUri }?, 240 attribute xml:lang { metalinkLanguageTag }?, 241 undefinedAttribute* 243 Metalink is an extensible format. See Section 6 of this document for 244 a full description of how Metalink Documents can be extended. 246 3. Common Metalink Constructs 248 Many of Metalink's elements share a few common structures. This 249 section defines those structures and their requirements for 250 convenient reference by the appropriate element definitions. 252 When an element is identified as being a particular kind of 253 construct, it inherits the corresponding requirements from that 254 construct's definition in this section. 256 Note that there MUST NOT be any white space in a Date construct or in 257 any IRI. Some XML-emitting implementations erroneously insert white 258 space around values by default, and such implementations will emit 259 invalid Metalink Documents. 261 3.1. Text Constructs 263 A Text construct contains human-readable text, usually in small 264 quantities. The content of Text constructs is Language-Sensitive. 266 metalinkTextConstruct = 267 metalinkCommonAttributes, 268 text 270 3.1.1. Text 272 Example metalink:description with text content: 274 ... 275 276 A description of the example file for download. 277 278 ... 280 The content of the Text construct MUST NOT contain child elements. 281 Such text is intended to be presented to humans in a readable 282 fashion. Thus, Metalink Processors MAY collapse white space 283 (including line breaks) and display the text using typographic 284 techniques such as justification and proportional fonts. 286 3.2. Date Constructs 288 A Date construct is an element whose content MUST conform to the 289 "date-time" production in [RFC3339]. In addition, an uppercase "T" 290 character MUST be used to separate date and time, and an uppercase 291 "Z" character MUST be present in the absence of a numeric time zone 292 offset. 294 metalinkDateConstruct = 295 metalinkCommonAttributes, 296 xsd:dateTime 298 Such date values happen to be compatible with the following 299 specifications: [ISO.8601.1988], [W3C.NOTE-datetime-19980827], and 300 [W3C.REC-xmlschema-2-20041028]. 302 Example Date constructs: 304 2008-12-13T18:30:02Z 305 2008-12-13T18:30:02.25Z 306 2008-12-13T18:30:02+01:00 307 2008-12-13T18:30:02.25+01:00 309 Date values SHOULD be as accurate as possible. For example, it would 310 be generally inappropriate for a publishing system to apply the same 311 timestamp to several entries that were published during the course of 312 a single day. 314 4. Metalink Element Definitions 316 4.1. Container Elements 317 4.1.1. The "metalink:metalink" Element 319 The "metalink:metalink" element is the document (i.e., top-level) 320 element of a Metalink Document, acting as a container for metadata 321 and data associated with the listed files. It contains one 322 "metalink:files" element whose element children consist of metadata 323 elements followed by one or more metalink:file child elements. 325 metalinkMetalink = 326 element metalink:metalink { 327 metalinkCommonAttributes, 328 (metalinkPublished? 329 & metalinkOrigin? 330 & metalinkGenerator? 331 & metalinkUpdated? 332 & extensionElement*), 333 metalinkFiles 334 } 336 The following child elements are defined by this specification (note 337 that the presence of some of these elements is required): 339 o metalink:metalink elements MUST contain exactly one metalink:files 340 element. 341 o metalink:metalink elements MAY contain exactly one metalink:origin 342 element. If metalink:type is "dynamic", metalink:metalink 343 elements MUST contain exactly one metalink:origin element. 344 o metalink:metalink elements MAY contain exactly one metalink:type 345 element. 346 o metalink:metalink elements MAY contain exactly one metalink: 347 generator element. 348 o metalink:metalink elements MAY contain exactly one metalink: 349 published element. 350 o metalink:metalink elements MAY contain exactly one metalink: 351 updated element. If metalink:type is "dynamic", metalink:metalink 352 elements MUST contain exactly one metalink:updated element. 354 4.1.1.1. Providing Textual Content 356 Experience teaches that downloads providing textual content are in 357 general more useful than those that do not. Some applications (one 358 example is full-text indexers) require a minimum amount of text to 359 function reliably and predictably. Metalink publishers should be 360 aware of these issues. It is advisable that each metalink:file 361 element contain a non-empty metalink:description element, a non-empty 362 metalink:identity element when that element is present, and a non- 363 empty metalink:version element, and a non-empty metalink:publisher 364 element. However, the absence of metalink:description is not an 365 error, and Metalink Processors MUST NOT fail to function correctly as 366 a consequence of such an absence. 368 4.1.2. The "metalink:files" Element 370 The "metalink:files" element acts as a container for metadata and 371 data associated with the listed files. It contains one or more 372 metalink:file child elements. Certain elements can be listed either 373 under metalink:files or metalink:file. If under metalink:files, they 374 apply to all files listed in each metalink:file. If under metalink: 375 file, then they apply to just that specific file. 377 metalinkFiles = 378 element metalink:files { 379 metalinkCommonAttributes, 380 (metalinkIdentity? 381 & metalinkVersion? 382 & metalinkDescription? 383 & metalinkOS? 384 & metalinkLogo? 385 & metalinkLanguage? 386 & metalinkPublisher? 387 & metalinkCopyright? 388 & metalinkLicense? 389 & extensionElement*) 390 metalinkFile 391 } 393 The following child elements are defined by this specification (note 394 that the presence of some of these elements is required): 396 o metalink:files element MUST contain one or more metalink:file 397 elements. 398 o metalink:files elements SHOULD contain exactly one metalink: 399 identity element. 400 o metalink:files elements SHOULD contain exactly one metalink: 401 version element. 402 o metalink:files elements MAY contain exactly one metalink: 403 description element. 404 o metalink:files elements MAY contain exactly one metalink:os 405 element. 406 o metalink:files elements MAY contain exactly one metalink:logo 407 element. 408 o metalink:files elements MAY contain exactly one metalink:language 409 element. 410 o metalink:files elements MAY contain exactly one metalink:publisher 411 element. 413 o metalink:files elements MAY contain exactly one metalink:copyright 414 element. 415 o metalink:files elements MAY contain exactly one metalink:license 416 element. 418 4.1.3. The "metalink:file" Element 420 The "metalink:file" element represents an individual file, acting as 421 a container for metadata and data associated with the file. 423 metalinkFile = 424 element metalink:file { 425 metalinkCommonAttributes, 426 attribute name { metalinkTextConstruct }, 427 (metalinkVerification? 428 & metalinkIdentity? 429 & metalinkVersion? 430 & metalinkDescription? 431 & metalinkSize? 432 & metalinkOS? 433 & metalinkLogo? 434 & metalinkLanguage? 435 & metalinkPublisher? 436 & metalinkCopyright? 437 & metalinkLicense? 438 & extensionElement*) 439 metalinkResources 440 } 442 This specification assigns no significance to the order of metalink: 443 file elements. 445 The following child elements are defined by this specification (note 446 that it requires the presence of some of these elements): 448 o metalink:file elements MUST contain exactly one metalink:resources 449 element. 450 o metalink:file elements SHOULD contain exactly one metalink: 451 verification element. 452 o metalink:file elements SHOULD contain exactly one metalink: 453 identity element. 454 o metalink:file elements SHOULD contain exactly one metalink:version 455 element. 456 o metalink:file elements MAY contain exactly one metalink: 457 description element. 458 o metalink:file elements SHOULD contain exactly one metalink:size 459 element. 461 o metalink:file elements MAY contain exactly one metalink:os 462 element. 463 o metalink:file elements MAY contain exactly one metalink:logo 464 element. 465 o metalink:file elements MAY contain exactly one metalink:language 466 element. 467 o metalink:file elements MAY contain exactly one metalink:publisher 468 element. 469 o metalink:file elements MAY contain exactly one metalink:copyright 470 element. 471 o metalink:file elements MAY contain exactly one metalink:license 472 element. 474 4.1.3.1. The "name" Attribute 476 metalink:file elements MUST have a "name" attribute, which contains 477 the filename of the file downloaded. 479 Directory information can also be contained in a "path/file" format 480 only, as in: 482 484 In this example, a subdirectory debian-amd64/sarge/ will be created 485 and a file named Contents-amd64.gz will be created inside it. The 486 path MUST be relative. The path MUST NOT begin with a "/", "./" or 487 "../", contain "/../", or end with "/..". Metalink Processors MUST 488 NOT allow directory traversal. 490 A Metalink Processor MAY alter the name of the subdirectory or file 491 if they contain characters which are invalid in the destination 492 filesystem. 494 4.1.4. The "metalink:resources" Element 496 The "metalink:resources" element acts as a container for metadata and 497 data associated with the listed files. It contains one or more 498 metalink:url child elements. 500 metalinkResources = 501 element metalink:resources { 502 metalinkCommonAttributes, 503 extensionElement* 504 metalinkURL* 505 } 507 This specification assigns no significance to the order of metalink: 508 url elements. Significance is determined by the value of the 509 "preference" attribute of the metalink:url elements. 511 The following child elements are defined by this specification (note 512 that the presence of some of these elements is required): 514 o metalink:resources element MUST contain one and SHOULD contain 515 more than one metalink:url elements. 517 4.1.5. The "metalink:verification" Element 519 The "metalink:verification" element acts as a container for metadata 520 and data associated with verifying the listed files. This 521 information is in the form of checksums and digital signatures. 522 Checksums are used to verify the integrity of a file or portion of a 523 file to determine if the files have been transferred without any 524 errors. Digital signatures verify that a file is from the entity 525 that has signed it. 527 metalinkVerification = 528 element metalink:verification { 529 metalinkCommonAttributes, 530 (metalinkHash* 531 & metalinkPieces* 532 & metalinkSignature 533 & extensionElement*) 534 } 536 The following child elements are defined by this specification (note 537 that the presence of some of these elements is required): 539 o metalink:verification element MAY contain one or more metalink: 540 hash elements. 541 o metalink:verification element MAY contain one or more metalink: 542 pieces elements. 543 o metalink:verification element MAY contain exactly one metalink: 544 signature elements. 546 4.1.6. The "metalink:pieces" Element 548 The "metalink:pieces" element is a Text construct that conveys a 549 human-readable piece information for a file. 551 metalinkPieces = 552 element metalink:pieces { 553 attribute length { metalinkTextConstruct }, 554 attribute type { "crc32" | "md4" | "md5" | "sha1" | 555 "sha256" | "sha384" | "sha512" | "rmd160" | "tiger" }, 556 hash+ 558 }+, 560 4.1.6.1. The "type" Attribute 562 metalink:pieces elements MUST have a "type" attribute. 564 This document defines nine initial values for hash types. It may be 565 useful to extend Metalink documents with new verification methods, so 566 unknown types are allowed. 567 1. The value "crc32" signifies that the information is CRC32. 568 2. The value "md4" signifies that the hash information is MD4, as 569 specified in [RFC1320]. 570 3. The value "md5" signifies that the hash information is MD5, as 571 specified in [RFC1321]. 572 4. The value "sha1" signifies that the hash information is SHA1, as 573 specified in [RFC3174]. 574 5. The value "sha256" signifies that the hash information is SHA- 575 256, as specified in [RFC4634]. 576 6. The value "sha384" signifies that the hash information is SHA- 577 384, as specified in [RFC4634]. 578 7. The value "sha512" signifies that the hash information is SHA- 579 512, as specified in [RFC4634]. 580 8. The value "rmd160" signifies that the hash information is RMD160, 581 as specified in [RIPE]. 582 9. The value "tiger" signifies that the hash information is TIGER. 584 4.1.6.2. The "length" Attribute 586 metalink:pieces elements MUST have a "length" attribute, which is an 587 integer that describes the length of the piece of the file in octets. 589 4.2. Metadata Elements 591 4.2.1. The "metalink:copyright" Element 593 The "metalink:copyright" element is a Text construct that conveys a 594 human-readable copyright for a file. 596 metalinkCopyright = 597 element metalink:copyright { 598 metalinkTextConstruct 599 } 601 4.2.2. The "metalink:description" Element 603 The "metalink:description" element is a Text construct that conveys a 604 human-readable description for a file. 606 metalinkDescription = 607 element metalink:description { 608 metalinkTextConstruct 609 } 611 4.2.3. The "metalink:generator" Element 613 The "metalink:generator" element's content identifies the agent used 614 to generate a Metalink Document, for debugging and other purposes. 616 metalinkGenerator = element metalink:generator { 617 metalinkCommonAttributes, 618 attribute uri { metalinkUri }?, 619 attribute version { text }?, 620 text 621 } 623 The content of this element, when present, MUST be a string that is a 624 human-readable name for the generating agent. Entities such as 625 "&" and "<" represent their corresponding characters ("&" and 626 "<" respectively), not markup. 628 The metalink:generator element MAY have a "uri" attribute whose value 629 MUST be an IRI reference [RFC3987]. When dereferenced, the resulting 630 URI (mapped from an IRI, if necessary) SHOULD produce a 631 representation that is relevant to that agent. 633 The metalink:generator element MAY have a "version" attribute that 634 indicates the version of the generating agent. 636 4.2.4. The "metalink:hash" Element 638 The "metalink:hash" element is a Text construct that conveys a human- 639 readable hash for a file. 641 metalinkHash = 642 element metalink:hash { 643 attribute piece { xsd:integer }?, 644 attribute type { "crc32" | "md4" | "md5" | "sha1" | 645 "sha256" | "sha384" | "sha512" | "rmd160" | "tiger" }, 646 text 647 } 649 4.2.4.1. The "type" Attribute 651 metalink:hash elements MUST have a "type" attribute or a "piece" 652 attribute. metalink:hash elements with a "type" attribute contain a 653 hash of the whole file. metalink:hash elements with a "piece" 654 attribute contain a hash for that specific piece or chunk of the 655 file. All hashes are in lowercase hexadecimal format. 657 When multiple hash types methods are provided, a Metalink Processor 658 MAY verify using more than one of these hash types. Metalink 659 Processors are encouraged to check all hash types given which they 660 are able to process 662 This document defines nine initial values for hash types. It may be 663 useful to extend Metalink documents with new verification methods, so 664 unknown types are allowed. 665 1. The value "crc32" signifies that the information is CRC32. 666 2. The value "md4" signifies that the hash information is MD4, as 667 specified in [RFC1320]. 668 3. The value "md5" signifies that the hash information is MD5, as 669 specified in [RFC1321]. 670 4. The value "sha1" signifies that the hash information is SHA1, as 671 specified in [RFC3174]. 672 5. The value "sha256" signifies that the hash information is SHA- 673 256, as specified in [RFC4634]. 674 6. The value "sha384" signifies that the hash information is SHA- 675 384, as specified in [RFC4634]. 676 7. The value "sha512" signifies that the hash information is SHA- 677 512, as specified in [RFC4634]. 678 8. The value "rmd160" signifies that the hash information is RMD160, 679 as specified in [RIPE]. 680 9. The value "tiger" signifies that the hash information is TIGER. 682 4.2.4.2. The "piece" Attribute 684 metalink:hash elements MAY have a "piece" attribute, only when they 685 are a sub element of metalink:pieces. The value of "piece" starts at 686 "0" and increases, depending on the "length" attribute of metalink: 687 pieces and the size of the file. 689 4.2.5. The "metalink:identity" Element 691 The "metalink:identity" element is a Text construct that conveys a 692 human-readable identity for a file. The identity of OpenOffice.org 693 3.0 would be "OpenOffice.org". 695 metalinkIdentity = 696 element metalink:identity { 697 metalinkTextConstruct 698 } 700 4.2.6. The "metalink:language" Element 702 The "metalink:language" element is a Text construct that conveys a 703 code for the language of a file, per [ISO639-2]. 705 metalinkLanguage = 706 element metalink:language { 707 metalinkTextConstruct 708 } 710 4.2.7. The "metalink:license" Element 712 The "metalink:license" element is a Text construct that conveys a 713 human-readable license name for a file. 715 metalinkLicense = 716 element metalink:license { 717 metalinkCommonAttributes, 718 attribute uri { metalinkUri }?, 719 attribute name { metalinkTextConstruct }?, 720 } 722 The metalink:license element MAY have a "uri" attribute whose value 723 MUST be an IRI reference [RFC3987]. When dereferenced, the resulting 724 URI (mapped from an IRI, if necessary) SHOULD produce a 725 representation that is relevant to that agent. 727 The metalink:license element MAY have a "name" attribute that 728 indicates the name of the license. 730 4.2.8. The "metalink:logo" Element 732 The "metalink:logo" element's content is an IRI reference [RFC3987] 733 that identifies an image that provides visual identification for a 734 file. 736 metalinkLogo = element metalink:logo { 737 metalinkCommonAttributes, 738 (metalinkUri) 739 } 741 The image SHOULD have an aspect ratio of one (horizontal) to one 742 (vertical) and SHOULD be suitable for presentation at a small size. 744 4.2.9. The "metalink:origin" Element 746 The "metalink:origin" element is an IRI where the Metalink Document 747 was originally published. If metalink:type is "dynamic", then 748 updated versions of the Metalink can be found at this IRI. 750 metalinkOrigin = element metalink:origin { 751 metalinkCommonAttributes, 752 (metalinkUri) 753 } 755 4.2.10. The "metalink:os" Element 757 The "metalink:os" element is a Text construct that conveys a human- 758 readable Operating System for a file. 760 metalinkOS = 761 element metalink:os { 762 metalinkTextConstruct 763 } 765 4.2.11. The "metalink:published" Element 767 The "metalink:published" element is a Date construct indicating an 768 instant in time associated with an event early in the life cycle of 769 the entry. 771 metalinkPublished = 772 element metalink:published { 773 metalinkDateConstruct 774 } 776 Typically, metalink:published will be associated with the initial 777 creation or first availability of the resource. 779 4.2.12. The "metalink:publisher" Element 781 The "metalink:publisher" element indicates a group or other entity 782 which has published the file. 784 metalinkPublisher = 785 element metalink:publisher { 786 metalinkCommonAttributes, 787 attribute uri { metalinkUri }?, 788 attribute name { metalinkTextConstruct }?, 789 } 791 The metalink:publisher element MAY have a "uri" attribute whose value 792 MUST be an IRI reference [RFC3987]. When dereferenced, the resulting 793 URI (mapped from an IRI, if necessary) SHOULD produce a 794 representation that is relevant to that agent. 796 The metalink:publisher element MAY have a "name" attribute that 797 indicates the name of the publisher. 799 4.2.13. The "metalink:signature" Element 801 The "metalink:signature" element is a Text construct that conveys a 802 digital signature for a file. 804 metalinkSignature = 805 element metalink:signature { 806 attribute type { "pgp" }, 807 metalinkTextConstruct 808 } 810 4.2.13.1. The "type" Attribute 812 metalink:signature elements MUST have a "type" attribute. The inital 813 value of "type" is the string that is non-empty and matches "pgp". 814 It may be useful to extend Metalink documents with new types of 815 digital signatures, so unknown types are allowed. 817 4.2.14. The "metalink:size" Element 819 The "metalink:size" element indicates the length of the linked 820 content in octets; it is a hint about the content length of the 821 representation returned when the IRI is mapped to a URI and 822 dereferenced. Note that the "metalink:size" element MUST override 823 the actual content length of the representation as reported by the 824 underlying protocol, i.e. files with different sizes should be 825 discarded. 827 metalinkSize = 828 element metalink:size { 829 metalinkTextConstruct 830 } 832 4.2.15. The "metalink:type" Element 834 The "metalink:type" element is a Text construct that describes 835 whether the IRI from "metalink:origin" a Metalink will contain 836 dynamic updated Metalinks or static content that is not updated. 838 metalinkType = 839 element metalink:type { 840 "static" | "dynamic" 841 } 843 4.2.16. The "metalink:updated" Element 845 The "metalink:updated" element is a Date construct indicating the 846 most recent instant in time when a Metalink was modified in a way the 847 publisher considers significant. Therefore, not all modifications 848 necessarily result in a changed metalink:updated value. 850 metalinkUpdated = 851 element metalink:updated { 852 metalinkDateConstruct 853 } 855 Publishers MAY change the value of this element over time. 857 4.2.17. The "metalink:url" Element 859 The "metalink:url" element contains the IRI of a file. All IRIs 860 should lead to identical files, except in the case of type 861 "bittorrent" where the IRI should lead to a .torrent file. 863 metalinkURL = 864 element metalink:url { 865 metalinkCommonAttributes, 866 attribute location { xsd:string { 867 minLength = "2" maxLength="2"} 868 }?, 869 attribute preference { xsd:integer }?, 870 attribute type { "ftp" | "ftps" | "http" | "https" | 871 "rsync" | "bittorrent" | "magnet" | "ed2k" }?, 872 metalinkUri 873 }+ 875 4.2.17.1. The "preference" Attribute 877 metalink:url elements MAY have a preference attribute, whose value 878 MUST be a number from 1 to 100 for priority, with 100 used first and 879 1 used last. Multiple metalink:url elements can have the same 880 preference, i.e. ten mirrors could have preference="100". A Metalink 881 Processor MAY download different segments of a file from more than 882 one IRI simultaneously, and when doing so SHOULD first use the 883 highest priority IRIs and then use lower ones. 885 When one or more metalink:url elements have a preference attribute 886 value of "100", other metalink:url elements SHOULD NOT be used, 887 unless these cannot be processed (e.g. are "bittorrent" etc, and this 888 is not supported by the Metalink Processor, or the servers are down). 890 Any metalink:url elements with a preference attribute value of "1" 891 SHOULD NOT be used unless all other metalink:url elements cannot be 892 processed (e.g. are "bittorrent" etc and this is not supported by the 893 Metalink Processor, or the servers are down). 895 4.2.17.2. The "type" Attribute 897 metalink:url elements MAY have a "type" attribute that indicates the 898 IRI type, except in the case of BitTorrent, where the value 899 "bittorrent" is required. The "type" attribute overrides any file 900 extension sniffing specified above. 902 Metalink Processors that do not support metalink:url elements with a 903 value of a specified type of MUST ignore that resource. 905 This document defines eight initial values for IRI types: 906 1. The value "ftp" signifies that the IRI is accessed via FTP as 907 specified in [RFC959]. 908 2. The value "ftps" signifies that the IRI is accessed via FTPS as 909 specified in [RFC4217]. 910 3. The value "http" signifies that the IRI is accessed via HTTP as 911 specified in [RFC2616]. 912 4. The value "https" signifies that the IRI is accessed via HTTPS as 913 specified in [RFC2818]. 914 5. The value "rsync" signifies that the IRI is accessed via rsync. 915 6. The value "bittorrent" signifies that the IRI (which can be 916 accessed via various URI schemes) leads to a BitTorrent .torrent 917 file as specified in [BITTORRENT]. Metalink Processors that do 918 not support BitTorrent MUST ignore this type and also ignore 919 metalink:url elements which retrieve files that end with the 920 extension ".torrent", unless the metalink:url element has a type 921 attribute which the Metalink Processor supports 922 7. The value "magnet" signifies that the IRI is accessed via Magnet 923 Link. 924 8. The value "ed2k" signifies that the IRI is accessed via ED2K 925 network. 927 4.2.17.3. The "location" Attribute 929 metalink:url elements MAY have a "location" attribute, which is a 930 [ISO3166] alpha-2 two letter country code for the geographical 931 location of the physical server an IRI is used to access. 933 4.2.18. The "metalink:version" Element 935 The "metalink:version" element is a Text construct that conveys a 936 human-readable version for a file. The version of OpenOffice.org 3.0 937 would be "3.0". 939 metalinkVersion = 940 element metalink:version { 941 metalinkTextConstruct 942 } 944 5. Securing Metalink Documents 946 Because Metalink is an XML-based format, existing XML security 947 mechanisms can be used to secure its content. 949 Producers of Metalinks may have sound reasons for signing and/or 950 encrypting otherwise-unprotected content. For example, a merchant 951 might digitally sign a Metalink that lists a file download to verify 952 its origin. Other merchants may wish to sign and encypt Metalinks 953 that list digital songs that have been purchased. Of course, many 954 other examples exist as well. 956 The algorithm requirements in this section pertain to the Metalink 957 Processor. They require that a recipient, at a minimum, be able to 958 handle messages that use the specified cryptographic algorithms. 959 These requirements do not limit the algorithms that the sender can 960 choose. 962 5.1. Digital Signatures 964 The root of a Metalink Document (i.e., metalink:metalink MAY have an 965 Enveloped Signature, as described by XML-Signature and Syntax 966 Processing [REC-xmldsig-core]. 968 Metalink Processors MUST NOT reject an Metalink Document containing 969 such a signature because they are not capable of verifying it; they 970 MUST continue processing and MAY inform the user of their failure to 971 validate the signature. 973 In other words, the presence of an element with the namespace URI 974 "http://www.w3.org/2000/09/xmldsig#" and a local name of "Signature" 975 as a child of the document element MUST NOT cause an Metalink 976 Processor to fail merely because of its presence. 978 Other elements in an Metalink Document MUST NOT be signed unless 979 their definitions explicitly specify such a capability. 981 Section 6.5.1 of [REC-xmldsig-core] requires support for Canonical 982 XML [REC-xml-c14n]. However, many implementers do not use it because 983 signed XML documents enclosed in other XML documents have their 984 signatures broken. Thus, Metalink Processors that verify signed 985 Metalink Documents MUST be able to canonicalize with the exclusive 986 XML canonicalization method identified by the URI 987 "http://www.w3.org/2001/10/xml-exc-c14n#", as specified in Exclusive 988 XML Canonicalization [REC-xml-exc-c14n]. 990 Section 4.4.2 of [REC-xmldsig-core] requires support for DSA 991 signatures and recommends support for RSA signatures. However, 992 because of the much greater popularity in the market of RSA versus 993 DSA, Metalink Processors that verify signed Metalink Documents MUST 994 be able to verify RSA signatures, but do not need be able to verify 995 DSA signatures. Due to security issues that can arise if the keying 996 material for message authentication code (MAC) authentication is not 997 handled properly, Metalink Documents SHOULD NOT use MACs for 998 signatures. 1000 5.2. Encryption 1002 The root of a Metalink Document (i.e., metalink:metalink in a 1003 Metalink Document MAY be encrypted, using the mechanisms described by 1004 XML Encryption Syntax and Processing [REC-xmlenc-core]. 1006 Section 5.1 of [REC-xmlenc-core] requires support of TripleDES, AES- 1007 128, and AES-256. Metalink Processors that decrypt Metalink 1008 Documents MUST be able to decrypt with AES-128 in Cipher Block 1009 Chaining (CBC) mode. 1011 Encryption based on [REC-xmlenc-core] does not ensure integrity of 1012 the original document. There are known cryptographic attacks where 1013 someone who cannot decrypt a message can still change bits in a way 1014 where part or all the decrypted message makes sense but has a 1015 different meaning. Thus, Metalink Processors that decrypt Metalink 1016 Documents SHOULD check the integrity of the decrypted document by 1017 verifying the hash in the signature (if any) in the document, or by 1018 verifying a hash of the document within the document (if any). 1020 5.3. Signing and Encrypting 1022 When an Metalink Document is to be both signed and encrypted, it is 1023 generally a good idea to first sign the document, then encrypt the 1024 signed document. This provides integrity to the base document while 1025 encrypting all the information, including the identity of the entity 1026 that signed the document. Note that, if MACs are used for 1027 authentication, the order MUST be that the document is signed and 1028 then encrypted, and not the other way around. 1030 6. Extending Metalink 1031 6.1. Extensions from Non-Metalink Vocabularies 1033 This specification describes Metalink's XML markup vocabulary. 1034 Markup from other vocabularies ("foreign markup") can be used in an 1035 Metalink Document. 1037 6.2. Extensions to the Metalink Vocabulary 1039 The Metalink namespace is reserved for future forward-compatible 1040 revisions of Metalink. Future versions of this specification could 1041 add new elements and attributes to the Metalink markup vocabulary. 1042 Software written to conform to this version of the specification will 1043 not be able to process such markup correctly and, in fact, will not 1044 be able to distinguish it from markup error. For the purposes of 1045 this discussion, unrecognized markup from the Metalink vocabulary 1046 will be considered "foreign markup". 1048 6.3. Processing Foreign Markup 1050 Metalink Processors that encounter foreign markup in a location that 1051 is legal according to this specification MUST NOT stop processing or 1052 signal an error. It might be the case that the Metalink Processor is 1053 able to process the foreign markup correctly and does so. Otherwise, 1054 such markup is termed "unknown foreign markup". 1056 When unknown foreign markup is encountered as a child of metalink: 1057 file, metalink:metalink, Metalink Processors MAY bypass the markup 1058 and any textual content and MUST NOT change their behavior as a 1059 result of the markup's presence. 1061 When unknown foreign markup is encountered in a Text Construct, 1062 software SHOULD ignore the markup and process any text content of 1063 foreign elements as though the surrounding markup were not present. 1065 6.4. Extension Elements 1067 Metalink allows foreign markup anywhere in an Metalink document, 1068 except where it is explicitly forbidden. Child elements of metalink: 1069 file and metalink:metalink are considered Metadata elements and are 1070 described below. Child elements of Person constructs are considered 1071 to apply to the construct. The role of other foreign markup is 1072 undefined by this specification. 1074 6.4.1. Simple Extension Elements 1076 A Simple Extension element MUST NOT have any attributes or child 1077 elements. The element MAY contain character data or be empty. 1078 Simple Extension elements are not Language-Sensitive. 1080 simpleExtensionElement = 1081 element * - metalink:* { 1082 text 1083 } 1085 The element can be interpreted as a simple property (or name/value 1086 pair) of the parent element that encloses it. The pair consisting of 1087 the namespace-URI of the element and the local name of the element 1088 can be interpreted as the name of the property. The character data 1089 content of the element can be interpreted as the value of the 1090 property. If the element is empty, then the property value can be 1091 interpreted as an empty string. 1093 6.4.2. Structured Extension Elements 1095 The root element of a Structured Extension element MUST have at least 1096 one attribute or child element. It MAY have attributes, it MAY 1097 contain well-formed XML content (including character data), or it MAY 1098 be empty. Structured Extension elements are Language-Sensitive. 1100 structuredExtensionElement = 1101 element * - metalink:* { 1102 (attribute * { text }+, 1103 (text|anyElement)*) 1104 | (attribute * { text }*, 1105 (text?, anyElement+, (text|anyElement)*)) 1106 } 1108 The structure of a Structured Extension element, including the order 1109 of its child elements, could be significant. 1111 This specification does not provide an interpretation of a Structured 1112 Extension element. The syntax of the XML contained in the element 1113 (and an interpretation of how the element relates to its containing 1114 element) is defined by the specification of the Metalink extension. 1116 7. IANA Considerations 1118 A Metalink Document, when serialized as XML 1.0, can be identified 1119 with the following media type: 1121 MIME media type name: application 1122 MIME subtype name: metalink+xml 1123 Mandatory parameters: None. 1124 Optional parameters: 1125 "charset": This parameter has semantics identical to the charset 1126 parameter of the "application/xml" media type as specified in 1127 [RFC3023]. 1128 Encoding considerations: Identical to those of "application/xml" as 1129 described in [RFC3023], Section 3.2. 1130 Security considerations: As defined in this specification. 1131 In addition, as this media type uses the "+xml" convention, it 1132 shares the same security considerations as described in [RFC3023], 1133 Section 10. 1134 Interoperability considerations: There are no known interoperability 1135 issues. 1136 Published specification: This specification. 1137 Applications that use this media type: No known applications 1138 currently use this media type. 1140 Additional information: 1142 Magic number(s): As specified for "application/xml" in [RFC3023], 1143 Section 3.2. 1144 File extension: .metalink 1145 Fragment identifiers: As specified for "application/xml" in 1146 [RFC3023], Section 5. 1147 Base URI: As specified in [RFC3023], Section 6. 1148 Macintosh File Type code: TEXT 1149 Person and email address to contact for further information: Anthony 1150 Bryan 1151 Intended usage: COMMON 1152 Author/Change controller: IESG 1154 8. Security Considerations 1156 Publishers are encouraged to offer Metalink documents via 1157 authenticated HTTP under TLS. Publishers are also encouraged to 1158 include digital signatures of the files within the Metalink Documents 1159 if they are available. 1161 8.1. URIs 1163 Metalink Processors handle URIs. See Section 7 of [RFC3986]. 1165 8.2. IRIs 1167 Metalink Processors handle IRIs. See Section 8 of [RFC3987]. 1169 8.3. Spoofing 1171 Metalink Processors should be aware of the potential for spoofing 1172 attacks where the attacker publishes Metalinks with false 1173 information. Malicious publishers might create Metalink Documents 1174 containing inaccurate information anywhere in the document. At best, 1175 this could deceive unaware downloaders that they are downloading a 1176 malicious or worthless file. At worst, malicious publishers could 1177 attempt a distributed denial of service attack by inserting unrelated 1178 IRIs into Metalink Documents. 1180 8.4. Encryption and Signing 1182 Metalink Documents can be encrypted and signed using 1183 [REC-xmlenc-core] and [REC-xmldsig-core], respectively, and are 1184 subject to the security considerations implied by their use. 1186 Digital signatures provide authentication, message integrity, and 1187 non-repudiation with proof of origin. Encryption provides data 1188 confidentiality. 1190 9. References 1192 9.1. Normative References 1194 [BITTORRENT] 1195 Cohen, B., "The BitTorrent Protocol Specification", 1196 BITTORRENT 11031, February 2008, 1197 . 1199 [ISO3166] International Organization for Standardization, "ISO 3166: 1200 1988 (E/F) - Codes for the representation of names of 1201 countries - The International Organization for 1202 Standardization, 3rd edition, 1988-08-15.", ISO Standard 1203 3166, 1988. 1205 [ISO639-2] 1206 International Organization for Standardization, "ISO 639- 1207 2:1998 - Codes for the representation of names of 1208 languages -- Part 2: Alpha-3 code - edition 1, 1209 1998-11-01, 66 pages, prepared by a Joint Working Group of 1210 ISO TC46/SC4 and ISO TC37/SC2.", ISO Standard 639-2, 1998. 1212 [REC-xml] Yergeau, F., Paoli, J., Bray, T., Sperberg-McQueen, C., 1213 and E. Maler, "Extensible Markup Language (XML) 1.0 1214 (Fourth Edition)", World Wide Web Consortium 1215 Recommendation REC-xml-20060816, August 2006, 1216 . 1218 [REC-xml-c14n] 1219 Boyer, J., "Canonical XML Version 1.0", W3C REC REC-xml- 1220 c14n-20010315, March 2001, 1221 . 1223 [REC-xml-exc-c14n] 1224 Eastlake, D., Boyer, J., and J. Reagle, "Exclusive XML 1225 Canonicalization Version 1.0", W3C REC REC-xml-exc-c14n- 1226 20020718, July 2002, 1227 . 1229 [REC-xml-infoset] 1230 Cowan, J. and R. Tobin, "XML Information Set (Second 1231 Edition)", World Wide Web Consortium Recommendation REC- 1232 xml-infoset-20040204, February 2004, 1233 . 1235 [REC-xml-names] 1236 Hollander, D., Bray, T., Tobin, R., and A. Layman, 1237 "Namespaces in XML 1.0 (Second Edition)", World Wide Web 1238 Consortium Recommendation REC-xml-names-20060816, 1239 August 2006, 1240 . 1242 [REC-xmlbase] 1243 Marsh, J., "XML Base", W3C REC W3C.REC-xmlbase-20010627, 1244 June 2001, 1245 . 1247 [REC-xmldsig-core] 1248 Solo, D., Reagle, J., and D. Eastlake, "XML-Signature 1249 Syntax and Processing", World Wide Web Consortium 1250 Recommendation REC-xmldsig-core-20020212, February 2002, 1251 . 1253 [REC-xmlenc-core] 1254 Eastlake, D. and J. Reagle, "XML Encryption Syntax and 1255 Processing", World Wide Web Consortium Recommendation REC- 1256 xmlenc-core-20021210, December 2002, 1257 . 1259 [RFC1320] Rivest, R., "The MD4 Message-Digest Algorithm", RFC 1320, 1260 April 1992. 1262 [RFC1321] Rivest, R., "The MD5 Message-Digest Algorithm", RFC 1321, 1263 April 1992. 1265 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 1266 Requirement Levels", BCP 14, RFC 2119, March 1997. 1268 [RFC2616] Fielding, R., Gettys, J., Mogul, J., Frystyk, H., 1269 Masinter, L., Leach, P., and T. Berners-Lee, "Hypertext 1270 Transfer Protocol -- HTTP/1.1", RFC 2616, June 1999. 1272 [RFC2818] Rescorla, E., "HTTP Over TLS", RFC 2818, May 2000. 1274 [RFC3023] Murata, M., St. Laurent, S., and D. Kohn, "XML Media 1275 Types", RFC 3023, January 2001. 1277 [RFC3174] Eastlake, D. and P. Jones, "US Secure Hash Algorithm 1 1278 (SHA1)", RFC 3174, September 2001. 1280 [RFC3339] Klyne, G. and C. Newman, "Date and Time on the Internet: 1281 Timestamps", RFC 3339, July 2002. 1283 [RFC3986] Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform 1284 Resource Identifier (URI): Generic Syntax", STD 66, 1285 RFC 3986, January 2005. 1287 [RFC3987] Duerst, M. and M. Suignard, "Internationalized Resource 1288 Identifiers (IRIs)", RFC 3987, January 2005. 1290 [RFC4217] Ford-Hutchinson, P., "Securing FTP with TLS", RFC 4217, 1291 October 2005. 1293 [RFC4634] Eastlake, D. and P. Jones, "US Secure Hash Algorithms (SHA 1294 and HMAC-SHA)", RFC 4634, July 2006. 1296 [RFC959] Postel, J. and J. Reynolds, "FILE TRANSFER PROTOCOL 1297 (FTP)", RFC 959, October 1985. 1299 [RIPE] Dobbertin, H., Bosselaers, A., and B. Preneel, "RIPEMD- 1300 160: A Strengthened Version of RIPEMD", RIPE RIPE, 1301 April 1996. 1303 9.2. Informative References 1305 [ISO.8601.1988] 1306 International Organization for Standardization, "Data 1307 elements and interchange formats - Information interchange 1308 - Representation of dates and times", ISO Standard 8601, 1309 June 1988. 1311 [RELAX-NG] 1312 Clark, J., "RELAX NG Compact Syntax", December 2001, . 1316 [RFC4287] Nottingham, M. and R. Sayre, "The Atom Syndication 1317 Format", RFC 4287, December 2005. 1319 [W3C.NOTE-datetime-19980827] 1320 Wolf, M. and C. Wicksteed, "Date and Time Formats", W3C 1321 NOTE NOTE-datetime-19980827, August 1998, 1322 . 1324 [W3C.REC-xmlschema-2-20041028] 1325 Malhotra, A. and P. Biron, "XML Schema Part 2: Datatypes 1326 Second Edition", W3C REC REC-xmlschema-2-20041028, 1327 October 2004, 1328 . 1330 Appendix A. Contributors 1332 The layout and content of this document relies heavily on work 1333 pioneered in the Atom Syndication Format as specified in [RFC4287]. 1335 The following people contributed to preliminary versions of this 1336 document: Paul Burkhead, Kristian Weston, Darius Liktorius, Michael 1337 Burford, Giorgio Maone, Manuel Subredu, Tatsuhiro Tsujikawa, A. Bram 1338 Neijt, Max Velasques, Manolo Valdes, Urs Wolfer, Frederick Cheung, 1339 Nils Maier, Hampus Wessman, Neil McNab, Hayden Legendre, Danny Ayers, 1340 Nick Dominguez, Rene Leonhardt, Per Oyvind Karlsen, Gary Zellerbach, 1341 James Clark, Tim Bray, Dan Brickley, Daniel Stenberg, Peter Poeml, 1342 Matt Domsch, and Ian Macfarlane. The content and concepts within are 1343 a product of the Metalink community. 1345 The Metalink community has dozens of very active contributors who 1346 proposed ideas and wording for this document, including: 1348 Nicolas Alvarez, Patrick Ruckstuhl, Mike Wells, Sebastien Willemijns, 1349 Micah Cowan, Dan Fandrich, Francis Giannaros, Yazsoft, Lukas 1350 Appelhans, KGet developers, FDM Team, Orbit Team, Arne 1351 Babenhauserheide, Mathias Berchtold, Xienzhenyu and TheWorld Browser 1352 Team, Xi Software, Bridget and Ethan Fletcher, Ruben Kerkhof, 1353 Agostino Russo, Gervase Markham, Salvatore and Robin Musumeci, Steve 1354 and Rachel Eshelman, Lucas and Rachel Hewett, Ryan and Darren Cronin, 1355 Dave Winquist, Bob Denison, Wes Shelton, Kees Cook, Josh Colbert, 1356 Steve Kleisath, Chad Neptune, Nick Carrabba, Chris Carrabba, Erin 1357 Solari, Derick Cordoba, Ryan Alexander, John Sowder, Sandra Amisano, 1358 Tom Mainville, Janie Wargo, Jason Hansen, Markus Hofmann, Dan 1359 Connolly, Tim Berners-Lee, Harry Chen, Adrien Macneil, Louis Suarez- 1360 Potts, Ross Smith, Rahul Sundaram, Jesse Keating, Michal Bentkowski, 1361 Andrew Pantyukhin, Judd Vinet, Charles Landemaine, Pascal Bleser, 1362 Jeff@BLAG, Yuichiro Nakada, Jereme Hancock, Marcel Hauser, Jeff 1363 Covey, Doug Lang, Seth Brown, Alexander Lazic, Mayank Sharma, Robin 1364 Heggelund Hansen, Steve Langasek, Federico Parodi, Stefano Verna, 1365 Jason Green, James Linden, Matt Nederlanden, Aren Olsen, Dag 1366 Odenhall, Troy Sobotka, Corey Farwell, Ed Lee, Shawn Wilsher, Mike 1367 Connor, Anand Muttagi, Debi Goulding, the Anthony Family, the Bryan 1368 Family, Juanita Anthony and Zimmy Bryan. 1370 Appendix B. RELAX NG Compact Schema 1372 This appendix is informative. 1374 The Relax NG schema explicitly excludes elements in the Metalink 1375 namespace that are not defined in this revision of the specification. 1376 Requirements for Metalink Processors encountering such markup are 1377 given in Sections 6.2 and 6.3. 1379 # -*- rnc -*- 1380 # RELAX NG Compact Syntax Grammar for the 1381 # Metalink Format Specification Version 1 1383 namespace metalink = "http://www.metalinker.org" 1384 namespace xsd = "http://www.w3.org/2001/XMLSchema" 1386 # Common attributes 1388 metalinkCommonAttributes = 1389 attribute xml:base { metalinkUri }?, 1390 attribute xml:lang { metalinkLanguageTag }?, 1391 undefinedAttribute* 1393 # Text Constructs 1395 metalinkTextConstruct = 1396 metalinkCommonAttributes, 1397 text 1399 # Date Construct 1401 metalinkDateConstruct = 1402 metalinkCommonAttributes, 1403 xsd:dateTime 1405 start = 1406 element metalink { 1407 attribute version { "3.0" }, 1408 element generator { 1409 attribute uri { metalinkUri }?, 1410 attribute version { text }?, 1411 metalinkTextConstruct 1412 } 1413 element origin { metalinkUri }?, 1414 element type { "static" | "dynamic" }?, 1415 element published { metalinkDateConstruct }?, 1416 element updated { metalinkDateConstruct }?, 1417 element files { 1418 element file { 1419 attribute name { metalinkTextConstruct }, 1420 element identity { metalinkTextConstruct }?, 1421 element version { metalinkTextConstruct }?, 1422 element size { xsd:integer }?, 1423 element description { metalinkTextConstruct }?, 1424 element license { 1425 attribute uri { metalinkUri }?, 1426 attribute name { metalinkTextConstruct }?, 1427 }?, 1428 element logo { metalinkUri }?, 1429 element publisher { 1430 attribute uri { metalinkUri }?, 1431 attribute name { metalinkTextConstruct }?, 1432 }?, 1433 element language { metalinkTextConstruct }?, 1434 element copyright { metalinkTextConstruct }?, 1435 element license { metalinkTextConstruct }?, 1436 element os { metalinkTextConstruct }?, 1437 element verification { 1438 hash+, 1439 element pieces { 1440 attribute length { metalinkTextConstruct }, 1441 attribute type { "crc32" | "md4" | "md5" | "sha1" | 1442 "sha256" | "sha384" | "sha512" | "rmd160" | "tiger" }, 1443 hash+ 1444 }+, 1445 element signature { 1446 attribute type { "pgp" }, 1447 text 1448 } 1449 }?, 1450 element resources { 1451 element url { 1452 attribute location { xsd:string { 1453 minLength = "2" maxLength="2"} 1454 }?, 1455 attribute preference { xsd:integer }?, 1456 attribute type { "ftp" | "ftps" | "http" | "https" | 1457 "rsync" | "bittorrent" | "magnet" | "ed2k" }?, 1458 metalinkUri 1459 }+ 1460 } 1461 }+ 1462 } 1463 } 1464 hash = 1465 element hash { 1466 attribute piece { metalinkTextConstruct }?, 1467 attribute type { "crc32" | "md4" | "md5" | "sha1" | 1468 "sha256" | "sha384" | "sha512" | "rmd160" | "tiger" }, 1469 text 1470 } 1472 # As defined in RFC 3066 1473 metalinkLanguageTag = xsd:string { 1474 pattern = "[A-Za-z]{1,8}(-[A-Za-z0-9]{1,8})*" 1475 } 1477 # Unconstrained; it's not entirely clear how IRI fit into 1478 # xsd:anyURI so let's not try to constrain it here 1479 metalinkUri = text 1481 # Simple Extension 1483 simpleExtensionElement = 1484 element * - metalink:* { 1485 text 1486 } 1488 # Structured Extension 1490 structuredExtensionElement = 1491 element * - metalink:* { 1492 (attribute * { text }+, 1493 (text|anyElement)*) 1494 | (attribute * { text }*, 1495 (text?, anyElement+, (text|anyElement)*)) 1496 } 1498 # Other Extensibility 1500 extensionElement = 1501 simpleExtensionElement | structuredExtensionElement 1503 undefinedAttribute = 1504 attribute * - (xml:base | xml:lang | local:*) { text } 1506 undefinedContent = (text|anyForeignElement)* 1508 anyElement = 1509 element * { 1510 (attribute * { text } 1511 | text 1512 | anyElement)* 1513 } 1515 anyForeignElement = 1516 element * - metalink:* { 1517 (attribute * { text } 1518 | text 1519 | anyElement)* 1520 } 1522 # EOF 1524 Index 1526 A 1527 application/metalink+xml Media Type 25 1529 C 1530 copyright XML element 14 1532 D 1533 description XML element 14 1535 F 1536 file XML element 11 1537 files XML element 10 1539 G 1540 generator XML element 15 1541 Grammar 1542 metalinkCommonAttributes 7 1543 metalinkCopyright 14 1544 metalinkDateConstruct 8 1545 metalinkDescription 15 1546 metalinkFile 11 1547 metalinkFiles 10 1548 metalinkGenerator 15 1549 metalinkHash 15 1550 metalinkIdentity 16 1551 metalinkLanguage 17 1552 metalinkLicense 17 1553 metalinkLogo 17 1554 metalinkMetalink 9 1555 metalinkOrigin 18 1556 metalinkOS 18 1557 metalinkPieces 13 1558 metalinkPublished 18 1559 metalinkPublisher 18 1560 metalinkResources 12 1561 metalinkSignature 19 1562 metalinkSize 19 1563 metalinkTextConstruct 7 1564 metalinkType 19 1565 metalinkUpdated 20 1566 metalinkURL 20 1567 metalinkVerification 13 1568 metalinkVersion 22 1569 simpleExtensionElement 25 1570 structuredExtensionElement 25 1572 H 1573 hash XML element 15 1575 I 1576 identity XML element 16 1578 L 1579 language XML element 17 1580 license XML element 17 1581 logo XML element 17 1583 M 1584 Media Type 1585 application/metalink+xml 25 1586 metalink XML element 9 1587 metalinkCommonAttributes grammar production 7 1588 metalinkCopyright grammar production 14 1589 metalinkDateConstruct grammar production 8 1590 metalinkDescription grammar production 15 1591 metalinkFile grammar production 11 1592 metalinkFiles grammar production 10 1593 metalinkGenerator grammar production 15 1594 metalinkHash grammar production 15 1595 metalinkIdentity grammar production 16 1596 metalinkLanguage grammar production 17 1597 metalinkLicense grammar production 17 1598 metalinkLogo grammar production 17 1599 metalinkMetalink grammar production 9 1600 metalinkOrigin grammar production 18 1601 metalinkOS grammar production 18 1602 metalinkPieces grammar production 13 1603 metalinkPublished grammar production 18 1604 metalinkPublisher grammar production 18 1605 metalinkResources grammar production 12 1606 metalinkSignature grammar production 19 1607 metalinkSize grammar production 19 1608 metalinkTextConstruct grammar production 7 1609 metalinkType grammar production 19 1610 metalinkUpdated grammar production 20 1611 metalinkURL grammar production 20 1612 metalinkVerification grammar production 13 1613 metalinkVersion grammar production 22 1615 O 1616 origin XML element 17 1617 os XML element 18 1619 P 1620 pieces XML element 13 1621 published XML element 18 1622 publisher XML element 18 1624 R 1625 resources XML element 12 1627 S 1628 signature XML element 19 1629 simpleExtensionElement grammar production 25 1630 size XML element 19 1631 structuredExtensionElement grammar production 25 1633 T 1634 type XML element 19 1636 U 1637 updated XML element 20 1638 url XML element 20 1640 V 1641 verification XML element 13 1642 version XML element 21 1644 X 1645 XML Elements 1646 copyright 14 1647 description 14 1648 entry 11 1649 files 10 1650 generator 15 1651 hash 15 1652 identity 16 1653 language 17 1654 license 17 1655 logo 17 1656 metalink 9 1657 origin 17 1658 os 18 1659 pieces 13 1660 published 18 1661 publisher 18 1662 resources 12 1663 signature 19 1664 size 19 1665 type 19 1666 updated 20 1667 url 20 1668 verification 13 1669 version 21 1671 Author's Address 1673 Anthony Bryan (editor) 1674 Metalinker Project 1676 Email: anthonybryan@gmail.com 1677 URI: http://www.metalinker.org 1679 Full Copyright Statement 1681 Copyright (C) The IETF Trust (2008). 1683 This document is subject to the rights, licenses and restrictions 1684 contained in BCP 78, and except as set forth therein, the authors 1685 retain all their rights. 1687 This document and the information contained herein are provided on an 1688 "AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS 1689 OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY, THE IETF TRUST AND 1690 THE INTERNET ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS 1691 OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF 1692 THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED 1693 WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 1695 Intellectual Property 1697 The IETF takes no position regarding the validity or scope of any 1698 Intellectual Property Rights or other rights that might be claimed to 1699 pertain to the implementation or use of the technology described in 1700 this document or the extent to which any license under such rights 1701 might or might not be available; nor does it represent that it has 1702 made any independent effort to identify any such rights. Information 1703 on the procedures with respect to rights in RFC documents can be 1704 found in BCP 78 and BCP 79. 1706 Copies of IPR disclosures made to the IETF Secretariat and any 1707 assurances of licenses to be made available, or the result of an 1708 attempt made to obtain a general license or permission for the use of 1709 such proprietary rights by implementers or users of this 1710 specification can be obtained from the IETF on-line IPR repository at 1711 http://www.ietf.org/ipr. 1713 The IETF invites any interested party to bring to its attention any 1714 copyrights, patents or patent applications, or other proprietary 1715 rights that may cover technology that may be required to implement 1716 this standard. Please address the information to the IETF at 1717 ietf-ipr@ietf.org.