Available on crate feature
gateway-api only.Expand description
Listener filters (Gateway API v1.7, experimental, GEP-5224): a listener’s
filters.requests run in order on every HTTP request, before a route is
picked. rws supports ExternalAuth:
- HTTP: the request’s method and path (after
http.path, the prefix) go to the authorization server withHost,Authorization,Content-Lengthand theallowedHeaders, and the body up toforwardBody.maxSize.200allows the request, which gets the server’s response headers (allowedResponseHeaders, else all butHost/:authorityand framing); any other status is the answer. - GRPC: Envoy’s
ext_authz(envoy.service.auth.v3.Authorization/Check) over HTTP/2 — the request’s attributes (method, path, host, scheme, headers, body) in aCheckRequest; statusOKallows it (with theok_response’s header changes), anything else answers with thedenied_response(403by default).
A request an authorization server denies goes no further; changes to
Host/:authority are ignored (the listener was already chosen). An
authorization server that can’t be reached denies with 403: the
filter fails closed.
Modules§
- proto
- The few protobuf messages of Envoy’s
ext_authzAPI rws needs (envoy.service.auth.v3,envoy.config.core.v3,google.rpc.Status), encoded and decoded by hand: aCheckRequestwith the HTTP request’s attributes, and the parts of aCheckResponsethat decide.
Structs§
- Compiled
Auth - One
ExternalAuthfilter, its server resolved.
Enums§
- Decision
- What an authorization server decided.
Functions§
- check
- Ask one authorization server.
- grpc_
decision - A
CheckResponseas a decision. - http_
decision - An HTTP authorization server’s answer as a decision.
- http_
request - The HTTP authorization request for
request. - run
- Run
filtersin order onrequest: the request as they left it (None: unchanged), or the answer when one denies it.