idnits 2.17.1 draft-wilde-accept-post-00.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- ** The abstract seems to contain references ([9], [10]), which it shouldn't. Please replace those with straight textual mentions of the documents in question. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (July 29, 2013) is 3924 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) ** Obsolete normative reference: RFC 2616 (ref. '2') (Obsoleted by RFC 7230, RFC 7231, RFC 7232, RFC 7233, RFC 7234, RFC 7235) Summary: 2 errors (**), 0 flaws (~~), 1 warning (==), 1 comment (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group J. Arwe 3 Internet-Draft S. Speicher 4 Intended status: Standards Track IBM 5 Expires: January 30, 2014 E. Wilde 6 EMC Corporation 7 July 29, 2013 9 The Accept-Post HTTP Header 10 draft-wilde-accept-post-00 12 Abstract 14 This specification defines a new HTTP response header field Accept- 15 Post, which indicates server support for specific media types for 16 entity bodies in HTTP POST requests. 18 Note to Readers 20 This draft should be discussed on the apps-discuss mailing list [9]. 22 Online access to all versions and files is available on github [10]. 24 Status of this Memo 26 This Internet-Draft is submitted in full conformance with the 27 provisions of BCP 78 and BCP 79. 29 Internet-Drafts are working documents of the Internet Engineering 30 Task Force (IETF). Note that other groups may also distribute 31 working documents as Internet-Drafts. The list of current Internet- 32 Drafts is at http://datatracker.ietf.org/drafts/current/. 34 Internet-Drafts are draft documents valid for a maximum of six months 35 and may be updated, replaced, or obsoleted by other documents at any 36 time. It is inappropriate to use Internet-Drafts as reference 37 material or to cite them other than as "work in progress." 39 This Internet-Draft will expire on January 30, 2014. 41 Copyright Notice 43 Copyright (c) 2013 IETF Trust and the persons identified as the 44 document authors. All rights reserved. 46 This document is subject to BCP 78 and the IETF Trust's Legal 47 Provisions Relating to IETF Documents 48 (http://trustee.ietf.org/license-info) in effect on the date of 49 publication of this document. Please review these documents 50 carefully, as they describe your rights and restrictions with respect 51 to this document. Code Components extracted from this document must 52 include Simplified BSD License text as described in Section 4.e of 53 the Trust Legal Provisions and are provided without warranty as 54 described in the Simplified BSD License. 56 Table of Contents 58 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 3 59 2. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . . 3 60 3. The Accept-Post Response Header Field . . . . . . . . . . . . . 3 61 4. IANA Considerations . . . . . . . . . . . . . . . . . . . . . . 3 62 4.1. The Accept-Post Response Header . . . . . . . . . . . . . . 4 63 5. Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 64 5.1. Linked Data Platform . . . . . . . . . . . . . . . . . . . 4 65 5.2. Atom Publishing Protocol . . . . . . . . . . . . . . . . . 4 66 5.3. Additional Information in Error Responses . . . . . . . . . 5 67 6. Implementation Status . . . . . . . . . . . . . . . . . . . . . 5 68 7. Security Considerations . . . . . . . . . . . . . . . . . . . . 5 69 8. Open Issues . . . . . . . . . . . . . . . . . . . . . . . . . . 6 70 9. References . . . . . . . . . . . . . . . . . . . . . . . . . . 6 71 9.1. Normative References . . . . . . . . . . . . . . . . . . . 6 72 9.2. Non-Normative References . . . . . . . . . . . . . . . . . 6 73 Appendix A. Acknowledgements . . . . . . . . . . . . . . . . . . . 7 74 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . . 7 76 1. Introduction 78 This specification defines a new HTTP response header field Accept- 79 Post, which indicates server support for specific media types for 80 entity bodies in HTTP POST requests. This header field is comparable 81 to the Accept-Patch response header field specified together with the 82 HTTP PATCH method [4] (notice, however, that while Accept-Patch is 83 defined to only list specific media types, Accept-Post reuses the 84 "media range" concept of HTTP's Accept header and thus allows media 85 type wildcards as well). 87 2. Terminology 89 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 90 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 91 document are to be interpreted as described in RFC 2119 [1]. 93 3. The Accept-Post Response Header Field 95 This specification introduces a new response header field Accept-Post 96 used to specify the document formats accepted by the server in HTTP 97 POST requests. Accept-Post SHOULD appear in the OPTIONS response for 98 any resource that supports the use of the POST method. The presence 99 of the Accept-Post header in response to any method is an implicit 100 indication that POST is allowed on the resource identified by the 101 Request-URI. The presence of a specific document format in this 102 header indicates that that specific format is allowed on the resource 103 identified by the Request-URI. 105 The syntax for Accept-Post headers, using the ABNF syntax defined in 106 Section 2.1 of RFC 2616 [2], is given by the following definition. 107 Accept-Post = "Accept-Post" ":" #( media-range [ accept-params ] ) 109 The Accept-Post header specifies a media range as defined by HTTP 110 [2]. The media range specifies a type of representation that can be 111 POSTed to the Request-URI. 113 The app:accept element is similar to the HTTP Accept request header 114 field [2]. Media type parameters are allowed within Accept-Post, but 115 Accept-Post has no notion of preference - "accept-params" or "q" 116 arguments, as specified in Section 14.1 of [2], are not significant. 118 4. IANA Considerations 119 4.1. The Accept-Post Response Header 121 The Accept-Post response header should be added to the permanent 122 registry of message header fields (see [3]). 124 5. Examples 126 Accept-Post extends the way in which interaction information can be 127 exposed in HTTP itself. The following sections contain some examples 128 how this can be used in concrete HTTP-based services. 130 5.1. Linked Data Platform 132 The Linked Data Platform (LDP) [5] describes a set of best practices 133 and simple approach for a read-write Linked Data architecture, based 134 on HTTP access to Web resources that describe their state using the 135 RDF data model. LDP defines LDP Containers (LDPC) and LDP Resources 136 (LDPR). Adding new LDPRs to an LDPC is done by sending an HTTP POST 137 request to the LDPC. An LDPC can constrain the media types it is 138 accepting for these POST requests, and MUST expose its support for 139 accepted media types via Accept-Post. 141 In fact, the Accept-Post header was initially developed within the 142 W3C's LDP Working Group (LDPWG), see Appendix A for acknowledgements. 143 It was then decided that the header itself might be useful in other 144 contexts as well, and thus should be specified in a standalone 145 document. 147 5.2. Atom Publishing Protocol 149 The Atom Publishing Protocol (AtomPub) [6] defines a model of 150 interacting with collections and members, based on representations 151 using the Atom [7] syntax. AtomPub allows clients to create new 152 collection members by using HTTP POST, with the request being sent to 153 the collection URI. AtomPub servers can limit the media types they 154 accept in these POST requests, and the accepted media types are 155 listed in an "AtomPub service document". 157 The Accept-Post header field does allow an AtomPub server to 158 advertise its support for specific media types in interactions with 159 the collection resource, without the need for a client to locate the 160 service document and interact with it. This increases the visibility 161 of the "POST to Create" model of AtomPub, and makes it easier for 162 clients to find out about the capabilities of a specific collection. 164 While the AtomPub protocol cannot be changed retroactively, this 165 additional way of exposing interaction guidance could make it easier 166 for clients to interact with AtomPub services that do support the 167 Accept-Post header field. For those that do not support Accept-Post, 168 clients would still have to rely on using the information contained 169 in the service document (including the sometimes tricky issue of how 170 to locate the service document for a given collection). 172 5.3. Additional Information in Error Responses 174 If a client POSTs an unsupported POST document, it is possible for 175 the server to use Accept-Post to indicate the supported media types. 176 These can be specified using a 415 (Unsupported Media Type) response 177 when the client sends a POST document format that the server does not 178 support for the resource identified by the Request-URI. Such a 179 response then MAY include an Accept-Post response header notify the 180 client what POST document media types are supported. 182 6. Implementation Status 184 Note to RFC Editor: Please remove this section before publication. 186 This section records the status of known implementations of the 187 protocol defined by this specification at the time of posting of this 188 Internet-Draft, and is based on a proposal described in RFC 6982 [8]. 189 The description of implementations in this section is intended to 190 assist the IETF in its decision processes in progressing drafts to 191 RFCs. Please note that the listing of any individual implementation 192 here does not imply endorsement by the IETF. Furthermore, no effort 193 has been spent to verify the information presented here that was 194 supplied by IETF contributors. This is not intended as, and must not 195 be construed to be, a catalog of available implementations or their 196 features. Readers are advised to note that other implementations may 197 exist. 199 According to RFC 6982, "this will allow reviewers and working groups 200 to assign due consideration to documents that have the benefit of 201 running code, which may serve as evidence of valuable experimentation 202 and feedback that have made the implemented protocols more mature. 203 It is up to the individual working groups to use this information as 204 they see fit". 206 ... 208 7. Security Considerations 210 The Accept-Post header may expose information that a server would 211 prefer to not publish. In such a case, a server can simply stop 212 exposing the header, in which case HTTP interactions would be back to 213 the level of standard HTTP (i.e., with no indication what kind of 214 media types a resource accepts in POST requests). 216 8. Open Issues 218 Note to RFC Editor: Please remove this section before publication. 220 o Accept-Post currently uses the "media range" concept of HTTP's 221 Accept header field. An alternative would be only support fully 222 specified media types, which is what the Accept-Patch header field 223 is doing. This latter solution is more constrained, and fails to 224 address some uses cases, such as AtomPub's way of exposing 225 collection support for POST requests. 227 9. References 229 9.1. Normative References 231 [1] Bradner, S., "Key words for use in RFCs to Indicate Requirement 232 Levels", RFC 2119, March 1997. 234 [2] Fielding, R., Gettys, J., Mogul, J., Frystyk, H., Masinter, L., 235 Leach, P., and T. Berners-Lee, "Hypertext Transfer Protocol -- 236 HTTP/1.1", RFC 2616, June 1999. 238 [3] Klyne, G., Nottingham, M., and J. Mogul, "Registration 239 Procedures for Message Header Fields", BCP 90, RFC 3864, 240 September 2004. 242 9.2. Non-Normative References 244 [4] Dusseault, L. and J. Snell, "PATCH Method for HTTP", RFC 5789, 245 March 2010. 247 [5] Speicher, S. and J. Arwe, "Linked Data Platform 1.0", World Wide 248 Web Consortium WD WD-ldp-20130307, March 2013, 249 . 251 [6] Gregorio, J. and B. de hOra, "The Atom Publishing Protocol", 252 RFC 5023, October 2007. 254 [7] Nottingham, M., Ed. and R. Sayre, Ed., "The Atom Syndication 255 Format", RFC 4287, December 2005. 257 [8] Sheffer, Y. and A. Farrel, "Improving Awareness of Running Code: 259 The Implementation Status Section", RFC 6982, July 2013. 261 URIs 263 [9] 265 [10] 267 Appendix A. Acknowledgements 269 This work has been done in the context of the W3C Linked Data 270 Platform Working Group (LDPWG) [5]. Thanks for comments and 271 suggestions provided by the working group as a whole. 273 Authors' Addresses 275 John Arwe 276 IBM 278 Email: johnarwe@us.ibm.com 280 Steve Speicher 281 IBM 283 Email: sspeiche@us.ibm.com 285 Erik Wilde 286 EMC Corporation 287 6801 Koll Center Parkway 288 Pleasanton, CA 94566 289 U.S.A. 291 Phone: +1-925-6006244 292 Email: erik.wilde@emc.com 293 URI: http://dret.net/netdret/