cors: allow using regexes to match origins (#3769)

Resolves https://github.com/envoyproxy/envoy/issues/2526

Signed-off-by: Neri Marschik <codesuki@users.noreply.github.com>

Mirrored from https://github.com/envoyproxy/envoy @ 00bb039a78f66b7cd42acedd9b2d3dc52bfb605d
pull/620/head
data-plane-api(CircleCI) 6 years ago
parent 5d8712556c
commit 09d2c4a4ea
  1. 8
      envoy/api/v2/route/route.proto

@ -282,10 +282,18 @@ message RouteMatch {
repeated QueryParameterMatcher query_parameters = 7;
}
// [#comment:next free field: 9]
message CorsPolicy {
// Specifies the origins that will be allowed to do CORS requests.
//
// An origin is allowed if either allow_origin or allow_origin_regex match.
repeated string allow_origin = 1;
// Specifies regex patterns that match allowed origins.
//
// An origin is allowed if either allow_origin or allow_origin_regex match.
repeated string allow_origin_regex = 8;
// Specifies the content for the *access-control-allow-methods* header.
string allow_methods = 2;

Loading…
Cancel
Save