Skip to main content

Authorize Log Fields

Summary​

The Authorize Log Fields setting controls which fields will be included in the authorize logs. For each incoming request, the authorize service will emit a log entry with the message authorize check containing the policy evaluation result and these additional log fields.

The default log fields should be appropriate for most deployments.

How to configure​

Config File KeyEnvironment VariableTypeDefault
authorize_log_fieldsAUTHORIZE_LOG_FIELDSArray of stringSee Authorize Fields and Defaults

Examples​

authorize_log_fields:
- request-id
- path
- ip
AUTHORIZE_LOG_FIELDS=request-id,path,ip

Headers examples:

# List all HTTP headers
authorize_log_fields:
- headers
AUTHORIZE_LOG_FIELDS=headers
# List custom HTTP headers
authorize_log_fields:
- headers.cookie
- headers.content-type
AUTHORIZE_LOG_FIELDS=headers.cookie,headers.content-type

The authorize_log_fields setting can also be configured by Terraform.

Authorize log fields and defaults​

The table below lists all available authorize log fields:

Field nameDescriptionDefault field
bodyThe HTTP request body. Only available for protocols with request content inspection such as MCP.No
check-request-idThe request ID of the gRPC check callYes
cluster-stat-nameThe stat name of the upstream cluster the request was routed to (set via route name, route id, or the Enterprise Console Metric Name field)No
emailThe logged-in user's email addressYes
envoy-route-checksumThe checksum of the Envoy route configuration used to match the requestYes
envoy-route-idThe ID of the Envoy route that matched the requestYes
headersThe complete set of HTTP request headersNo
headers.{CustomHeaderName}An HTTP Request Header identified by the HeaderNameNo
hostThe HTTP request :authority or Host header value. Can be a domain name or IP address and may contain a port number (for example, www.example.com)