Network Working Group                                           J. Snell
Internet-Draft                                          January 24, 2006
Expires: July 28, 2006


                Atom Syndication Format Link Extensions
               draft-snell-atompub-link-extensions-02.txt

Status of this Memo

   By submitting this Internet-Draft, each author represents that any
   applicable patent or other IPR claims of which he or she is aware
   have been or will be disclosed, and any of which he or she becomes
   aware will be disclosed, in accordance with Section 6 of BCP 79.

   Internet-Drafts are working documents of the Internet Engineering
   Task Force (IETF), its areas, and its working groups.  Note that
   other groups may also distribute working documents as Internet-
   Drafts.

   Internet-Drafts are draft documents valid for a maximum of six months
   and may be updated, replaced, or obsoleted by other documents at any
   time.  It is inappropriate to use Internet-Drafts as reference
   material or to cite them other than as "work in progress."

   The list of current Internet-Drafts can be accessed at
   http://www.ietf.org/ietf/1id-abstracts.txt.

   The list of Internet-Draft Shadow Directories can be accessed at
   http://www.ietf.org/shadow.html.

   This Internet-Draft will expire on July 28, 2006.

Copyright Notice

   Copyright (C) The Internet Society (2006).

Abstract

   This specification defines extensions to the Atom Syndication Format
   link and content elements that may be used to express additional
   metadata about linked resources.









Snell                     Expires July 28, 2006                 [Page 1]


Internet-Draft            Atom Link Extensions              January 2006


Table of Contents

   1.  Introduction . . . . . . . . . . . . . . . . . . . . . . . . .  3
   2.  Notational Conventions . . . . . . . . . . . . . . . . . . . .  3
   3.  Entity Attributes  . . . . . . . . . . . . . . . . . . . . . .  3
     3.1.  The 'md5' Attribute  . . . . . . . . . . . . . . . . . . .  3
     3.2.  The 'etag' Attribute . . . . . . . . . . . . . . . . . . .  4
     3.3.  The 'last-modified' Attribute  . . . . . . . . . . . . . .  4
     3.4.  The 'range' Attribute  . . . . . . . . . . . . . . . . . .  5
   4.  Media Descriptors  . . . . . . . . . . . . . . . . . . . . . .  6
     4.1.  The 'media' Attribute  . . . . . . . . . . . . . . . . . .  6
   5.  Link Grouping and Alternates . . . . . . . . . . . . . . . . .  7
     5.1.  The 'group' Attribute  . . . . . . . . . . . . . . . . . .  8
     5.2.  The 'alternate' Element  . . . . . . . . . . . . . . . . .  8
   6.  Indexing and Automated Downloads . . . . . . . . . . . . . . .  9
     6.1.  The 'le:follow' attribute  . . . . . . . . . . . . . . . .  9
     6.2.  The 'le:index' attribute . . . . . . . . . . . . . . . . . 10
     6.3.  The 'le:archive' attribute . . . . . . . . . . . . . . . . 10
   7.  Security Considerations  . . . . . . . . . . . . . . . . . . . 11
   8.  IANA Considerations  . . . . . . . . . . . . . . . . . . . . . 11
   9.  Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . 11
   10. References . . . . . . . . . . . . . . . . . . . . . . . . . . 11
   Author's Address . . . . . . . . . . . . . . . . . . . . . . . . . 13
   Intellectual Property and Copyright Statements . . . . . . . . . . 14



























Snell                     Expires July 28, 2006                 [Page 2]


Internet-Draft            Atom Link Extensions              January 2006


1.  Introduction

   This specification defines extensions to the Atom Syndication Format
   [RFC4287] link and content elements that may be used to express
   additional metadata about linked resources.


2.  Notational Conventions

   The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
   "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
   document are to be interpreted as described in BCP 14, [RFC2119]

   This specification uses XML Namespaces [W3C.REC-xml-names-19990114]
   to uniquely identify XML element names.  It uses the following
   namespace prefix for the indicated namespace URI;

   {Ed.  Note: this namespace MUST be changed to a proper IETF namespace
   scheme prior to publication}

    "le": "http://purl.org/atompub/link-extensions/1.0"


3.  Entity Attributes

   The following link Entity Attributes may be used to specify metadata
   about the resource referenced by an atom:link element or atom:content
   element using the 'src' attribute.  The attributes are designed to
   closely correlate with existing HTTP [RFC2616] mechanisms used to
   perform conditional operations, detecting resource modifications and
   requesting ranges.

3.1.  The 'md5' Attribute

   The 'md5' Attribute specifies a Base64-encoded MD5 digest [RFC1864]
   of the resource identified by the atom:link/@href or atom:content/@
   src attributes.  The value of the digest is calculated as specified
   in [RFC2616] and [RFC1864].  The 'md5' attribute MAY appear as a
   child of the atom:link and atom:content (using the 'src' attribute)
   elements.

     md5 = attribute le:md5 { md5-digest }

     md5-digest   = <base64 of 128 bit MD5 digest as per RFC 1864>

   While MD5 digests are not a guarantee against malicious modifications
   of a resource, the digest specified may be used as a simple integrity
   check to verify whether or not the referenced resource may have been



Snell                     Expires July 28, 2006                 [Page 3]


Internet-Draft            Atom Link Extensions              January 2006


   modified.

   An example MD5 digest of an enclosed MP3 file

     <atom:link rel="enclosure"
       href="http://example.org/media/myfile.mp3"
       le:md5="Q2hlY2sgSW50ZWdyaXR5IQ==" />

3.2.  The 'etag' Attribute

   The 'etag' Attribute specifies an Entity Tag [RFC2616] for the
   resource identified by the atom:link or atom:content element.  The
   'etag' attribute MAY appear as a child of the atom:link and atom:
   content (using the 'src' attribute) elements.

     etag = attribute le:etag { entity-tag }

     entity-tag = [ weak ] opaque-tag
     weak       = "W/"
     opaque-tag = quoted-string

   As specified by [RFC2616], Entity Tags are usable for the purpose of
   comparing multiple entities served from the same resource URI and are
   typically used in the context of conditional-retrievals of resource
   representations.

   An example Entity Tag for an enclosed MP3 file

     <atom:link rel="enclosure"
       href="http://example.org/media/myfile.mp3"
       le:etag="W/xyzzy" />

3.3.  The 'last-modified' Attribute

   The 'last-modified' Attribute specifies the date and time when the
   resource identified by the atom:link or atom:content element was last
   modified as specified by [RFC2616].  The value of the attribute must
   conform to the HTTP-date construct from [RFC2616].  The 'last-
   modified' attribute MAY appear as a child of the atom:link and atom:
   content (using the 'src' attribute) elements.











Snell                     Expires July 28, 2006                 [Page 4]


Internet-Draft            Atom Link Extensions              January 2006


     last-modified = attribute le:last-modified { HTTP-date }

     HTTP-date    = rfc1123-date | rfc850-date | asctime-date
     rfc1123-date = wkday "," SP date1 SP time SP "GMT"
     rfc850-date  = weekday "," SP date2 SP time SP "GMT"
     asctime-date = wkday SP date3 SP time SP 4DIGIT
     date1        = 2DIGIT SP month SP 4DIGIT
                    ; day month year (e.g., 02 Jun 1982)
     date2        = 2DIGIT "-" month "-" 2DIGIT
                    ; day-month-year (e.g., 02-Jun-82)
     date3        = month SP ( 2DIGIT | ( SP 1DIGIT ))
                    ; month day (e.g., Jun  2)
     time         = 2DIGIT ":" 2DIGIT ":" 2DIGIT
                    ; 00:00:00 - 23:59:59
     wkday        = "Mon" | "Tue" | "Wed"
                  | "Thu" | "Fri" | "Sat" | "Sun"
     weekday      = "Monday" | "Tuesday" | "Wednesday"
                  | "Thursday" | "Friday" | "Saturday" | "Sunday"
     month        = "Jan" | "Feb" | "Mar" | "Apr"
                  | "May" | "Jun" | "Jul" | "Aug"
                  | "Sep" | "Oct" | "Nov" | "Dec"

   An example last-modified attribute for an enclosed MP3 file

     <atom:link rel="enclosure"
       href="http://example.org/media/myfile.mp3"
       le:last-modified="Tue, 29 Nov 2005 20:37:00 PST" />

3.4.  The 'range' Attribute

   The 'range' Attribute specifies a subset of the resource identified
   by the atom:link or atom:content element as specified by the standard
   HTTP Range header defined by [RFC2616].  The 'range' attribute MAY
   appear as a child of the atom:link and atom:content (using the 'src'
   attribute) elements.

     range = attribute le:range { ranges-specifier }

     ranges-specifier = byte-ranges-specifier
     byte-ranges-specifier = bytes-unit "=" byte-range-set
     byte-range-set  = 1#( byte-range-spec | suffix-byte-range-spec )
     byte-range-spec = first-byte-pos "-" [last-byte-pos]
     first-byte-pos  = 1*DIGIT
     last-byte-pos   = 1*DIGIT

   The only Range Specifier defined by [RFC2616] is the "bytes" range
   specifier used to request a specific sequence of bytes from a
   resource.  Other range specifiers MAY be used.  Unknown range



Snell                     Expires July 28, 2006                 [Page 5]


Internet-Draft            Atom Link Extensions              January 2006


   specifiers SHOULD be ignored.

   An example range attribute specifying the first 500 bytes of an
   enclosed MP3 file

     <atom:link rel="enclosure"
       href="http://example.org/media/myfile.mp3"
       le:range="bytes 0-499" />


4.  Media Descriptors

   Resources referenced by atom:link and atom:content elements may be
   optimized for rendering on specific types of devices.

4.1.  The 'media' Attribute

   The 'media' attribute MAY be used to identify the types of devices
   for which a resource referenced by an atom:link or atom:content
   (using the src attribute) has been targeted.  The definition of the
   media attribute is the same as the 'media' attribute on HTML
   [W3C.REC-html401-19991224] and XHTML [W3C.REC-xhtml1-20020801] link
   elements.  The 'media' attribute MAY appear as a child of the atom:
   link and atom:content elements.

     media = attribute le:media { media-descriptors }

   The value of the 'media' attribute is a comma separated list of
   media-descriptor tokens.  If not specified, the value of attribute is
   assumed to be "all".  The following lists the standard media-
   descriptor definitions as specified by [W3C.REC-html401-19991224].




















Snell                     Expires July 28, 2006                 [Page 6]


Internet-Draft            Atom Link Extensions              January 2006


     screen
         intended for non-paged computer screens

     tty
         intended for media using a fixed-pitch character
         grid, such as teletypes, terminals, or portable
         devices with limited display capabilities.

     tv
         intended for television-type devices (low-resolution,
         color, limited scrollability).

     projection
         intended for projectors

     handheld
         intended for handheld devices (small screen,
         monochrome, bitmapped graphics, limited bandwidth).

     print
         intended for paged, opaque material and for documents
         viewed on screen in print preview mode

     braille
         intended for braille tactile feedback devices.

     aural
         intended for speech synthesizers

     all
         suitable for all devices

   Two alternate atom:link elements respectively targeted at screen and
   handheld devices

     <atom:link rel="alternate"
       href="http://example.org/a.html"
       le:media="screen" />
     <atom:link rel="alternate"
       href="http://example.org/b.html"
       le:media="handheld" />


5.  Link Grouping and Alternates

   The Link Grouping and Alternate mechanisms defined below make it
   possible to group related atom:link elements into logical sets or to
   identify alternate IRI's (e.g. mirrors) for linked resources.



Snell                     Expires July 28, 2006                 [Page 7]


Internet-Draft            Atom Link Extensions              January 2006


5.1.  The 'group' Attribute

   The 'group' Attribute MAY appear as a child of atom:link elements and
   MAY be used to group associated links together into a logical set of
   mutually-exclusive options.  The value of the attribute is a case-
   insensitive, opaque text string.  Link elements with 'group'
   attributes specifying the same value are considered to belong to the
   same logical set.

     group = attribute le:group { text }

   The following illustrates an example of how the 'group' attribute may
   be used to identify alternate encodings of the same enclosed audio
   content.

     <atom:link rel="enclosure"
       href="http://example.org/media/myfile.mp3"
       le:group="mypodcast" />
     <atom:link rel="enclosure"
       href="http://example.org/media/myfile.wma"
       le:group="mypodcast" />

   Comparison operations on the 'group' attribute are performed using a
   case-insensitive character-by-character examination.  Entity
   encodings MUST be interpreted as the character they represent.  For
   instance, The value "&#103;&#114;&#111;&#117;&#112;" is equivalent to
   "group", "Group", "GROUP", etc.

5.2.  The 'alternate' Element

   The 'alternate' Element is used to specify one or more alternative
   IRI's for the resource identified by an atom:link element.  For
   instance, an enclosure referenced by a link may be downloadable from
   multiple mirror locations.  The 'alternate' Element consists of an
   IRI, an optional language-sensitive text label, and an optional
   'group' attribute used to group associated alternates together into
   logical sets.  Zero or more 'alternate' elements MAY appear as
   children of the atom:link element.  The parent link element's 'type',
   'length' and 'hreflang' attributes are considered to apply equally to
   each of the contained 'alternate' elements.

     alternate = element le:alternate {
      atomCommonAttributes,
      attribute href { atomURI },
      attribute title { text }?,
      attribute group { text }?
      (undefinedContent)
     }



Snell                     Expires July 28, 2006                 [Page 8]


Internet-Draft            Atom Link Extensions              January 2006


   An example atom:link that specifies two alternate download locations
   for the enclosed MP3 file

     <atom:link rel="enclosure"
       type="audio/mpeg"
       href="http://example.org/media/myfile.mp3">
       <le:alternate title="Mirror 1"
         group="Asia"
         href="http://jp.example.org/media/myfile.mp3" />
       <le:alternate title="Mirror 2"
         group="Asia"
         href="http://cn.example.org/media/myfile.mp3" />
       <le:alternate title="Mirror 3"
         group="Europe"
         href="http://de.example.org/media/myfile.mp3" />
       <le:alternate title="Mirror 4"
         group="Europe"
         href="http://fr.example.org/media/myfile.mp3" />
     </atom:link>


6.  Indexing and Automated Downloads

6.1.  The 'le:follow' attribute

   The 'le:follow" attribute indicates whether applications should
   automatically attempt to follow links and referenced content (e.g.,
   whether or not enclosure links should be automatically downloaded,
   etc).  The value of the attribute is either "yes" or "no".  A value
   of "no" indicates that applications SHOULD NOT attempt to
   automatically dereference the linked resource -- rather, the
   application should wait until a user explicitly requests the linked
   resource to be resolved.

   For example,
     <entry xmlns="http://www.w3.org/2005/Atom"
            xmlns:le="http://purl.org/atompub/link-extensions/1.0">
       <id>...</id>
       <title>...</title>
       <link rel="enclosure"
             href="http://example.com/mediafiles/mysong.mp3"
             le:follow="no" />
       ...
     </entry>

   The 'le:follow' attribute MAY be contained by atom:link elements and
   atom:content elements that contain a 'src' attribute.




Snell                     Expires July 28, 2006                 [Page 9]


Internet-Draft            Atom Link Extensions              January 2006


6.2.  The 'le:index' attribute

   The 'le:index' attribute indicates whether applications should index
   links and referenced content.  The value of the attribute is either
   "yes" or "no".  A value of "no" indicates that applications SHOULD
   NOT index the referenced resource.

   For the sake of this specification, 'indexing' refers to the practice
   of parsing and processing the content of a resource for the purpose
   of populating a database used for searching and other forms of
   analysis.  The intended purpose of using le:index="no" would be for
   the publisher to indicate their preference that the associated
   resource not be processed for searching or analysis purposes.
     <entry xmlns="http://www.w3.org/2005/Atom"
            xmlns:le="http://purl.org/atompub/link-extensions/1.0">
       <id>...</id>
       <title>...</title>
       <link rel="enclosure"
             href="http://example.com/mediafiles/mysong.mp3"
             le:index="no" />
       ...
     </entry>

   The 'le:index' attribute MAY be contained by atom:link elements and
   atom:content elements containing a 'src' attribute.

6.3.  The 'le:archive' attribute

   The 'le:archive' attribute indicates whether applications should
   archive the targets of links and content references.  The value of
   the attribute is either "yes" or "no".  A value of "no" indicate that
   applications SHOULD NOT archive the referenced resource.

   For the sake of this specification, 'archiving' refers to the
   practice of maintain a local copy of a resource as part of a
   historical record.  This is different than the practice of
   maintaining locally cached copies of a resource for the sake of
   improving transmission performance and reducing network bandwidth.
   The intended purpose of using le:archive="no" would be for a
   publisher to indicate their preference that local copies of the
   asociated resource not be maintained for archival/historical
   purposes.









Snell                     Expires July 28, 2006                [Page 10]


Internet-Draft            Atom Link Extensions              January 2006


     <entry xmlns="http://www.w3.org/2005/Atom"
            xmlns:le="http://purl.org/atompub/link-extensions/1.0">
       <id>...</id>
       <title>...</title>
       <link rel="enclosure"
             href="http://example.com/mediafiles/mysong.mp3"
             le:archive="no" />
       ...
     </entry>

   The 'le:archive' attribute MAY be contained by atom:link elements and
   atom:content elements containing a 'src' attribute.


7.  Security Considerations

   While the mechanisms defined herein may be used to detect
   modifications of linked resources, the mechanisms MUST NOT be
   considered to provide a guarantee against inappropriate modification.
   Other mechanisms, such as XML Digital Signatures and XML Encryption
   should be used to properly secure Atom documents.


8.  IANA Considerations

   This specification does not introduce any IANA considerations.


9.  Acknowledgements

   The author gratefully acknowledges the feedback from the members of
   the Atom Publishing Format and Protocol working group during the
   development of this specification.

10.  References

   [RFC1864]  Myers, J. and M. Rose, "The Content-MD5 Header Field",
              RFC 1864, October 1995.

   [RFC2119]  Bradner, S., "Key words for use in RFCs to Indicate
              Requirement Levels", BCP 14, RFC 2119, March 1997.

   [RFC2616]  Fielding, R., Gettys, J., Mogul, J., Frystyk, H.,
              Masinter, L., Leach, P., and T. Berners-Lee, "Hypertext
              Transfer Protocol -- HTTP/1.1", RFC 2616, June 1999.

   [RFC4287]  Nottingham, M. and R. Sayre, "The Atom Syndication
              Format", RFC 4287, December 2005.



Snell                     Expires July 28, 2006                [Page 11]


Internet-Draft            Atom Link Extensions              January 2006


   [W3C.REC-html401-19991224]
              Hors, A., Jacobs, I., and D. Raggett, "HTML 4.01
              Specification", W3C REC REC-html401-19991224,
              December 1999.

   [W3C.REC-xhtml1-20020801]
              Pemberton, S., "XHTML[TM] 1.0 The Extensible HyperText
              Markup Language (Second Edition)", W3C REC REC-xhtml1-
              20020801, August 2002.

   [W3C.REC-xml-infoset-20040204]
              Tobin, R. and J. Cowan, "XML Information Set (Second
              Edition)", W3C REC REC-xml-infoset-20040204,
              February 2004.

   [W3C.REC-xml-names-19990114]
              Hollander, D., Bray, T., and A. Layman, "Namespaces in
              XML", W3C REC REC-xml-names-19990114, January 1999.

































Snell                     Expires July 28, 2006                [Page 12]


Internet-Draft            Atom Link Extensions              January 2006


Author's Address

   James M Snell


   Phone:
   Email: jasnell@gmail.com
   URI:   http://snellspace.com











































Snell                     Expires July 28, 2006                [Page 13]


Internet-Draft            Atom Link Extensions              January 2006


Intellectual Property Statement

   The IETF takes no position regarding the validity or scope of any
   Intellectual Property Rights or other rights that might be claimed to
   pertain to the implementation or use of the technology described in
   this document or the extent to which any license under such rights
   might or might not be available; nor does it represent that it has
   made any independent effort to identify any such rights.  Information
   on the procedures with respect to rights in RFC documents can be
   found in BCP 78 and BCP 79.

   Copies of IPR disclosures made to the IETF Secretariat and any
   assurances of licenses to be made available, or the result of an
   attempt made to obtain a general license or permission for the use of
   such proprietary rights by implementers or users of this
   specification can be obtained from the IETF on-line IPR repository at
   http://www.ietf.org/ipr.

   The IETF invites any interested party to bring to its attention any
   copyrights, patents or patent applications, or other proprietary
   rights that may cover technology that may be required to implement
   this standard.  Please address the information to the IETF at
   ietf-ipr@ietf.org.


Disclaimer of Validity

   This document and the information contained herein are provided on an
   "AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS
   OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY AND THE INTERNET
   ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS OR IMPLIED,
   INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE
   INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
   WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.


Copyright Statement

   Copyright (C) The Internet Society (2006).  This document is subject
   to the rights, licenses and restrictions contained in BCP 78, and
   except as set forth therein, the authors retain all their rights.


Acknowledgment

   Funding for the RFC Editor function is currently provided by the
   Internet Society.




Snell                     Expires July 28, 2006                [Page 14]