Hear from Slack, the ACLU, TED, & more at our customer summit in San Francisco Register
LOG IN SIGN UP
Documentation

TLS and HTTP/2 VCL variables and functions

  Last updated June 05, 2017

Fastly has added several variables that expose information about the TLS and HTTP/2 attributes of a request. When using these variables, remember the following:

Feature Description
fastly_info.is_h2 Whether or not the request was made using HTTP/2. Returns a boolean value.
fastly_info.h2.is_push If the request was made over HTTP/2, whether or not the request is part of a push request. Returns a boolean value.
fastly_info.h2.stream_id If the request was made over HTTP/2, the underlying HTTP/2 stream ID.
h2.push(<string>) Triggers an HTTP/2 server push of the asset passed into the function as the input-string.
tls.client.protocol The TLS protocol version this connection is speaking over. Example: "TLSv1.2"
tls.client.servername The Server Name Indication (SNI) the client sent in the ClientHello TLS record. Returns "" if the client did not send SNI. Returns NULL (the undefined string) if the request is not a TLS request.
tls.client.cipher The cipher suite used to secure the client TLS connection. Example: "ECDHE-RSA-AES128-GCM-SHA256"
tls.client.ciphers_sha A SHA1 of the cipher suite identifiers sent from the client as part of the TLS handshake, represented in base64.
tls.client.tlsexts_sha A SHA1 of the TLS extension identifiers sent from the client as part of the TLS handshake, represented in base64.

Back to Top