idnits 2.17.1 draft-ietf-appsawg-webfinger-08.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 : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (December 21, 2012) is 4143 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: 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) ** Obsolete normative reference: RFC 5785 (ref. '3') (Obsoleted by RFC 8615) ** Obsolete normative reference: RFC 5988 (ref. '4') (Obsoleted by RFC 8288) ** Obsolete normative reference: RFC 4627 (ref. '5') (Obsoleted by RFC 7158, RFC 7159) == Outdated reference: A later version (-07) exists of draft-ietf-appsawg-acct-uri-01 -- Possible downref: Non-RFC (?) normative reference: ref. '9' -- Possible downref: Non-RFC (?) normative reference: ref. '10' -- Possible downref: Non-RFC (?) normative reference: ref. '11' ** Obsolete normative reference: RFC 4288 (ref. '12') (Obsoleted by RFC 6838) ** Obsolete normative reference: RFC 2818 (ref. '14') (Obsoleted by RFC 9110) Summary: 6 errors (**), 0 flaws (~~), 2 warnings (==), 5 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group Paul E. Jones 3 Internet Draft Gonzalo Salgueiro 4 Intended status: Standards Track Cisco Systems 5 Expires: June 21, 2013 Joseph Smarr 6 Google 7 December 21, 2012 9 WebFinger 10 draft-ietf-appsawg-webfinger-08.txt 12 Abstract 14 This specification defines the WebFinger protocol, which can be used 15 to discover information about people or other entities on the 16 Internet using standard HTTP methods. 18 Status of this Memo 20 This Internet-Draft is submitted in full conformance with the 21 provisions of BCP 78 and BCP 79. 23 Internet-Drafts are working documents of the Internet Engineering 24 Task Force (IETF). Note that other groups may also distribute 25 working documents as Internet-Drafts. The list of current Internet- 26 Drafts is at http://datatracker.ietf.org/drafts/current/. 28 Internet-Drafts are draft documents valid for a maximum of six months 29 and may be updated, replaced, or obsoleted by other documents at any 30 time. It is inappropriate to use Internet-Drafts as reference 31 material or to cite them other than as "work in progress." 33 This Internet-Draft will expire on June 21, 2013. 35 Copyright Notice 37 Copyright (c) 2012 IETF Trust and the persons identified as the 38 document authors. All rights reserved. 40 This document is subject to BCP 78 and the IETF Trust's Legal 41 Provisions Relating to IETF Documents 42 (http://trustee.ietf.org/license-info) in effect on the date of 43 publication of this document. Please review these documents 44 carefully, as they describe your rights and restrictions with respect 45 to this document. Code Components extracted from this document must 46 include Simplified BSD License text as described in Section 4.e of 47 the Trust Legal Provisions and are provided without warranty as 48 described in the Simplified BSD License. 50 Table of Contents 52 1. Introduction...................................................2 53 2. Terminology....................................................3 54 3. Example Uses of WebFinger......................................3 55 3.1. Locating a User's Blog....................................3 56 3.2. Identity Provider Discovery for OpenID Connect............5 57 3.3. Auto-Configuration of Email Clients.......................6 58 3.4. Retrieving Device Information.............................7 59 4. WebFinger Protocol.............................................8 60 4.1. Constructing a WebFinger Query............................8 61 4.2. Performing a WebFinger Query..............................8 62 4.3. The "rel" Parameter.......................................9 63 4.4. The JSON Resource Descriptor (JRD).......................10 64 4.4.1. expires.............................................11 65 4.4.2. subject.............................................11 66 4.4.3. aliases.............................................11 67 4.4.4. properties..........................................12 68 4.4.5. links...............................................12 69 4.5. WebFinger and URIs.......................................14 70 5. Cross-Origin Resource Sharing (CORS)..........................14 71 6. Access Control................................................15 72 7. Hosted WebFinger Services.....................................15 73 8. Security Considerations.......................................16 74 9. IANA Considerations...........................................17 75 10. Acknowledgments..............................................18 76 11. References...................................................18 77 11.1. Normative References....................................18 78 11.2. Informative References..................................19 79 Author's Addresses...............................................20 81 1. Introduction 83 WebFinger is used to discover information about people or other 84 entities on the Internet that are identified by a URI [6] or IRI [7] 85 using standard Hypertext Transfer Protocol (HTTP) [2] methods over a 86 secure transport [14]. A WebFinger server returns a JavaScript 87 Object Notation (JSON) [5] object that describes a resource that is 88 queried. The JSON object is referred to as the JSON Resource 89 Descriptor (JRD). 91 For a person, the kinds of information that might be discoverable via 92 WebFinger include a personal profile address, identity service, 93 telephone number, or preferred avatar. For other entities on the 94 Internet, a WebFinger server might return JRDs containing link 95 relations that allow a client to discover, for example, the amount of 96 toner in a printer or the physical location of a server. 98 Information returned via WebFinger might be for direct human 99 consumption (e.g., looking up someone's phone number), or it might be 100 used by systems to help carry out some operation (e.g., facilitate 101 logging into a web site by determining a user's identity service). 103 Use of WebFinger is illustrated in the examples in Section 3 and 104 described more formally in Section 4. 106 2. Terminology 108 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 109 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 110 document are to be interpreted as described in RFC 2119 [1]. 112 WebFinger makes heavy use of "Link Relations". Briefly, a Link 113 Relation is an attribute and value pair used on the Internet wherein 114 the attribute identifies the type of link to which the associated 115 value refers. In HTTP and Web Linking [4], the attribute is a "rel" 116 and the value is an "href". WebFinger also uses the "rel" attribute, 117 where the "rel" value is either a single IANA-registered link 118 relation type [10] or a URI [6]. 120 3. Example Uses of WebFinger 122 This non-normative section shows a few sample uses of WebFinger. 124 3.1. Locating a User's Blog 126 Assume you receive an email from Bob and he refers to something he 127 posted on his blog, but you do not know where Bob's blog is located. 128 It would be simple to discover the address of Bob's blog if he makes 129 that information available via WebFinger. 131 Assume your email client can discover the blog for you. After 132 receiving the message from Bob (bob@example.com), you instruct your 133 email client to perform a WebFinger query. It does so by issuing the 134 following HTTPS [14] query to example.com: 136 GET /.well-known/webfinger? 137 resource=acct%3Abob%40example.com HTTP/1.1 138 Host: example.com 140 The server might then respond with a message like this: 142 HTTP/1.1 200 OK 143 Access-Control-Allow-Origin: * 144 Content-Type: application/json; charset=UTF-8 146 { 147 "expires" : "2012-11-16T19:41:35Z", 148 "subject" : "acct:bob@example.com", 149 "aliases" : 150 [ 151 "http://www.example.com/~bob/" 152 ], 153 "properties" : 154 { 155 "http://example.com/ns/role/" : "employee" 156 }, 157 "links" : 158 [ 159 { 160 "rel" : "http://webfinger.net/rel/avatar", 161 "type" : "image/jpeg", 162 "href" : "http://www.example.com/~bob/bob.jpg" 163 }, 164 { 165 "rel" : "http://webfinger.net/rel/profile-page", 166 "href" : "http://www.example.com/~bob/" 167 }, 168 { 169 "rel" : "blog", 170 "type" : "text/html", 171 "href" : "http://blogs.example.com/bob/", 172 "titles" : 173 { 174 "en-us" : "The Magical World of Bob", 175 "fr" : "Le monde magique de Bob" 176 } 177 }, 178 { 179 "rel" : "vcard", 180 "href" : "https://www.example.com/~bob/bob.vcf" 181 } 182 ] 183 } 185 The email client would take note of the "blog" link relation in the 186 above JRD that refers to Bob's blog. This URL would then be 187 presented to you so that you could then visit his blog. The email 188 client might also note that Bob has published an avatar link relation 189 and use that picture to represent Bob inside the email client. 190 Lastly, the client might consider the vcard [16] link relation in 191 order to update contact information for Bob. 193 In the above example, an "acct" URI [8] is used in the query, though 194 any valid alias for the user might also be used. An alias is a URI 195 that is different from the "subject" URI that identifies the same 196 entity. In the above example, there is one "http" alias returned, 197 though there might have been more than one. Had the "http:" URI 198 shown as an alias been used to query for information about Bob, the 199 query would have appeared as: 201 GET /.well-known/webfinger? 202 resource=http%3A%2F%2Fwww.example.com%2F~bob%2F HTTP/1.1 203 Host: example.com 205 The response would have been substantially the same, with the subject 206 and alias information changed as necessary. Other information, such 207 as the expiration time might also change, but the set of link 208 relations and properties would be the same with either response. 210 3.2. Identity Provider Discovery for OpenID Connect 212 Suppose Carol wishes to authenticate with a web site she visits using 213 OpenID Connect [18]. She would provide the web site with her OpenID 214 Connect identifier, say carol@example.com. The visited web site 215 would perform a WebFinger query looking for the OpenID Connect 216 Provider. Since the site is interested in only one particular link 217 relation, the server might utilize the "rel" parameter as described 218 in Section 4.3: 220 GET /.well-known/webfinger? 221 resource=acct%3Acarol%40example.com& 222 rel=http%3A%2F%2Fopenid.net%2Fspecs%2Fconnect%2F1.0%2Fissuer 223 HTTP/1.1 224 Host: example.com 226 The server might respond with a JRD like this: 228 { 229 "expires" : "2012-11-16T19:41:35Z", 230 "subject" : "acct:carol@example.com", 231 "aliases" : 232 [ 233 "http://www.example.com/~carol/" 234 ], 235 "properties" : 236 { 237 "http://example.com/ns/role/" : "employee" 238 }, 239 "links" : 240 [ 241 { 242 "rel" : "http://openid.net/specs/connect/1.0/issuer", 243 "href" : "https://openid.example.com/" 244 } 246 ] 247 } 249 Since the "rel" parameter only filters the link relations returned by 250 the server, other name/value pairs in the response, including any 251 aliases or properties, would be returned. Also, since support for 252 the "rel" parameter is optional, the client must not assume the 253 "links" array will contain only the requested link relation. 255 3.3. Auto-Configuration of Email Clients 257 WebFinger could be used to auto-provision an email client with basic 258 configuration data. Suppose that sue@example.com wants to configure 259 her email client. Her email client might issue the following query: 261 GET /.well-known/webfinger? 262 resource=mailto%3Asue%40example.com HTTP/1.1 263 Host: example.com 265 The response from the server would contain entries for the various 266 protocols, transport options, and security options. If there are 267 multiple options, the server might return a link relation that for 268 each of the valid options and the client or Sue might select which 269 option to choose. Since JRDs list link relations in a specific 270 order, then the most-preferred choices could be presented first. 271 Consider this response: 273 { 274 "subject" : "mailto:sue@example.com", 275 "links" : 276 [ 277 { 278 "rel" : "http://example.net/rel/smtp-server", 279 "properties" : 280 { 281 "http://example.net/email/host" : "smtp.example.com", 282 "http://example.net/email/port" : "587", 283 "http://example.net/email/login-required" : "yes", 284 "http://example.net/email/transport" : "starttls" 285 } 286 }, 287 { 288 "rel" : "http://example.net/rel/imap-server", 289 "properties" : 290 { 291 "http://example.net/email/host" : "imap.example.com", 292 "http://example.net/email/port" : "993", 293 "http://example.net/email/transport" : "ssl" 294 } 296 } 297 ] 298 } 300 In this example, you can see that the WebFinger server advertises an 301 SMTP service and an IMAP service. In this example, the "href" 302 entries associated with the link relation are absent. This is valid 303 when there is no external reference that needs to be made. 305 3.4. Retrieving Device Information 307 As another example, suppose there are printers on the network and you 308 would like to check the current toner level for a particular printer 309 identified via the URI device:p1.example.com. While the "device" URI 310 scheme is not presently specified, we use it here for illustrative 311 purposes. 313 Following the procedures similar to those above, a query may be 314 issued to get link relations specific to this URI like this: 316 GET /.well-known/webfinger? 317 resource=device%3Ap1.example.com HTTP/1.1 318 Host: example.com 320 The link relations that are returned for a device may be quite 321 different than those for user accounts. Perhaps we may see a 322 response like this: 324 HTTP/1.1 200 OK 325 Access-Control-Allow-Origin: * 326 Content-Type: application/json; charset=UTF-8 328 { 329 "subject" : "device:p1.example.com", 330 "links" : 331 [ 332 { 333 "rel" : "http://example.com/rel/tipsi", 334 "href" : "http://192.168.1.5/npap/" 335 } 336 ] 337 } 339 While this example is fictitious, you can imagine that perhaps the 340 Transport Independent, Printer/System Interface [17] may be enhanced 341 with a web interface that allows a device that understands the TIP/SI 342 web interface specification to query the printer for toner levels. 344 4. WebFinger Protocol 346 WebFinger is a simple HTTP-based web service that returns a JSON 347 Resource Descriptor (JRD) to convey information about an entity on 348 the Internet and the Cross-Origin Resource Sharing (CORS) [9] 349 specification to facilitate queries made via a web browser. 351 4.1. Constructing a WebFinger Query 353 This specification defines URI parameters that are passed from the 354 client to the server when issuing a request. These parameters, 355 "resource" and "rel", and the parameter values are included in the 356 "query" component of the URI (see Section 3.4 of RFC 3986). To 357 construct the "query" component, the client performs the following 358 steps. First, each parameter value is percent-encoded as per Section 359 2.1 of RFC 3986. Next, the client constructs a string to be placed 360 in the query component by concatenating the name of the first 361 parameter together with an equal sign ("=") and the percent-encoded 362 parameter value. For any subsequent parameters, the client appends 363 an ampersand ("&") to the string, the name of the next parameter, an 364 equal sign, and percent-encoded parameter value. The client MUST NOT 365 insert any spaces while constructing the string. The order in which 366 the client places each parameter and its corresponding parameter 367 value is unspecified. 369 4.2. Performing a WebFinger Query 371 A WebFinger client issues a query to the well-known [3] resource 372 /.well-known/webfinger. A query MUST include the "resource" 373 parameter exactly once and set to the value of the URI for which 374 information is being sought. If the "resource" parameter is absent 375 or malformed, the WebFinger server MUST indicate that the request is 376 bad as per Section 10.4.1 of RFC 2616 [2]. 378 A client MUST query the WebFinger server using HTTPS only. If the 379 client determines that the server has an invalid certificate, the 380 server returns a 4xx or 5xx status code, or the HTTPS connection 381 cannot be established for any reason, the client MUST accept that the 382 WebFinger query has failed and MUST NOT attempt to reissue the 383 WebFinger request using HTTP over a non-secure connection. 385 A WebFinger server MUST return a JRD as the representation for the 386 resource if the client requests no other supported format explicitly 387 via the HTTP "Accept" header. The client MAY include the "Accept" 388 header to indicate a desired representation, though no other 389 representation than JRD is defined in this specification. The media 390 type used for the JSON Resource Descriptor (JRD) is 391 "application/json" [5]. 393 A WebFinger server MAY redirect the client, but MUST only redirect 394 the client to an HTTPS URI. 396 A WebFinger server can include cache validators in a response to 397 enable conditional requests by the client and/or expiration times as 398 per Section 13 of RFC 2616. 400 4.3. The "rel" Parameter 402 When issuing a request to the server, the client MAY utilize the 403 "rel" parameter to request only a subset of the information that 404 would otherwise be returned without the "rel" parameter. When the 405 "rel" parameter is used, only the link relations that match the link 406 relations provided via "rel" are included in the array of links 407 returned in the JRD. All other information normally present in a 408 resource descriptor is present in the resource descriptor, even when 409 "rel" is employed. 411 The "rel" parameter MAY be transmitted to the server multiple times 412 in order to request multiple types of link relations. 414 The purpose of the "rel" parameter is to return a subset of 415 resource's link relations. Use of the parameter might reduce 416 processing requirements on either the client or server, and it might 417 also reduce the bandwidth required to convey the partial resource 418 descriptor, especially if there are numerous link relation values to 419 convey for a given resource. 421 Support for the "rel" parameter is OPTIONAL, but RECOMMENDED on the 422 server. Should the server not support the "rel" parameter, it MUST 423 ignore it and process the request as if no "rel" parameter values 424 were present. 426 The following example presents the same example as found in Section 427 3.1, but uses the "rel" parameter in order to select two link 428 relations: 430 GET /.well-known/webfinger? 431 resource=acct%3Abob%40example.com& 432 rel=http%3A%2F%2Fwebfinger.net%2Frel%2Fprofile-page& 433 rel=vcard HTTP/1.1 434 Host: example.com 436 In this example, the client requests the link relations of type 437 "http://webfinger.net/rel/profile-page" and "vcard". The server then 438 responds with a message like this: 440 HTTP/1.1 200 OK 441 Access-Control-Allow-Origin: * 442 Content-Type: application/json; charset=UTF-8 444 { 445 "expires" : "2012-11-16T19:41:35Z", 446 "subject" : "acct:bob@example.com", 447 "aliases" : 448 [ 449 "http://www.example.com/~bob/" 450 ], 451 "properties" : 452 { 453 "http://example.com/ns/role/" : "employee" 454 }, 455 "links" : 456 [ 457 { 458 "rel" : "http://webfinger.net/rel/profile-page", 459 "href" : "http://www.example.com/~bob/" 460 }, 461 { 462 "rel" : "vcard", 463 "href" : "http://www.example.com/~bob/bob.vcf" 464 } 465 ] 466 } 468 As you can see, the server returned only the link relations requested 469 by the client, but also included the other parts of the JRD. 471 In the event that a client requests links for link relations that are 472 not defined for the specified resource, a resource descriptor MUST be 473 returned. In the returned JRD, the "links" array MAY be absent, 474 empty, or contain only links that did match a provided "rel" value. 476 4.4. The JSON Resource Descriptor (JRD) 478 The JSON Resource Descriptor (JRD), originally introduced in RFC 6415 479 [19] and based on the Extensible Resource Descriptor (XRD) format 480 [20], is a JSON object that is comprised of the following name/value 481 pairs: 483 o expires 484 o subject 485 o aliases 486 o properties 487 o links 489 The members "expires" and "subject" are name/value pairs whose value 490 are strings, "aliases" is an array of strings, "properties" is an 491 object comprised of name/value pairs whose values are strings, and 492 "links" is an array of objects that contain link relation 493 information. 495 When processing a JRD, the client MUST ignore any unknown member and 496 not treat the presence of an unknown member as an error. 498 Below, each of these members of the JRD is described in more detail. 500 4.4.1. expires 502 The value of the "expires" member is a string that indicates the date 503 and time after which the JRD SHOULD be considered expired and no 504 longer utilized. 506 This format is formally defined in RFC 3339 [15]. 508 The "expires" member MUST NOT use fractional seconds and MUST express 509 time only Universal Coordinate Time via the "Z" designation on the 510 end of the string. 512 An example of the "expires" member is: 514 "expires" : "2012-11-16T19:41:35Z" 516 The "expires" member is optional in a JRD, but SHOULD be honored if 517 present. 519 4.4.2. subject 521 The value of the "subject" member is a URI that identifies the entity 522 that the JRD describes. 524 The "subject" value returned by a WebFinger server MAY differ from 525 the value of the "resource" parameter used in the client's request. 526 This may happen, for example, when the subject's identity changes 527 (e.g., a user moves his or her account to another service) or when 528 the server prefers to express URIs in canonical form. 530 The "subject" member MUST be present. 532 4.4.3. aliases 534 The "aliases" array is an array of zero or more URI strings that 535 identify the same entity as the "subject" URI. Each URI must be an 536 absolute URI. 538 The "aliases" array is optional. 540 4.4.4. properties 542 The "properties" object is comprised of zero or more name/value pairs 543 whose names are absolute URIs and whose values are strings or null. 544 Properties are used to convey additional information about the 545 subject of the JRD. As an example, consider this use of 546 "properties": 548 "properties" : { "http://webfinger.net/ns/name" : "Bob Smith" } 550 The "properties" member is optional. 552 4.4.5. links 554 The "links" array contains zero or more elements that contain the 555 link relation information. Each element of the array is an object 556 comprised of the following name/value pairs: 558 o rel 559 o type 560 o href 561 o titles 562 o properties 564 The members "rel", "type", and "href" are a name/value pairs whose 565 values are strings, "titles" and "properties" are objects comprised 566 of name/value pairs whose values are strings. 568 The order of elements in the "links" array indicates an order of 569 preference. Thus, if there are two or more link relations having the 570 same "rel" value, the first link relation would indicate the user's 571 preferred link relation. 573 The "links" array is optional in the JRD. 575 Below, each of the members of the objects found in the "links" array 576 is described in more detail. Each object in the "links" array, 577 referred to as a "link relation object", is completely independent 578 from any other object in the array; any requirement to include a 579 given member in the link relation object refers only to that 580 particular object. 582 4.4.5.1. rel 584 The value of the "rel" member is a string that is either an absolute 585 URI or a registered relation type [10] (see RFC 5988 [4]). The value 586 of the "rel" member MUST contain exactly one URI string or registered 587 relation type and MUST NOT contain a space-separated list of URIs or 588 registered relation types. The URI or registered relation type 589 identifies the type of the link relation. The other members of the 590 object have meaning only once the type of link relation is 591 understood. In some instances, the link relation will have 592 associated semantics that allow a client to query for other resources 593 on the Internet. In other instances, the link relation will have 594 associated semantics that allow the client to utilize the other 595 members of the link relation object without fetching additional 596 external resources. 598 The "rel" member MUST be present in the link relation object. 600 4.4.5.2. type 602 The value of the "type" member is a string that indicates the media 603 type [11] of the linked resource (see RFC 4288 [12]). 605 The "type" member is optional in the link relation object. 607 4.4.5.3. href 609 The value of the "href" member is a string that contains a URI 610 pointing to the linked resource. 612 The "href" member is optional in the link relation object. 614 4.4.5.4. titles 616 The "titles" object is comprised of zero or more name/value pairs 617 whose name is a language tag [13] or the string "default". The 618 string is human-readable and describes the link relation. More than 619 one title for the link relation MAY be provided for the benefit of 620 users who utilize the link relation and, if used, a language 621 identifier SHOULD be duly used as the name. If the language is 622 unknown or unspecified, then the name is "default". 624 A JRD SHOULD NOT include more than one title identified with the same 625 language tag (or "default") within the link relation object. Meaning 626 is undefined if a link relation object includes more than one title 627 named with the same language tag (or "default"), though this MUST NOT 628 treat this as an error. A client MAY select whichever title or 629 titles it wishes to utilize. 631 Here is an example of the titles object: 633 "titles" : 634 { 635 "en-us" : "The Magical World of Bob", 636 "fr" : "Le monde magique de Bob" 637 } 639 The "titles" member is optional in the link relation object. 641 4.4.5.5. properties 643 The "properties" object within the link relation object is comprised 644 of zero or more name/value pairs whose names are absolute URIs and 645 whose values are strings or null. Properties are used to convey 646 additional information about the link relation. As an example, 647 consider this use of "properties": 649 "properties" : { "http://example.net/mail/port" : "993" } 651 The "properties" member is optional in the link relation object. 653 4.5. WebFinger and URIs 655 WebFinger requests can include a parameter specifying the URI of an 656 account, device, or other entity. WebFinger is agnostic regarding 657 the scheme of such a URI: it could be an "acct" URI [7], an "http" or 658 "https" URI, a "mailto" URI [21], or some other scheme. 660 For resources associated with a user account at a host, use of the 661 "acct" URI scheme is RECOMMENDED, since it explicitly identifies an 662 account accessible via WebFinger. Further, the "acct" URI scheme is 663 not associated with other protocols as, by way of example, the 664 "mailto" URI scheme is associated with email. Since not every host 665 offers email service, using the "mailto" URI scheme is not ideal for 666 identifying user accounts on all hosts. That said, use of the 667 "mailto" URI scheme would be ideal for use with WebFinger to discover 668 mail server configuration information for a user. 670 5. Cross-Origin Resource Sharing (CORS) 672 WebFinger resources might not be accessible from a web browser due to 673 "Same-Origin" policies. The current best practice is to make 674 resources available to browsers through Cross-Origin Resource Sharing 675 (CORS) [9], and servers MUST include the Access-Control-Allow-Origin 676 HTTP header in responses. Servers SHOULD support the least 677 restrictive setting by allowing any domain access to the WebFinger 678 resources: 680 Access-Control-Allow-Origin: * 682 There are cases where defaulting to the least restrictive setting is 683 not appropriate, for example a WebFinger server on an intranet that 684 provides sensitive company information should not allow CORS requests 685 from any domain, as that could allow leaking of that sensitive 686 information. A WebFinger server that wishes to restrict access to 687 information from external entities SHOULD use a more restrictive 688 Access-Control-Allow-Origin header. 690 6. Access Control 692 As with all web resources, access to the /.well-known/webfinger 693 resource MAY require authentication. Further, failure to provide 694 required credentials MAY result in the server forbidding access or 695 providing a different response than had the client authenticated with 696 the server. 698 Likewise, a server MAY provide different responses to different 699 clients based on other factors, such as whether the client is inside 700 or outside a corporate network. As a concrete example, a query 701 performed on the internal corporate network might return link 702 relations to employee pictures, whereas link relations for employee 703 pictures might not be provided to external entities. 705 Further, link relations provided in a WebFinger server response MAY 706 point to web resources that impose access restrictions. For example, 707 the aforementioned corporate server may provide both internal and 708 external entities with URIs to employee pictures, but further 709 authentication might be required in order for the client to access 710 the picture resources if the request comes from outside the corporate 711 network. 713 The decisions made with respect to what set of link relations a 714 WebFinger server provides to one client versus another and what 715 resources require further authentication, as well as the specific 716 authentication mechanisms employed, are outside the scope of this 717 document. 719 7. Hosted WebFinger Services 721 As with most services provided on the Internet, it is possible for a 722 domain owner to utilize "hosted" WebFinger services. By way of 723 example, a domain owner might control most aspects of their domain, 724 but use a third-party hosting service for email. In the case of 725 email, mail servers for a domain are identified by MX records. An MX 726 record points to the mail server to which mail for the domain should 727 be delivered. It does not matter to the sending mail server whether 728 those MX records point to a server in the destination domain or a 729 different domain. 731 Likewise, a domain owner might utilize the services of a third party 732 to provide WebFinger services on behalf of its users. Just as a 733 domain owner was required to insert MX records into DNS to allow for 734 hosted email serves, the domain owner is required to redirect HTTP 735 queries to its domain to allow for hosted WebFinger services. 737 When a query is issued to /.well-known/webfinger, the web server MUST 738 return a response with a redirection status code that includes a 739 Location header pointing to the location of the hosted WebFinger 740 service URL. The WebFinger service URL does not need to point to 741 /.well-known/* on the hosting service provider server. 743 As an example, assume that example.com's WebFinger services are 744 hosted by example.net. Suppose a client issues a query for 745 acct:alice@example.com like this: 747 GET /.well-known/webfinger? 748 resource=acct%3Aalice%40example.com HTTP/1.1 749 Host: example.com 751 The server might respond with this: 753 HTTP/1.1 307 Temporary Redirect 754 Access-Control-Allow-Origin: * 755 Location: https://wf.example.net/example.com/webfinger? 756 resource=acct%3Aalice%40example.com HTTP/1.1 758 The client can then follow the redirection, re-issuing the request to 759 the URL provided in the Location header. Note that the server will 760 include any required URI parameters in the Location header value, 761 which could be different than the URI parameters the client 762 originally used. 764 8. Security Considerations 766 Since this specification utilizes Cross-Origin Resource Sharing 767 (CORS) [9], all of the security considerations applicable CORS are 768 also applicable to this specification. 770 The required use of HTTPS is to ensure that information is not 771 modified during transit. It should be appreciated that in 772 environments where a web server is normally available, there exists 773 the possibility that a compromised network might have its WebFinger 774 server operating on HTTPS replaced with one operating only over HTTP. 775 As such, clients MUST NOT issue queries over a non-secure connection. 777 Clients MUST verify that the certificate used on an HTTPS connection 778 is valid and accept a response only if the certificate is valid. 780 Service providers and users should be aware that placing information 781 on the Internet accessible through WebFinger means that any user can 782 access that information. While WebFinger can be an extremely useful 783 tool for allowing quick and easy access to one's avatar, blog, or 784 other personal information, users should understand the risks, too. 785 If one does not wish to share certain information with the world, do 786 not allow that information to be freely accessible through WebFinger 787 and do not use any service supporting WebFinger. Further, a 788 WebFinger server MUST NOT be used to provide any personal information 789 to any party unless explicitly or implicitly authorized by the person 790 whose information is being shared. Implicit authorization can be 791 determined by the user's voluntary utilization of a service as 792 defined by that service's relevant terms of use or published privacy 793 policy. 795 The aforementioned word of caution is perhaps worth emphasizing again 796 with respect to dynamic information one might wish to share, such as 797 the current location of a user. WebFinger can be a powerful tool 798 used to assemble information about a person all in one place, but 799 service providers and users should be mindful of the nature of that 800 information shared and the fact that it might be available for the 801 entire world to see. Sharing location information, for example, 802 would potentially put a person in danger from any individual who 803 might seek to inflict harm on that person. 805 The easy access to user information via WebFinger was a design goal 806 of the protocol, not a limitation. If one wishes to limit access to 807 information available via WebFinger, such as a WebFinger server for 808 use inside a corporate network, the network administrator must take 809 measures necessary to limit access from outside the network. Using 810 standard methods for securing web resources, network administrators 811 do have the ability to control access to resources that might return 812 sensitive information. Further, a WebFinger server can be employed 813 in such a way as to require authentication and prevent disclosure of 814 information to unauthorized entities. 816 Finally, a WebFinger server has no means of ensuring that information 817 provided by a user is accurate. Likewise, neither the server nor the 818 client can be absolutely guaranteed that information has not been 819 manipulated either at the server or along the communication path 820 between the client and server. Use of HTTPS helps to address some 821 concerns with manipulation of information along the communication 822 path, but it clearly cannot address issues where the server provided 823 incorrect information, either due to being provided false information 824 or due to malicious behavior on the part of the server administrator. 825 As with any information service available on the Internet, users 826 should wary of information received from untrusted sources. 828 9. IANA Considerations 830 This specification registers the "webfinger" well-known URI in the 831 Well-Known URI Registry as defined by [3]. 833 URI suffix: webfinger 834 Change controller: IETF 836 Specification document(s): RFC QQQ 838 Related information: The response from WebFinger server will be a 839 JSON Resource Descriptor (JRD) as described in section 4.4 of RFC 840 QQQ. 842 [RFC EDITOR: Please replace "QQQ" references in this section with the 843 number for this RFC.] 845 10. Acknowledgments 847 The authors would like to acknowledge Eran Hammer-Lahav, Blaine Cook, 848 Brad Fitzpatrick, Laurent-Walter Goix, Joe Clarke, Michael B. Jones, 849 Peter Saint-Andre, Dick Hardt, Tim Bray, and Joe Gregorio for their 850 invaluable input. 852 11. References 854 11.1. Normative References 856 [1] Bradner, S., "Key words for use in RFCs to Indicate Requirement 857 Levels", BCP 14, RFC 2119, March 1997. 859 [2] Fielding, R., Gettys, J., Mogul, J., Frystyk, H., Masinter, L., 860 Leach, P., and T. Berners-Lee, "Hypertext Transfer Protocol -- 861 HTTP/1.1", RFC 2616, June 1999. 863 [3] Nottingham, M., Hammer-Lahav, E., "Defining Well-Known Uniform 864 Resource Identifiers (URIs)", RFC 5785, April 2010. 866 [4] Nottingham, M., "Web Linking", RFC 5988, October 2010. 868 [5] Crockford, D., "The application/json Media Type for JavaScript 869 Object Notation (JSON)", RFC 4627, July 2006. 871 [6] Berners-Lee, T., Fielding, R., and Masinter, L., "Uniform 872 Resource Identifier (URI): Generic Syntax", STD 66, RFC 3986, 873 January 2005. 875 [7] Duerst, M., "Internationalized Resource Identifiers (IRIs)", 876 RFC 3987, January 2005. 878 [8] Saint-Andre, P., "The 'acct' URI Scheme", draft-ietf-appsawg- 879 acct-uri-01, October 2012. 881 [9] Van Kesteren, A., "Cross-Origin Resource Sharing", W3C CORS 882 http://www.w3.org/TR/cors/, July 2010. 884 [10] IANA, "Link Relations", http://www.iana.org/assignments/link- 885 relations/. 887 [11] IANA, "MIME Media Types", 888 http://www.iana.org/assignments/media-types/index.html. 890 [12] Freed, N., Klensin, J., "Media Type Specifications and 891 Registration Procedures", RFC 4288, December 2005. 893 [13] Phillips, A., Davis, M., "Tags for Identifying Languages", RFC 894 5646, January 2001. 896 [14] Rescorla, E., "HTTP Over TLS", RFC 2818, May 2000. 898 [15] Klyne, G., Newman, C., "Date and Time on the Internet: 899 Timestamps", RFC 3339, July 2002. 901 11.2. Informative References 903 [16] Perreault, S., "vCard Format Specification", RFC 6350, August 904 2011. 906 [17] "Transport Independent, Printer/System Interface", IEEE Std 907 1284.1-1997, 1997. 909 [18] Sakimura, N., Bradley, J., Jones, M., de Medeiros, B., 910 Mortimore, C., and E. Jay, "OpenID Connect Messages 1.0", June 911 2012, http://openid.net/specs/openid-connect-messages-1_0.html. 913 [19] Hammer-Lahav, E. and Cook, B., "Web Host Metadata", RFC 6415, 914 October 2011. 916 [20] Hammer-Lahav, E. and W. Norris, "Extensible Resource Descriptor 917 (XRD) Version 1.0", http://docs.oasis- 918 open.org/xri/xrd/v1.0/xrd-1.0.html. 920 [21] Duerst, M., Masinter, L., and J. Zawinski, "The 'mailto' URI 921 Scheme", RFC 6068, October 2010. 923 Author's Addresses 925 Paul E. Jones 926 Cisco Systems, Inc. 927 7025 Kit Creek Rd. 928 Research Triangle Park, NC 27709 929 USA 931 Phone: +1 919 476 2048 932 Email: paulej@packetizer.com 933 IM: xmpp:paulej@packetizer.com 935 Gonzalo Salgueiro 936 Cisco Systems, Inc. 937 7025 Kit Creek Rd. 938 Research Triangle Park, NC 27709 939 USA 941 Phone: +1 919 392 3266 942 Email: gsalguei@cisco.com 943 IM: xmpp:gsalguei@cisco.com 945 Joseph Smarr 946 Google 948 Email: jsmarr@google.com