From 656e45488c44200542f1009499231b461527e47b Mon Sep 17 00:00:00 2001 From: "data-plane-api(Azure Pipelines)" Date: Mon, 5 Apr 2021 16:42:06 +0000 Subject: [PATCH] matching: initial support for match tree validation (#15709) Adds some basic structure for validating match tree constructions, only with support for validating the data input. Updates the HTTP filter factory to be able to specify data input requirements and wires it up. Signed-off-by: Snow Pettersen Mirrored from https://github.com/envoyproxy/envoy @ afb751344c93f6eb02ea1bd1630a282c55c7aef2 --- .../filters/common/dependency/v3/dependency.proto | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/envoy/extensions/filters/common/dependency/v3/dependency.proto b/envoy/extensions/filters/common/dependency/v3/dependency.proto index 11893792..9dce610a 100644 --- a/envoy/extensions/filters/common/dependency/v3/dependency.proto +++ b/envoy/extensions/filters/common/dependency/v3/dependency.proto @@ -42,3 +42,18 @@ message FilterDependencies { // A list of dependencies provided on the encode path. repeated Dependency encode_provided = 4; } + +// Matching requirements for a filter. For a match tree to be used with a filter, the match +// requirements must be satisfied. +// +// This protobuf is provided by the filter implementation as a way to communicate the matching +// requirements to the filter factories, allowing for config rejection if the requirements are +// not satisfied. +message MatchingRequirements { + message DataInputAllowList { + // An explicit list of data inputs that are allowed to be used with this filter. + repeated string type_url = 1; + } + + DataInputAllowList data_input_allow_list = 1; +}