< draft-nottingham-link-template-01.txt   draft-nottingham-link-template-02.txt >
Network Working Group M. Nottingham Network Working Group M. Nottingham
Internet-Draft January 1, 2014 Internet-Draft June 19, 2017
Intended status: Informational Intended status: Standards Track
Expires: July 5, 2014 Expires: December 21, 2017
The Link-Template HTTP Header Field The Link-Template HTTP Header Field
draft-nottingham-link-template-01 draft-nottingham-link-template-02
Abstract Abstract
This specification defines the Link-Template HTTP header field, This specification defines the Link-Template HTTP header field,
providing a means for describing the structure of a link between two providing a means for describing the structure of a link between two
resources, so that new links can be generated. resources, so that new links can be generated.
Status of this Memo Note to Readers
The issues list can be found at https://github.com/mnot/I-D/labels/
link-template .
The most recent (often, unpublished) draft is at
https://mnot.github.io/I-D/link-template/ .
Recent changes are listed at https://github.com/mnot/I-D/commits/gh-
pages/link-template .
Status of This Memo
This Internet-Draft is submitted in full conformance with the This Internet-Draft is submitted in full conformance with the
provisions of BCP 78 and BCP 79. provisions of BCP 78 and BCP 79.
Internet-Drafts are working documents of the Internet Engineering Internet-Drafts are working documents of the Internet Engineering
Task Force (IETF). Note that other groups may also distribute Task Force (IETF). Note that other groups may also distribute
working documents as Internet-Drafts. The list of current Internet- working documents as Internet-Drafts. The list of current Internet-
Drafts is at http://datatracker.ietf.org/drafts/current/. Drafts is at http://datatracker.ietf.org/drafts/current/.
Internet-Drafts are draft documents valid for a maximum of six months Internet-Drafts are draft documents valid for a maximum of six months
and may be updated, replaced, or obsoleted by other documents at any and may be updated, replaced, or obsoleted by other documents at any
time. It is inappropriate to use Internet-Drafts as reference time. It is inappropriate to use Internet-Drafts as reference
material or to cite them other than as "work in progress." material or to cite them other than as "work in progress."
This Internet-Draft will expire on July 5, 2014. This Internet-Draft will expire on December 21, 2017.
Copyright Notice Copyright Notice
Copyright (c) 2014 IETF Trust and the persons identified as the Copyright (c) 2017 IETF Trust and the persons identified as the
document authors. All rights reserved. document authors. All rights reserved.
This document is subject to BCP 78 and the IETF Trust's Legal This document is subject to BCP 78 and the IETF Trust's Legal
Provisions Relating to IETF Documents Provisions Relating to IETF Documents
(http://trustee.ietf.org/license-info) in effect on the date of (http://trustee.ietf.org/license-info) in effect on the date of
publication of this document. Please review these documents publication of this document. Please review these documents
carefully, as they describe your rights and restrictions with respect carefully, as they describe your rights and restrictions with respect
to this document. Code Components extracted from this document must to this document. Code Components extracted from this document must
include Simplified BSD License text as described in Section 4.e of include Simplified BSD License text as described in Section 4.e of
the Trust Legal Provisions and are provided without warranty as the Trust Legal Provisions and are provided without warranty as
described in the Simplified BSD License. described in the Simplified BSD License.
Table of Contents Table of Contents
1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 3 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2
2. Requirements . . . . . . . . . . . . . . . . . . . . . . . . . 3 1.1. Notational Conventions . . . . . . . . . . . . . . . . . 2
3. Notational Conventions . . . . . . . . . . . . . . . . . . . . 3 2. The Link-Template Header Field . . . . . . . . . . . . . . . 2
4. The Link-Template Header Field . . . . . . . . . . . . . . . . 3 2.1. The 'var-base' parameter . . . . . . . . . . . . . . . . 3
5. The 'var-base' parameter . . . . . . . . . . . . . . . . . . . 4 3. Security Considerations . . . . . . . . . . . . . . . . . . . 4
6. Security Considerations . . . . . . . . . . . . . . . . . . . . 5 4. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 4
7. IANA Considerations . . . . . . . . . . . . . . . . . . . . . . 5 5. Normative References . . . . . . . . . . . . . . . . . . . . 4
8. References . . . . . . . . . . . . . . . . . . . . . . . . . . 5 Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 5
8.1. Normative References . . . . . . . . . . . . . . . . . . . 5
8.2. Informative References . . . . . . . . . . . . . . . . . . 5
Author's Address . . . . . . . . . . . . . . . . . . . . . . . . . 6
1. Introduction 1. Introduction
[RFC6570] defines a syntax for templates that, when expanded using a [RFC6570] defines a syntax for templates that, when expanded using a
set of variables, results in a URI [RFC3986]. set of variables, results in a URI [RFC3986].
This specification defines a HTTP header field for conveying This specification defines a HTTP header field for conveying
templated links in the headers of a HTTP message. It is templates for links in the headers of a HTTP message. It is
complimentary to the Link header field [RFC5988], which carries links complimentary to the Link header field [RFC5988], which carries links
directly. directly.
2. Requirements 1.1. Notational Conventions
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
document are to be interpreted as described in [RFC2119]. document are to be interpreted as described in [RFC2119].
3. Notational Conventions This document uses the Augmented BNF defined in [RFC7230] to specify
valid protocol elements. Additionally, it uses the modified
This document uses the Augmented BNF defined in [RFC2616] to specify "parameter" rule from [RFC5987], and the "URI-Template" rule from
valid protocol elements. [RFC6570].
Additionally, it uses the modified "parameter" rule from [RFC5987],
and the "URI-Template" rule from [RFC6570].
4. The Link-Template Header Field 2. The Link-Template Header Field
The Link-Template entity-header field provides a means for The Link-Template entity-header field provides a means for
serialising one or more links into HTTP headers. It is semantically serialising one or more links into HTTP headers. It is semantically
equivalent to the Link header field [RFC5988], except that it uses equivalent to the Link header field [RFC5988], except that it uses
URI Templates [RFC6570] to convey the structure of links. URI Templates [RFC6570] to convey the structure of links.
Link-Template = "Link-Template" ":" #linkt-value Link-Template = "Link-Template" ":" #linkt-value
linkt-value = "<" URI-Template ">" *( ";" parameter ) linkt-value = "<" URI-Template ">" *( ";" parameter )
For example: For example:
skipping to change at page 4, line 21 skipping to change at page 3, line 36
"anchor" parameter to modify the context IRI, and so on. "anchor" parameter to modify the context IRI, and so on.
Likewise, the requirements for parameters on linkt-values are the Likewise, the requirements for parameters on linkt-values are the
same as those for a Link header field; in particular, the "rel" same as those for a Link header field; in particular, the "rel"
parameter MUST NOT appear more than once, and if it does, the linkt- parameter MUST NOT appear more than once, and if it does, the linkt-
value MUST be ignored by parsers. value MUST be ignored by parsers.
This specification defines additional semantics for the "var-base" This specification defines additional semantics for the "var-base"
parameter on linkt-values; see below. parameter on linkt-values; see below.
5. The 'var-base' parameter 2.1. The 'var-base' parameter
When a linkt-value has a 'var-base' parameter, its value conveys a When a linkt-value has a 'var-base' parameter, its value conveys a
URI-reference that is used as a base URI for the variable names in URI-reference that is used as a base URI for the variable names in
the URI template. the URI template.
This mechanism allows template variables to be globally identified, This mechanism allows template variables to be globally identified,
rather than specific to the context of use. Dereferencing the URI rather than specific to the context of use. Dereferencing the URI
for a particular variable might lead to more information about the for a particular variable might lead to more information about the
syntax or semantics of that variable; specification of particular syntax or semantics of that variable; specification of particular
formats for this information is out of scope for this document. formats for this information is out of scope for this document.
skipping to change at page 4, line 48 skipping to change at page 4, line 15
For example: For example:
Link-Template: </widgets/{widget_id}>; Link-Template: </widgets/{widget_id}>;
rel="http://example.org/rel/widget"; rel="http://example.org/rel/widget";
var-base="http://example.org/vars/" var-base="http://example.org/vars/"
indicates that a resource with the relation type indicates that a resource with the relation type
"http://example.org/rel/widget" can be found by interpolating the "http://example.org/rel/widget" can be found by interpolating the
"http://example.org/vars/widget_id" variable into the template given. "http://example.org/vars/widget_id" variable into the template given.
If the current context of the link is "http://example.org/", the same If the current context of the message that the header appears within
information could be conveyed by this header field: is "http://example.org/", the same information could be conveyed by
this header field:
Link-Template: </widgets/{widget_id}>; Link-Template: </widgets/{widget_id}>;
rel="http://example.org/rel/widget"; rel="http://example.org/rel/widget";
var-base="/vars/" var-base="/vars/"
6. Security Considerations 3. Security Considerations
The security consideration for the Link header field in [RFC5988] and The security consideration for the Link header field in [RFC5988] and
those for URI Templates [RFC6570] both apply. those for URI Templates [RFC6570] both apply.
7. IANA Considerations 4. IANA Considerations
This specification enters the "Link-Template" into the registry of This specification enters the "Link-Template" into the registry of
Permanent Message Header Field Names. Permanent Message Header Field Names.
o Header Field Name: Link-Template Header Field Name: Link-Template
o Protocol: http Protocol: http
o Status: Status:
o Reference: [this document] Reference: [this document]
8. References
8.1. Normative References 5. Normative References
[RFC2119] Bradner, S., "Key words for use in RFCs to Indicate [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
Requirement Levels", BCP 14, RFC 2119, March 1997. Requirement Levels", BCP 14, RFC 2119,
DOI 10.17487/RFC2119, March 1997,
<http://www.rfc-editor.org/info/rfc2119>.
[RFC2616] Fielding, R., Gettys, J., Mogul, J., Frystyk, H., [RFC3986] Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform
Masinter, L., Leach, P., and T. Berners-Lee, "Hypertext Resource Identifier (URI): Generic Syntax", STD 66,
Transfer Protocol -- HTTP/1.1", RFC 2616, June 1999. RFC 3986, DOI 10.17487/RFC3986, January 2005,
<http://www.rfc-editor.org/info/rfc3986>.
[RFC5987] Reschke, J., "Character Set and Language Encoding for [RFC5987] Reschke, J., "Character Set and Language Encoding for
Hypertext Transfer Protocol (HTTP) Header Field Hypertext Transfer Protocol (HTTP) Header Field
Parameters", RFC 5987, August 2010. Parameters", RFC 5987, DOI 10.17487/RFC5987, August 2010,
<http://www.rfc-editor.org/info/rfc5987>.
[RFC5988] Nottingham, M., "Web Linking", RFC 5988, October 2010. [RFC5988] Nottingham, M., "Web Linking", RFC 5988,
DOI 10.17487/RFC5988, October 2010,
<http://www.rfc-editor.org/info/rfc5988>.
[RFC6570] Gregorio, J., Fielding, R., Hadley, M., Nottingham, M., [RFC6570] Gregorio, J., Fielding, R., Hadley, M., Nottingham, M.,
and D. Orchard, "URI Template", RFC 6570, March 2012. and D. Orchard, "URI Template", RFC 6570,
DOI 10.17487/RFC6570, March 2012,
8.2. Informative References <http://www.rfc-editor.org/info/rfc6570>.
[RFC3986] Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform [RFC7230] Fielding, R., Ed. and J. Reschke, Ed., "Hypertext Transfer
Resource Identifier (URI): Generic Syntax", STD 66, Protocol (HTTP/1.1): Message Syntax and Routing",
RFC 3986, January 2005. RFC 7230, DOI 10.17487/RFC7230, June 2014,
<http://www.rfc-editor.org/info/rfc7230>.
Author's Address Author's Address
Mark Nottingham Mark Nottingham
Email: mnot@mnot.net EMail: mnot@mnot.net
URI: http://www.mnot.net/ URI: https://www.mnot.net/
 End of changes. 23 change blocks. 
52 lines changed or deleted 63 lines changed or added

This html diff was produced by rfcdiff 1.46. The latest version is available from http://tools.ietf.org/tools/rfcdiff/