Skip to main content

The Cache-Status HTTP Response Header Field
draft-ietf-httpbis-cache-header-08

The information below is for an old version of the document.
Document Type
This is an older version of an Internet-Draft that was ultimately published as RFC 9211.
Author Mark Nottingham
Last updated 2021-07-07 (Latest revision 2021-04-20)
Replaces draft-nottingham-cache-header
RFC stream Internet Engineering Task Force (IETF)
Formats
Reviews
Additional resources Mailing list discussion
Stream WG state Submitted to IESG for Publication
Associated WG milestone
Submit Cache-Status Header
Document shepherd Tommy Pauly
Shepherd write-up Show Last changed 2021-04-20
IESG IESG state Became RFC 9211 (Proposed Standard)
Consensus boilerplate Yes
Telechat date (None)
Responsible AD Francesca Palombini
Send notices to tpauly@apple.com
IANA IANA review state IANA OK - Actions Needed
draft-ietf-httpbis-cache-header-08
Network Working Group                                      N. Cam-Winget
Request for Comments: 4851                                     D. McGrew
Category: Informational                                       J. Salowey
                                                                 H. Zhou
                                                           Cisco Systems
                                                                May 2007

           The Flexible Authentication via Secure Tunneling
          Extensible Authentication Protocol Method (EAP-FAST)

Status of This Memo

   This memo provides information for the Internet community.  It does
   not specify an Internet standard of any kind.  Distribution of this
   memo is unlimited.

Copyright Notice

   Copyright (C) The IETF Trust (2007).

Abstract

   This document defines the Extensible Authentication Protocol (EAP)
   based Flexible Authentication via Secure Tunneling (EAP-FAST)
   protocol.  EAP-FAST is an EAP method that enables secure
   communication between a peer and a server by using the Transport
   Layer Security (TLS) to establish a mutually authenticated tunnel.
   Within the tunnel, Type-Length-Value (TLV) objects are used to convey
   authentication related data between the peer and the EAP server.

Cam-Winget, et al.           Informational                      [Page 1]
RFC 4851                        EAP-FAST                        May 2007

Table of Contents

   1.  Introduction . . . . . . . . . . . . . . . . . . . . . . . . .  4
     1.1.  Specification Requirements . . . . . . . . . . . . . . . .  5
     1.2.  Terminology  . . . . . . . . . . . . . . . . . . . . . . .  5
   2.  Protocol Overview  . . . . . . . . . . . . . . . . . . . . . .  6
     2.1.  Architectural Model  . . . . . . . . . . . . . . . . . . .  6
     2.2.  Protocol Layering Model  . . . . . . . . . . . . . . . . .  7
   3.  EAP-FAST Protocol  . . . . . . . . . . . . . . . . . . . . . .  8
     3.1.  Version Negotiation  . . . . . . . . . . . . . . . . . . .  8
     3.2.  EAP-FAST Authentication Phase 1: Tunnel Establishment  . .  9
       3.2.1.  TLS Session Resume Using Server State  . . . . . . . . 10
       3.2.2.  TLS Session Resume Using a PAC . . . . . . . . . . . . 10
       3.2.3.  Transition between Abbreviated and Full TLS
               Handshake  . . . . . . . . . . . . . . . . . . . . . . 12
     3.3.  EAP-FAST Authentication Phase 2: Tunneled
           Authentication . . . . . . . . . . . . . . . . . . . . . . 12
       3.3.1.  EAP Sequences  . . . . . . . . . . . . . . . . . . . . 13
       3.3.2.  Protected Termination and Acknowledged Result
               Indication . . . . . . . . . . . . . . . . . . . . . . 13
     3.4.  Determining Peer-Id and Server-Id  . . . . . . . . . . . . 14
     3.5.  EAP-FAST Session Identifier  . . . . . . . . . . . . . . . 15
     3.6.  Error Handling . . . . . . . . . . . . . . . . . . . . . . 15
       3.6.1.  TLS Layer Errors . . . . . . . . . . . . . . . . . . . 15
       3.6.2.  Phase 2 Errors . . . . . . . . . . . . . . . . . . . . 16
     3.7.  Fragmentation  . . . . . . . . . . . . . . . . . . . . . . 16
   4.  Message Formats  . . . . . . . . . . . . . . . . . . . . . . . 18
     4.1.  EAP-FAST Message Format  . . . . . . . . . . . . . . . . . 18
       4.1.1.  Authority ID Data  . . . . . . . . . . . . . . . . . . 20
     4.2.  EAP-FAST TLV Format and Support  . . . . . . . . . . . . . 20
       4.2.1.  General TLV Format . . . . . . . . . . . . . . . . . . 21
       4.2.2.  Result TLV . . . . . . . . . . . . . . . . . . . . . . 22
       4.2.3.  NAK TLV  . . . . . . . . . . . . . . . . . . . . . . . 23
       4.2.4.  Error TLV  . . . . . . . . . . . . . . . . . . . . . . 24
       4.2.5.  Vendor-Specific TLV  . . . . . . . . . . . . . . . . . 25
       4.2.6.  EAP-Payload TLV  . . . . . . . . . . . . . . . . . . . 26
       4.2.7.  Intermediate-Result TLV  . . . . . . . . . . . . . . . 28
       4.2.8.  Crypto-Binding TLV . . . . . . . . . . . . . . . . . . 29
       4.2.9.  Request-Action TLV . . . . . . . . . . . . . . . . . . 31
     4.3.  Table of TLVs  . . . . . . . . . . . . . . . . . . . . . . 32
   5.  Cryptographic Calculations . . . . . . . . . . . . . . . . . . 32
     5.1.  EAP-FAST Authentication Phase 1: Key Derivations . . . . . 32
     5.2.  Intermediate Compound Key Derivations  . . . . . . . . . . 33
     5.3.  Computing the Compound MAC . . . . . . . . . . . . . . . . 34
     5.4.  EAP Master Session Key Generation  . . . . . . . . . . . . 35
     5.5.  T-PRF  . . . . . . . . . . . . . . . . . . . . . . . . . . 35
   6.  IANA Considerations  . . . . . . . . . . . . . . . . . . . . . 36

Cam-Winget, et al.           Informational                      [Page 2]
RFC 4851                        EAP-FAST                        May 2007

   7.  Security Considerations  . . . . . . . . . . . . . . . . . . . 37
     7.1.  Mutual Authentication and Integrity Protection . . . . . . 37
     7.2.  Method Negotiation . . . . . . . . . . . . . . . . . . . . 38
     7.3.  Separation of Phase 1 and Phase 2 Servers  . . . . . . . . 38
     7.4.  Mitigation of Known Vulnerabilities and Protocol
           Deficiencies . . . . . . . . . . . . . . . . . . . . . . . 39
       7.4.1.  User Identity Protection and Verification  . . . . . . 39
       7.4.2.  Dictionary Attack Resistance . . . . . . . . . . . . . 40
       7.4.3.  Protection against Man-in-the-Middle Attacks . . . . . 40
       7.4.4.  PAC Binding to User Identity . . . . . . . . . . . . . 41
     7.5.  Protecting against Forged Clear Text EAP Packets . . . . . 41
     7.6.  Server Certificate Validation  . . . . . . . . . . . . . . 42
     7.7.  Tunnel PAC Considerations  . . . . . . . . . . . . . . . . 42
     7.8.  Security Claims  . . . . . . . . . . . . . . . . . . . . . 43
   8.  Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . 44
   9.  References . . . . . . . . . . . . . . . . . . . . . . . . . . 44
     9.1.  Normative References . . . . . . . . . . . . . . . . . . . 44
     9.2.  Informative References . . . . . . . . . . . . . . . . . . 45
   Appendix A.  Examples  . . . . . . . . . . . . . . . . . . . . . . 46
     A.1.  Successful Authentication  . . . . . . . . . . . . . . . . 46
     A.2.  Failed Authentication  . . . . . . . . . . . . . . . . . . 47
     A.3.  Full TLS Handshake using Certificate-based Ciphersuite . . 48
     A.4.  Client Authentication during Phase 1 with Identity
           Privacy  . . . . . . . . . . . . . . . . . . . . . . . . . 50
     A.5.  Fragmentation and Reassembly . . . . . . . . . . . . . . . 52
     A.6.  Sequence of EAP Methods  . . . . . . . . . . . . . . . . . 53
     A.7.  Failed Crypto-Binding  . . . . . . . . . . . . . . . . . . 56
     A.8.  Sequence of EAP Method with Vendor-Specific TLV
           Exchange . . . . . . . . . . . . . . . . . . . . . . . . . 57
   Appendix B.  Test Vectors  . . . . . . . . . . . . . . . . . . . . 60
     B.1.  Key Derivation . . . . . . . . . . . . . . . . . . . . . . 60
     B.2.  Crypto-Binding MIC . . . . . . . . . . . . . . . . . . . . 62

Cam-Winget, et al.           Informational                      [Page 3]
RFC 4851                        EAP-FAST                        May 2007

1.  Introduction

   Network access solutions requiring user friendly and easily
   deployable secure authentication mechanisms highlight the need for
   strong mutual authentication protocols that enable the use of weaker
   user credentials.  This document defines an Extensible Authentication
   Protocol (EAP), which consists of establishing a Transport Layer
   Security (TLS) tunnel using TLS 1.0 [RFC2246], TLS 1.1 [RFC4346], or
   a successor version of TLS, using the latest version supported by
   both parties.  Once the tunnel is established, the protocol further
   exchanges data in the form of type, length, and value objects (TLV)
   to perform further authentication.  EAP-FAST supports the TLS
   extension defined in [RFC4507] to support fast re-establishment of
   the secure tunnel without having to maintain per-session state on the
   server.  [EAP-PROV] defines EAP-FAST-based mechanisms to provision
   the credential for this extension which is called a Protected Access
   Credential (PAC).

   EAP-FAST's design motivations included:

   o  Mutual authentication: an EAP server must be able to verify the
      identity and authenticity of the peer, and the peer must be able
      to verify the authenticity of the EAP server.

   o  Immunity to passive dictionary attacks: many authentication
      protocols require a password to be explicitly provided (either as
      cleartext or hashed) by the peer to the EAP server; at minimum,
      the communication of the weak credential (e.g., password) must be
      immune from eavesdropping.

   o  Immunity to man-in-the-middle (MitM) attacks: in establishing a
      mutually authenticated protected tunnel, the protocol must prevent
      adversaries from successfully interjecting information into the
      conversation between the peer and the EAP server.

   o  Flexibility to enable support for most password authentication
      interfaces: as many different password interfaces (e.g., Microsoft
      Challenge Handshake Authentication Protocol (MS-CHAP), Lightweight
      Directory Access Protocol (LDAP), One-Time Password (OTP), etc.)
      exist to authenticate a peer, the protocol must provide this
      support seamlessly.

   o  Efficiency: specifically when using wireless media, peers will be
      limited in computational and power resources.  The protocol must
      enable the network access communication to be computationally
      lightweight.

Cam-Winget, et al.           Informational                      [Page 4]
RFC 4851                        EAP-FAST                        May 2007

   quot;), a
   hostname ("cache-3.example.com"), an IP address, or a generated
   string.

Nottingham               Expires 22 October 2021                [Page 3]
Internet-Draft             Cache-Status Header                April 2021

   Each member of the list can have parameters that describe that
   cache's handling of the request.  While these parameters are
   OPTIONAL, caches are encouraged to provide as much information as
   possible.

   This specification defines the following parameters:

   hit          = sf-boolean
   fwd          = sf-token
   fwd-status   = sf-integer
   ttl          = sf-integer
   stored       = sf-boolean
   collapsed    = sf-boolean
   key          = sf-string
   detail       = sf-token / sf-string

2.1.  The hit parameter

   "hit", when true, indicates that the request was satisfied by the
   cache; i.e., it was not forwarded, and the response was obtained from
   the cache.

   A response that was originally produced by the origin but was
   modified by the cache (for example, a 304 or 206 status code) is
   still considered a hit, as long as it did not go forward (e.g., for
   validation).

   A response that was in cache but not able to be used without going
   forward (e.g., because it was stale, or partial) is not considered a
   hit.  Note that a stale response that is used without going forward
   (e.g., because the origin server is not available) can be considered
   a hit.

   "hit" and "fwd" are exclusive; only one of them should appear on each
   list member.

2.2.  The fwd parameter

   "fwd" indicates that the request went forward towards the origin, and
   why.

   The following parameter values are defined to explain why the request
   went forward, from most specific to least:

   *  bypass - The cache was configured to not handle this request

   *  method - The request method's semantics require the request to be
      forwarded

Nottingham               Expires 22 October 2021                [Page 4]
Internet-Draft             Cache-Status Header                April 2021

   *  uri-miss - The cache did not contain any responses that matched
      the request URI

   *  vary-miss - The cache contained a response that matched the
      request URI, but could not select a response based upon this
      request's headers and stored Vary headers.

   *  miss - The cache did not contain any responses that could be used
      to satisfy this request (to be used when an implementation cannot
      distinguish between uri-miss and vary-miss)

   *  request - The cache was able to select a fresh response for the
      request, but the request's semantics (e.g., Cache-Control request
      directives) did not allow its use

   *  stale - The cache was able to select a response for the request,
      but it was stale

   *  partial - The cache was able to select a partial response for the
      request, but it did not contain all of the requested ranges (or
      the request was for the complete response)

   The most specific reason that the cache is aware of SHOULD be used.

2.3.  The fwd-status parameter

   "fwd-status" indicates what status code the next hop server returned
   in response to the request.  Only meaningful when "fwd" is present;
   if "fwd-status" is not present but "fwd" is, it defaults to the
   status code sent in the response.

   This parameter is useful to distinguish cases when the next hop
   server sends a 304 Not Modified response to a conditional request, or
   a 206 Partial Response because of a range request.

2.4.  The ttl parameter

   "ttl" indicates the response's remaining freshness lifetime as
   calculated by the cache, as an integer number of seconds, measured
   when the response header section is sent by the cache.  This includes
   freshness assigned by the cache; e.g., through heuristics, local
   configuration, or other factors.  May be negative, to indicate
   staleness.

2.5.  The stored parameter

   "stored" indicates whether the cache stored the response; a true
   value indicates that it did.  Only meaningful when fwd is present.

Nottingham               Expires 22 October 2021                [Page 5]
Internet-Draft             Cache-Status Header                April 2021

2.6.  The collapsed parameter

   "collapsed" indicates whether this request was collapsed together
   with one or more other forward requests; if true, the response was
   successfully reused; if not, a new request had to be made.  If not
   present, the request was not collapsed with others.  Only meaningful
   when fwd is present.

2.7.  The key parameter

   "key" conveys a representation of the cache key used for the
   response.  Note that this may be implementation-specific.

2.8.  The detail parameter

   "detail" allows implementations to convey additional information not
   captured in other parameters; for example, implementation-specific
   states, or other caching-related metrics.

   For example:

   Cache-Status: ExampleCache; hit; detail=MEMORY

   The semantics of a detail parameter are always specific to the cache
   that sent it; even if a member of details from another cache shares
   the same name, it might not mean the same thing.

   This parameter is intentionally limited.  If an implementation's
   developer or operator needs to convey additional information in an
   interoperable fashion, they are encouraged to register extension
   parameters (see Section 4) or define another header field.

3.  Examples

   The most minimal cache hit:

   Cache-Status: ExampleCache; hit

   ... but a polite cache will give some more information, e.g.:

   Cache-Status: ExampleCache; hit; ttl=376

   A stale hit just has negative freshness:

   Cache-Status: ExampleCache; hit; ttl=-412

   Whereas a complete miss is:

Nottingham               Expires 22 October 2021                [Page 6]
Internet-Draft             Cache-Status Header                April 2021

   Cache-Status: ExampleCache; fwd=uri-miss

   A miss that successfully validated on the back-end server:

   Cache-Status: ExampleCache; fwd=stale; fwd-status=304

   A miss that was collapsed with another request:

   Cache-Status: ExampleCache; fwd=uri-miss; collapsed

   A miss that the cache attempted to collapse, but couldn't:

   Cache-Status: ExampleCache; fwd=uri-miss; collapsed=?0

   Going through two separate layers of caching, where the cache closest
   to the origin responded to an earlier request with a stored response,
   and a second cache stored that response and later reused it to
   satisfy the current request:

   Cache-Status: OriginCache; hit; ttl=1100,
                 "CDN Company Here"; hit; ttl=545

4.  Defining New Cache-Status Parameters

   New Cache-Status Parameters can be defined by registering them in the
   HTTP Cache-Status Parameters registry.

   Registration requests are reviewed and approved by a Designated
   Expert, as per [RFC8126], Section 4.5.  A specification document is
   appreciated, but not required.

   The Expert(s) should consider the following factors when evaluating
   requests:

   *  Community feedback

   *  If the value is sufficiently well-defined

   *  Generic parameters are preferred over vendor-specific,
      application-specific, or deployment-specific values.  If a generic
      value cannot be agreed upon in the community, the parameter's name
      should be correspondingly specific (e.g., with a prefix that
      identifies the vendor, application or deployment).

   Registration requests should use the following template:

   *  Name: [a name for the Cache-Status Parameter that matches key]

Nottingham               Expires 22 October 2021                [Page 7]
Internet-Draft             Cache-Status Header                April 2021

   *  Description: [a description of the parameter semantics and value]

   *  Reference: [to a specification defining this parameter]

   See the registry at https://iana.org/assignments/http-cache-status
   (https://iana.org/assignments/http-cache-status) for details on where
   to send registration requests.

5.  IANA Considerations

   Upon publication, please create the HTTP Cache-Status Parameters
   registry at https://iana.org/assignments/http-cache-status
   (https://iana.org/assignments/http-cache-status) and populate it with
   the types defined in Section 2; see Section 4 for its associated
   procedures.

6.  Security Considerations

   Attackers can use the information in Cache-Status to probe the
   behaviour of the cache (and other components), and infer the activity
   of those using the cache.  The Cache-Status header field may not
   create these risks on its own, but can assist attackers in exploiting
   them.

   For example, knowing if a cache has stored a response can help an
   attacker execute a timing attack on sensitive data.  Exposing the
   cache key can help an attacker understand modifications to the cache
   key, which may assist cache poisoning attacks.  See [ENTANGLE] for
   details.

   The underlying risks can be mitigated with a variety of techniques
   (e.g., use of encryption and authentication; avoiding the inclusion
   of attacker-controlled data in the cache key), depending on their
   exact nature.

   To avoid assisting such attacks, the Cache-Status header field can be
   omitted, only sent when the client is authorized to receive it, or
   only send sensitive information (e.g., the key parameter) when the
   client is authorized.

7.  References

7.1.  Normative References

   [RFC2119]  Bradner, S., "Key words for use in RFCs to Indicate
              Requirement Levels", BCP 14, RFC 2119,
              DOI 10.17487/RFC2119, March 1997,
              <https://www.rfc-editor.org/rfc/rfc2119>.

Nottingham               Expires 22 October 2021                [Page 8]
Internet-Draft             Cache-Status Header                April 2021

   [RFC8126]  Cotton, M., Leiba, B., and T. Narten, "Guidelines for
              Writing an IANA Considerations Section in RFCs", BCP 26,
              RFC 8126, DOI 10.17487/RFC8126, June 2017,
              <https://www.rfc-editor.org/rfc/rfc8126>.

   [RFC8941]  Nottingham, M. and P-H. Kamp, "Structured Field Values for
              HTTP", RFC 8941, DOI 10.17487/RFC8941, February 2021,
              <https://www.rfc-editor.org/rfc/rfc8941>.

   [RFC8174]  Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC
              2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174,
              May 2017, <https://www.rfc-editor.org/rfc/rfc8174>.

   [RFC5234]  Crocker, D., Ed. and P. Overell, "Augmented BNF for Syntax
              Specifications: ABNF", STD 68, RFC 5234,
              DOI 10.17487/RFC5234, January 2008,
              <https://www.rfc-editor.org/rfc/rfc5234>.

7.2.  Informative References

   [ENTANGLE] Kettle, J., "Web Cache Entanglement: Novel Pathways to
              Poisoning", 2020, <https://i.blackhat.com/USA-
              20/Wednesday/us-20-Kettle-Web-Cache-Entanglement-Novel-
              Pathways-To-Poisoning-wp.pdf>.

Author's Address

   Mark Nottingham
   Fastly
   Prahran VIC
   Australia

   Email: mnot@mnot.net
   URI:   https://www.mnot.net/

Nottingham               Expires 22 October 2021                [Page 9]