Documentation ¶
Index ¶
- Variables
- type HeaderMutation
- func (*HeaderMutation) Descriptor() ([]byte, []int)deprecated
- func (m *HeaderMutation) GetAction() isHeaderMutation_Action
- func (x *HeaderMutation) GetAppend() *v31.HeaderValueOption
- func (x *HeaderMutation) GetRemove() string
- func (*HeaderMutation) ProtoMessage()
- func (x *HeaderMutation) ProtoReflect() protoreflect.Message
- func (x *HeaderMutation) Reset()
- func (x *HeaderMutation) String() string
- func (m *HeaderMutation) Validate() error
- func (m *HeaderMutation) ValidateAll() error
- type HeaderMutationMultiError
- type HeaderMutationRules
- func (*HeaderMutationRules) Descriptor() ([]byte, []int)deprecated
- func (x *HeaderMutationRules) GetAllowAllRouting() *wrapperspb.BoolValue
- func (x *HeaderMutationRules) GetAllowEnvoy() *wrapperspb.BoolValue
- func (x *HeaderMutationRules) GetAllowExpression() *v3.RegexMatcher
- func (x *HeaderMutationRules) GetDisallowAll() *wrapperspb.BoolValue
- func (x *HeaderMutationRules) GetDisallowExpression() *v3.RegexMatcher
- func (x *HeaderMutationRules) GetDisallowIsError() *wrapperspb.BoolValue
- func (x *HeaderMutationRules) GetDisallowSystem() *wrapperspb.BoolValue
- func (*HeaderMutationRules) ProtoMessage()
- func (x *HeaderMutationRules) ProtoReflect() protoreflect.Message
- func (x *HeaderMutationRules) Reset()
- func (x *HeaderMutationRules) String() string
- func (m *HeaderMutationRules) Validate() error
- func (m *HeaderMutationRules) ValidateAll() error
- type HeaderMutationRulesMultiError
- type HeaderMutationRulesValidationError
- func (e HeaderMutationRulesValidationError) Cause() error
- func (e HeaderMutationRulesValidationError) Error() string
- func (e HeaderMutationRulesValidationError) ErrorName() string
- func (e HeaderMutationRulesValidationError) Field() string
- func (e HeaderMutationRulesValidationError) Key() bool
- func (e HeaderMutationRulesValidationError) Reason() string
- type HeaderMutationValidationError
- func (e HeaderMutationValidationError) Cause() error
- func (e HeaderMutationValidationError) Error() string
- func (e HeaderMutationValidationError) ErrorName() string
- func (e HeaderMutationValidationError) Field() string
- func (e HeaderMutationValidationError) Key() bool
- func (e HeaderMutationValidationError) Reason() string
- type HeaderMutation_Append
- type HeaderMutation_Remove
Constants ¶
This section is empty.
Variables ¶
var File_envoy_config_common_mutation_rules_v3_mutation_rules_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type HeaderMutation ¶ added in v0.11.0
type HeaderMutation struct { // Types that are assignable to Action: // // *HeaderMutation_Remove // *HeaderMutation_Append Action isHeaderMutation_Action `protobuf_oneof:"action"` // contains filtered or unexported fields }
The HeaderMutation structure specifies an action that may be taken on HTTP headers.
func (*HeaderMutation) Descriptor
deprecated
added in
v0.11.0
func (*HeaderMutation) Descriptor() ([]byte, []int)
Deprecated: Use HeaderMutation.ProtoReflect.Descriptor instead.
func (*HeaderMutation) GetAction ¶ added in v0.11.0
func (m *HeaderMutation) GetAction() isHeaderMutation_Action
func (*HeaderMutation) GetAppend ¶ added in v0.11.0
func (x *HeaderMutation) GetAppend() *v31.HeaderValueOption
func (*HeaderMutation) GetRemove ¶ added in v0.11.0
func (x *HeaderMutation) GetRemove() string
func (*HeaderMutation) ProtoMessage ¶ added in v0.11.0
func (*HeaderMutation) ProtoMessage()
func (*HeaderMutation) ProtoReflect ¶ added in v0.11.0
func (x *HeaderMutation) ProtoReflect() protoreflect.Message
func (*HeaderMutation) Reset ¶ added in v0.11.0
func (x *HeaderMutation) Reset()
func (*HeaderMutation) String ¶ added in v0.11.0
func (x *HeaderMutation) String() string
func (*HeaderMutation) Validate ¶ added in v0.11.0
func (m *HeaderMutation) Validate() error
Validate checks the field values on HeaderMutation with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.
func (*HeaderMutation) ValidateAll ¶ added in v0.11.0
func (m *HeaderMutation) ValidateAll() error
ValidateAll checks the field values on HeaderMutation with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in HeaderMutationMultiError, or nil if none found.
type HeaderMutationMultiError ¶ added in v0.11.0
type HeaderMutationMultiError []error
HeaderMutationMultiError is an error wrapping multiple validation errors returned by HeaderMutation.ValidateAll() if the designated constraints aren't met.
func (HeaderMutationMultiError) AllErrors ¶ added in v0.11.0
func (m HeaderMutationMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (HeaderMutationMultiError) Error ¶ added in v0.11.0
func (m HeaderMutationMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type HeaderMutationRules ¶
type HeaderMutationRules struct { // By default, certain headers that could affect processing of subsequent // filters or request routing cannot be modified. These headers are // “host“, “:authority“, “:scheme“, and “:method“. Setting this parameter // to true allows these headers to be modified as well. AllowAllRouting *wrapperspb.BoolValue `protobuf:"bytes,1,opt,name=allow_all_routing,json=allowAllRouting,proto3" json:"allow_all_routing,omitempty"` // If true, allow modification of envoy internal headers. By default, these // start with “x-envoy“ but this may be overridden in the “Bootstrap“ // configuration using the // :ref:`header_prefix <envoy_v3_api_field_config.bootstrap.v3.Bootstrap.header_prefix>` // field. Default is false. AllowEnvoy *wrapperspb.BoolValue `protobuf:"bytes,2,opt,name=allow_envoy,json=allowEnvoy,proto3" json:"allow_envoy,omitempty"` // If true, prevent modification of any system header, defined as a header // that starts with a “:“ character, regardless of any other settings. // A processing server may still override the “:status“ of an HTTP response // using an “ImmediateResponse“ message. Default is false. DisallowSystem *wrapperspb.BoolValue `protobuf:"bytes,3,opt,name=disallow_system,json=disallowSystem,proto3" json:"disallow_system,omitempty"` // If true, prevent modifications of all header values, regardless of any // other settings. A processing server may still override the “:status“ // of an HTTP response using an “ImmediateResponse“ message. Default is false. DisallowAll *wrapperspb.BoolValue `protobuf:"bytes,4,opt,name=disallow_all,json=disallowAll,proto3" json:"disallow_all,omitempty"` // If set, specifically allow any header that matches this regular // expression. This overrides all other settings except for // “disallow_expression“. AllowExpression *v3.RegexMatcher `protobuf:"bytes,5,opt,name=allow_expression,json=allowExpression,proto3" json:"allow_expression,omitempty"` // If set, specifically disallow any header that matches this regular // expression regardless of any other settings. DisallowExpression *v3.RegexMatcher `protobuf:"bytes,6,opt,name=disallow_expression,json=disallowExpression,proto3" json:"disallow_expression,omitempty"` // If true, and if the rules in this list cause a header mutation to be // disallowed, then the filter using this configuration will terminate the // request with a 500 error. In addition, regardless of the setting of this // parameter, any attempt to set, add, or modify a disallowed header will // cause the “rejected_header_mutations“ counter to be incremented. // Default is false. DisallowIsError *wrapperspb.BoolValue `protobuf:"bytes,7,opt,name=disallow_is_error,json=disallowIsError,proto3" json:"disallow_is_error,omitempty"` // contains filtered or unexported fields }
The HeaderMutationRules structure specifies what headers may be manipulated by a processing filter. This set of rules makes it possible to control which modifications a filter may make.
By default, an external processing server may add, modify, or remove any header except for an "Envoy internal" header (which is typically denoted by an x-envoy prefix) or specific headers that may affect further filter processing:
* “host“ * “:authority“ * “:scheme“ * “:method“
Every attempt to add, change, append, or remove a header will be tested against the rules here. Disallowed header mutations will be ignored unless “disallow_is_error“ is set to true.
Attempts to remove headers are further constrained -- regardless of the settings, system-defined headers (that start with “:“) and the “host“ header may never be removed.
In addition, a counter will be incremented whenever a mutation is rejected. In the ext_proc filter, that counter is named “rejected_header_mutations“. [#next-free-field: 8]
func (*HeaderMutationRules) Descriptor
deprecated
func (*HeaderMutationRules) Descriptor() ([]byte, []int)
Deprecated: Use HeaderMutationRules.ProtoReflect.Descriptor instead.
func (*HeaderMutationRules) GetAllowAllRouting ¶
func (x *HeaderMutationRules) GetAllowAllRouting() *wrapperspb.BoolValue
func (*HeaderMutationRules) GetAllowEnvoy ¶
func (x *HeaderMutationRules) GetAllowEnvoy() *wrapperspb.BoolValue
func (*HeaderMutationRules) GetAllowExpression ¶
func (x *HeaderMutationRules) GetAllowExpression() *v3.RegexMatcher
func (*HeaderMutationRules) GetDisallowAll ¶
func (x *HeaderMutationRules) GetDisallowAll() *wrapperspb.BoolValue
func (*HeaderMutationRules) GetDisallowExpression ¶
func (x *HeaderMutationRules) GetDisallowExpression() *v3.RegexMatcher
func (*HeaderMutationRules) GetDisallowIsError ¶
func (x *HeaderMutationRules) GetDisallowIsError() *wrapperspb.BoolValue
func (*HeaderMutationRules) GetDisallowSystem ¶
func (x *HeaderMutationRules) GetDisallowSystem() *wrapperspb.BoolValue
func (*HeaderMutationRules) ProtoMessage ¶
func (*HeaderMutationRules) ProtoMessage()
func (*HeaderMutationRules) ProtoReflect ¶
func (x *HeaderMutationRules) ProtoReflect() protoreflect.Message
func (*HeaderMutationRules) Reset ¶
func (x *HeaderMutationRules) Reset()
func (*HeaderMutationRules) String ¶
func (x *HeaderMutationRules) String() string
func (*HeaderMutationRules) Validate ¶
func (m *HeaderMutationRules) Validate() error
Validate checks the field values on HeaderMutationRules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.
func (*HeaderMutationRules) ValidateAll ¶
func (m *HeaderMutationRules) ValidateAll() error
ValidateAll checks the field values on HeaderMutationRules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in HeaderMutationRulesMultiError, or nil if none found.
type HeaderMutationRulesMultiError ¶
type HeaderMutationRulesMultiError []error
HeaderMutationRulesMultiError is an error wrapping multiple validation errors returned by HeaderMutationRules.ValidateAll() if the designated constraints aren't met.
func (HeaderMutationRulesMultiError) AllErrors ¶
func (m HeaderMutationRulesMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (HeaderMutationRulesMultiError) Error ¶
func (m HeaderMutationRulesMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type HeaderMutationRulesValidationError ¶
type HeaderMutationRulesValidationError struct {
// contains filtered or unexported fields
}
HeaderMutationRulesValidationError is the validation error returned by HeaderMutationRules.Validate if the designated constraints aren't met.
func (HeaderMutationRulesValidationError) Cause ¶
func (e HeaderMutationRulesValidationError) Cause() error
Cause function returns cause value.
func (HeaderMutationRulesValidationError) Error ¶
func (e HeaderMutationRulesValidationError) Error() string
Error satisfies the builtin error interface
func (HeaderMutationRulesValidationError) ErrorName ¶
func (e HeaderMutationRulesValidationError) ErrorName() string
ErrorName returns error name.
func (HeaderMutationRulesValidationError) Field ¶
func (e HeaderMutationRulesValidationError) Field() string
Field function returns field value.
func (HeaderMutationRulesValidationError) Key ¶
func (e HeaderMutationRulesValidationError) Key() bool
Key function returns key value.
func (HeaderMutationRulesValidationError) Reason ¶
func (e HeaderMutationRulesValidationError) Reason() string
Reason function returns reason value.
type HeaderMutationValidationError ¶ added in v0.11.0
type HeaderMutationValidationError struct {
// contains filtered or unexported fields
}
HeaderMutationValidationError is the validation error returned by HeaderMutation.Validate if the designated constraints aren't met.
func (HeaderMutationValidationError) Cause ¶ added in v0.11.0
func (e HeaderMutationValidationError) Cause() error
Cause function returns cause value.
func (HeaderMutationValidationError) Error ¶ added in v0.11.0
func (e HeaderMutationValidationError) Error() string
Error satisfies the builtin error interface
func (HeaderMutationValidationError) ErrorName ¶ added in v0.11.0
func (e HeaderMutationValidationError) ErrorName() string
ErrorName returns error name.
func (HeaderMutationValidationError) Field ¶ added in v0.11.0
func (e HeaderMutationValidationError) Field() string
Field function returns field value.
func (HeaderMutationValidationError) Key ¶ added in v0.11.0
func (e HeaderMutationValidationError) Key() bool
Key function returns key value.
func (HeaderMutationValidationError) Reason ¶ added in v0.11.0
func (e HeaderMutationValidationError) Reason() string
Reason function returns reason value.
type HeaderMutation_Append ¶ added in v0.11.0
type HeaderMutation_Append struct { // Append new header by the specified HeaderValueOption. Append *v31.HeaderValueOption `protobuf:"bytes,2,opt,name=append,proto3,oneof"` }
type HeaderMutation_Remove ¶ added in v0.11.0
type HeaderMutation_Remove struct { // Remove the specified header if it exists. Remove string `protobuf:"bytes,1,opt,name=remove,proto3,oneof"` }