idnits 2.17.1 draft-pauly-httpbis-geoip-hint-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 : ---------------------------------------------------------------------------- ** There is 1 instance of too long lines in the document, the longest one being 12 characters in excess of 72. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year == Using lowercase 'not' together with uppercase 'MUST', 'SHALL', 'SHOULD', or 'RECOMMENDED' is not an accepted usage according to RFC 2119. Please use uppercase 'NOT' together with RFC 2119 keywords (if that is what you mean). Found 'MUST not' in this paragraph: The value contained in this hint SHOULD be based only on a IP Geolocation feed value for an IP address the client is already presenting to a server. In order to avoid disclosing any private information, this value MUST not be based on geolocation of the client determined by other means, such as physical latitude and longitude coordinates. -- The document date (30 March 2022) is 755 days in the past. Is this intentional? Checking references for intended status: Experimental ---------------------------------------------------------------------------- No issues found here. Summary: 1 error (**), 0 flaws (~~), 2 warnings (==), 1 comment (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group T. Pauly 3 Internet-Draft Apple Inc. 4 Intended status: Experimental D. Schinazi 5 Expires: 1 October 2022 Google LLC 6 30 March 2022 8 The IP Geolocation HTTP Client Hint 9 draft-pauly-httpbis-geoip-hint-00 11 Abstract 13 This documents defines an HTTP Client Hint that allows a client to 14 share information about its IP Geolocation. This helps ensure that 15 servers have information about location that is consistent with what 16 a client expects and what other servers use. 18 Discussion Venues 20 This note is to be removed before publishing as an RFC. 22 Source for this draft and an issue tracker can be found at 23 https://github.com/tfpauly/privacy-proxy. 25 Status of This Memo 27 This Internet-Draft is submitted in full conformance with the 28 provisions of BCP 78 and BCP 79. 30 Internet-Drafts are working documents of the Internet Engineering 31 Task Force (IETF). Note that other groups may also distribute 32 working documents as Internet-Drafts. The list of current Internet- 33 Drafts is at https://datatracker.ietf.org/drafts/current/. 35 Internet-Drafts are draft documents valid for a maximum of six months 36 and may be updated, replaced, or obsoleted by other documents at any 37 time. It is inappropriate to use Internet-Drafts as reference 38 material or to cite them other than as "work in progress." 40 This Internet-Draft will expire on 1 October 2022. 42 Copyright Notice 44 Copyright (c) 2022 IETF Trust and the persons identified as the 45 document authors. All rights reserved. 47 This document is subject to BCP 78 and the IETF Trust's Legal 48 Provisions Relating to IETF Documents (https://trustee.ietf.org/ 49 license-info) in effect on the date of publication of this document. 50 Please review these documents carefully, as they describe your rights 51 and restrictions with respect to this document. Code Components 52 extracted from this document must include Revised BSD License text as 53 described in Section 4.e of the Trust Legal Provisions and are 54 provided without warranty as described in the Revised BSD License. 56 Table of Contents 58 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 59 1.1. Requirements . . . . . . . . . . . . . . . . . . . . . . 3 60 2. IP Geo Header . . . . . . . . . . . . . . . . . . . . . . . . 3 61 3. Server Behavior . . . . . . . . . . . . . . . . . . . . . . . 3 62 4. Security Considerations . . . . . . . . . . . . . . . . . . . 4 63 5. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 4 64 5.1. HTTP Headers . . . . . . . . . . . . . . . . . . . . . . 5 65 6. References . . . . . . . . . . . . . . . . . . . . . . . . . 5 66 6.1. Normative References . . . . . . . . . . . . . . . . . . 5 67 6.2. Informative References . . . . . . . . . . . . . . . . . 5 68 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 6 70 1. Introduction 72 HTTP Client Hints [RFC8942] defines a convention for HTTP headers to 73 communicate optional information from clients to servers as hints. 74 This can be done conditionally based on if a server claims supports 75 for a particular hint. 77 This document defines a client hint that can be used to send a IP 78 geolocation entry that maps to the client's IP address. This 79 location can be used to influence server behavior, such as by causing 80 the server to return responses relevant to the client's location. 81 The format of the IP geolocation entry is the same as that defined 82 for IP geolocation feeds in [GEOFEED]. 84 This header is intended to be used to provide rough geolocation hints 85 to servers that do not already have accurate or authoritative 86 mappings for the IP addresses of clients. This can be particularly 87 useful for cases where IP geolocation mappings have changed recently, 88 or a client is using a VPN or proxy that may not be commonly 89 recognized by servers. 91 The mechanism for how a client learns the IP geolocation mapping to 92 send is beyond the scope of this document. [RFC9092] defines some 93 mechanisms for discovery, but clients can also have other mechanisms 94 (such as coordinating with a VPN or proxy that is assigning the 95 client a tunnelled or proxied address) to learn what hint to sent. 97 1.1. Requirements 99 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 100 "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and 101 "OPTIONAL" in this document are to be interpreted as described in 102 BCP 14 [RFC2119] [RFC8174] when, and only when, they appear in all 103 capitals, as shown here. 105 2. IP Geo Header 107 The "Sec-CH-IP-Geo" is an Item Structured Field [STRUCTURED-FIELDS]. 108 The field's value is a String. The string uses the format defined in 109 Section 2.1.1 of [GEOFEED], with the IP Prefix element removed. 110 Thus, this contains a comma-separated list of Alpha2code, Region, and 111 City. The value SHOULD NOT contain a Postal Code. 113 For example, the header for an entry "192.0.2.5,US,US-AL,Alabaster" 114 would be: 116 Sec-CH-IP-Geo = "US,US-AL,Alabaster" 118 This field also defines a parameter, "feed", that contains the URI of 119 the IP geolocation feed that is authoritative for this entry. For 120 example: 122 Sec-CH-IP-Geo = "SG,SG-01,Singapore"; feed="https://noc.ietf.org/geo/google.csv" 124 Servers that can provide different content based on Geohash hints 125 SHOULD include the headers in their "Accept-CH" list. 127 Accept-CH: Sec-CH-IP-Geo 129 Servers also SHOULD indicate for any cacheable content if the IP geo 130 hints will influence the cached content, using the "Vary" header. 132 Vary: Sec-CH-IP-Geo 134 3. Server Behavior 136 Upon receiving a IP Geolocation Client Hint, a server can use the 137 information to influence its behavior in various ways, such as 138 determining the content of HTTP responses. 140 Many servers have existing IP geolocation feeds that they use to 141 identify client locations. Servers can choose to use the hint value 142 in one of several ways: 144 * Use the client hint information instead of consulting another 145 geolocation feed. 147 * Check the value of the "feed" parameter on the header and 148 determine if it is a trusted feed. If this feed is trusted, but 149 is not the default feed used by the server, the server can choose 150 to prefer the feed indicated by the client. 152 * Check the value of the "feed" parameter on the header and fetch a 153 copy of the feed to verify the mapping, if a copy of the feed has 154 not been fetched recently. 156 * If the feed indicated in the "feed" parameter is unknown or 157 untrusted, but starts becoming common, the server can flag this 158 feed as one to be manually checked and added, if appropriate. 159 This allows servers to automatically discover when new feeds and 160 services are brought up.. 162 If the server is acting as a forward proxy, such as a CONNECT proxy, 163 it can use the hint to determine an appropriate geo-mapped IP address 164 to use for outbound connections, or a client subnet to present in the 165 EDNS0 Client Subnet extension for DNS queries [RFC6891] [RFC7871]. 167 4. Security Considerations 169 The use of the IP Geolocation Client Hint MUST use the Sec- header 170 prefix as recommended in [RFC8942]. 172 Servers MUST NOT use IP Geolocation Client Hints for making security 173 or access-control decisions, as the value can be spoofed by a client. 174 The hint is intended only for use in optimizing behavior. 176 The value contained in this hint SHOULD be based only on a IP 177 Geolocation feed value for an IP address the client is already 178 presenting to a server. In order to avoid disclosing any private 179 information, this value MUST not be based on geolocation of the 180 client determined by other means, such as physical latitude and 181 longitude coordinates. 183 5. IANA Considerations 184 5.1. HTTP Headers 186 This document registers the "Sec-CH-IP-Geo" header in the "Permanent 187 Message Header Field Names" registry 188 . 190 +----------------------+----------+--------+---------------+ 191 | Header Field Name | Protocol | Status | Reference | 192 +----------------------+----------+--------+---------------+ 193 | Sec-CH-IP-Geo | http | exp | This document | 194 +----------------------+----------+--------+---------------+ 196 6. References 198 6.1. Normative References 200 [GEOFEED] Kline, E., Duleba, K., Szamonek, Z., Moser, S., and W. 201 Kumari, "A Format for Self-Published IP Geolocation 202 Feeds", RFC 8805, DOI 10.17487/RFC8805, August 2020, 203 . 205 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 206 Requirement Levels", BCP 14, RFC 2119, 207 DOI 10.17487/RFC2119, March 1997, 208 . 210 [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 211 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, 212 May 2017, . 214 [RFC8942] Grigorik, I. and Y. Weiss, "HTTP Client Hints", RFC 8942, 215 DOI 10.17487/RFC8942, February 2021, 216 . 218 [STRUCTURED-FIELDS] 219 Nottingham, M. and P-H. Kamp, "Structured Field Values for 220 HTTP", RFC 8941, DOI 10.17487/RFC8941, February 2021, 221 . 223 6.2. Informative References 225 [RFC6891] Damas, J., Graff, M., and P. Vixie, "Extension Mechanisms 226 for DNS (EDNS(0))", STD 75, RFC 6891, 227 DOI 10.17487/RFC6891, April 2013, 228 . 230 [RFC7871] Contavalli, C., van der Gaast, W., Lawrence, D., and W. 231 Kumari, "Client Subnet in DNS Queries", RFC 7871, 232 DOI 10.17487/RFC7871, May 2016, 233 . 235 [RFC9092] Bush, R., Candela, M., Kumari, W., and R. Housley, 236 "Finding and Using Geofeed Data", RFC 9092, 237 DOI 10.17487/RFC9092, July 2021, 238 . 240 Authors' Addresses 242 Tommy Pauly 243 Apple Inc. 244 One Apple Park Way 245 Cupertino, California 95014, 246 United States of America 247 Email: tpauly@apple.com 249 David Schinazi 250 Google LLC 251 Email: dschinazi.ietf@gmail.com