Class HeaderValidatorConfig
- java.lang.Object
-
- com.google.protobuf.AbstractMessageLite
-
- com.google.protobuf.AbstractMessage
-
- com.google.protobuf.GeneratedMessageV3
-
- io.envoyproxy.envoy.extensions.http.header_validators.envoy_default.v3.HeaderValidatorConfig
-
- All Implemented Interfaces:
com.google.protobuf.Message,com.google.protobuf.MessageLite,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,HeaderValidatorConfigOrBuilder,Serializable
public final class HeaderValidatorConfig extends com.google.protobuf.GeneratedMessageV3 implements HeaderValidatorConfigOrBuilder
This extension validates that HTTP request and response headers are well formed according to respective RFCs. #. HTTP/1 header map validity according to `RFC 7230 section 3.2 <https://datatracker.ietf.org/doc/html/rfc7230#section-3.2>`_ #. Syntax of HTTP/1 request target URI and response status #. HTTP/2 header map validity according to `RFC 7540 section 8.1.2 <https://datatracker.ietf.org/doc/html/rfc7540#section-8.1.2>`_ #. Syntax of HTTP/2 pseudo headers #. HTTP/3 header map validity according to `RFC 9114 section 4.3 <https://www.rfc-editor.org/rfc/rfc9114.html>`_ #. Syntax of HTTP/3 pseudo headers #. Syntax of Content-Length and Transfer-Encoding #. Validation of HTTP/1 requests with both ``Content-Length`` and ``Transfer-Encoding`` headers #. Normalization of the URI path according to `Normalization and Comparison <https://datatracker.ietf.org/doc/html/rfc3986#section-6>`_ without `case normalization <https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2.1>`_Protobuf typeenvoy.extensions.http.header_validators.envoy_default.v3.HeaderValidatorConfig- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classHeaderValidatorConfig.BuilderThis extension validates that HTTP request and response headers are well formed according to respective RFCsstatic classHeaderValidatorConfig.Http1ProtocolOptionsProtobuf typeenvoy.extensions.http.header_validators.envoy_default.v3.HeaderValidatorConfig.Http1ProtocolOptionsstatic interfaceHeaderValidatorConfig.Http1ProtocolOptionsOrBuilderstatic classHeaderValidatorConfig.UriPathNormalizationOptionsProtobuf typeenvoy.extensions.http.header_validators.envoy_default.v3.HeaderValidatorConfig.UriPathNormalizationOptionsstatic interfaceHeaderValidatorConfig.UriPathNormalizationOptionsOrBuilder-
Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageV3
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage,BuilderType extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType,BuilderType>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter
-
-
Field Summary
Fields Modifier and Type Field Description static intHTTP1_PROTOCOL_OPTIONS_FIELD_NUMBERstatic intRESTRICT_HTTP_METHODS_FIELD_NUMBERstatic intURI_PATH_NORMALIZATION_OPTIONS_FIELD_NUMBER
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object obj)static HeaderValidatorConfiggetDefaultInstance()HeaderValidatorConfiggetDefaultInstanceForType()static com.google.protobuf.Descriptors.DescriptorgetDescriptor()HeaderValidatorConfig.Http1ProtocolOptionsgetHttp1ProtocolOptions().envoy.extensions.http.header_validators.envoy_default.v3.HeaderValidatorConfig.Http1ProtocolOptions http1_protocol_options = 1;HeaderValidatorConfig.Http1ProtocolOptionsOrBuildergetHttp1ProtocolOptionsOrBuilder().envoy.extensions.http.header_validators.envoy_default.v3.HeaderValidatorConfig.Http1ProtocolOptions http1_protocol_options = 1;com.google.protobuf.Parser<HeaderValidatorConfig>getParserForType()booleangetRestrictHttpMethods()Restrict HTTP methods to these defined in the `RFC 7231 section 4.1 <https://datatracker.ietf.org/doc/html/rfc7231#section-4.1>`_ Envoy will respond with 400 to requests with disallowed methods.intgetSerializedSize()com.google.protobuf.UnknownFieldSetgetUnknownFields()HeaderValidatorConfig.UriPathNormalizationOptionsgetUriPathNormalizationOptions()The URI path normalization options.HeaderValidatorConfig.UriPathNormalizationOptionsOrBuildergetUriPathNormalizationOptionsOrBuilder()The URI path normalization options.inthashCode()booleanhasHttp1ProtocolOptions().envoy.extensions.http.header_validators.envoy_default.v3.HeaderValidatorConfig.Http1ProtocolOptions http1_protocol_options = 1;booleanhasUriPathNormalizationOptions()The URI path normalization options.protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTableinternalGetFieldAccessorTable()booleanisInitialized()static HeaderValidatorConfig.BuildernewBuilder()static HeaderValidatorConfig.BuildernewBuilder(HeaderValidatorConfig prototype)HeaderValidatorConfig.BuildernewBuilderForType()protected HeaderValidatorConfig.BuildernewBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)protected ObjectnewInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)static HeaderValidatorConfigparseDelimitedFrom(InputStream input)static HeaderValidatorConfigparseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static HeaderValidatorConfigparseFrom(byte[] data)static HeaderValidatorConfigparseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static HeaderValidatorConfigparseFrom(com.google.protobuf.ByteString data)static HeaderValidatorConfigparseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static HeaderValidatorConfigparseFrom(com.google.protobuf.CodedInputStream input)static HeaderValidatorConfigparseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static HeaderValidatorConfigparseFrom(InputStream input)static HeaderValidatorConfigparseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static HeaderValidatorConfigparseFrom(ByteBuffer data)static HeaderValidatorConfigparseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static com.google.protobuf.Parser<HeaderValidatorConfig>parser()HeaderValidatorConfig.BuildertoBuilder()voidwriteTo(com.google.protobuf.CodedOutputStream output)-
Methods inherited from class com.google.protobuf.GeneratedMessageV3
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, hasField, hasOneof, internalGetMapField, isStringEmpty, makeExtensionsImmutable, mergeFromAndMakeImmutableInternal, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTag
-
Methods inherited from class com.google.protobuf.AbstractMessage
findInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toString
-
Methods inherited from class com.google.protobuf.AbstractMessageLite
addAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeTo
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
-
-
-
Field Detail
-
HTTP1_PROTOCOL_OPTIONS_FIELD_NUMBER
public static final int HTTP1_PROTOCOL_OPTIONS_FIELD_NUMBER
- See Also:
- Constant Field Values
-
URI_PATH_NORMALIZATION_OPTIONS_FIELD_NUMBER
public static final int URI_PATH_NORMALIZATION_OPTIONS_FIELD_NUMBER
- See Also:
- Constant Field Values
-
RESTRICT_HTTP_METHODS_FIELD_NUMBER
public static final int RESTRICT_HTTP_METHODS_FIELD_NUMBER
- See Also:
- Constant Field Values
-
-
Method Detail
-
newInstance
protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
- Overrides:
newInstancein classcom.google.protobuf.GeneratedMessageV3
-
getUnknownFields
public final com.google.protobuf.UnknownFieldSet getUnknownFields()
- Specified by:
getUnknownFieldsin interfacecom.google.protobuf.MessageOrBuilder- Overrides:
getUnknownFieldsin classcom.google.protobuf.GeneratedMessageV3
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
-
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessageV3
-
hasHttp1ProtocolOptions
public boolean hasHttp1ProtocolOptions()
.envoy.extensions.http.header_validators.envoy_default.v3.HeaderValidatorConfig.Http1ProtocolOptions http1_protocol_options = 1;- Specified by:
hasHttp1ProtocolOptionsin interfaceHeaderValidatorConfigOrBuilder- Returns:
- Whether the http1ProtocolOptions field is set.
-
getHttp1ProtocolOptions
public HeaderValidatorConfig.Http1ProtocolOptions getHttp1ProtocolOptions()
.envoy.extensions.http.header_validators.envoy_default.v3.HeaderValidatorConfig.Http1ProtocolOptions http1_protocol_options = 1;- Specified by:
getHttp1ProtocolOptionsin interfaceHeaderValidatorConfigOrBuilder- Returns:
- The http1ProtocolOptions.
-
getHttp1ProtocolOptionsOrBuilder
public HeaderValidatorConfig.Http1ProtocolOptionsOrBuilder getHttp1ProtocolOptionsOrBuilder()
.envoy.extensions.http.header_validators.envoy_default.v3.HeaderValidatorConfig.Http1ProtocolOptions http1_protocol_options = 1;- Specified by:
getHttp1ProtocolOptionsOrBuilderin interfaceHeaderValidatorConfigOrBuilder
-
hasUriPathNormalizationOptions
public boolean hasUriPathNormalizationOptions()
The URI path normalization options. By default Envoy normalizes URI path using the default values of the :ref:`UriPathNormalizationOptions <envoy_v3_api_msg_extensions.http.header_validators.envoy_default.v3.HeaderValidatorConfig.UriPathNormalizationOptions>`. URI path transformations specified by the ``uri_path_normalization_options`` configuration can be applied to a portion of requests by setting the ``envoy_default_header_validator.uri_path_transformations`` runtime value. Caution: disabling path normalization may lead to path confusion vulnerabilities in access control or incorrect service selection.
.envoy.extensions.http.header_validators.envoy_default.v3.HeaderValidatorConfig.UriPathNormalizationOptions uri_path_normalization_options = 2;- Specified by:
hasUriPathNormalizationOptionsin interfaceHeaderValidatorConfigOrBuilder- Returns:
- Whether the uriPathNormalizationOptions field is set.
-
getUriPathNormalizationOptions
public HeaderValidatorConfig.UriPathNormalizationOptions getUriPathNormalizationOptions()
The URI path normalization options. By default Envoy normalizes URI path using the default values of the :ref:`UriPathNormalizationOptions <envoy_v3_api_msg_extensions.http.header_validators.envoy_default.v3.HeaderValidatorConfig.UriPathNormalizationOptions>`. URI path transformations specified by the ``uri_path_normalization_options`` configuration can be applied to a portion of requests by setting the ``envoy_default_header_validator.uri_path_transformations`` runtime value. Caution: disabling path normalization may lead to path confusion vulnerabilities in access control or incorrect service selection.
.envoy.extensions.http.header_validators.envoy_default.v3.HeaderValidatorConfig.UriPathNormalizationOptions uri_path_normalization_options = 2;- Specified by:
getUriPathNormalizationOptionsin interfaceHeaderValidatorConfigOrBuilder- Returns:
- The uriPathNormalizationOptions.
-
getUriPathNormalizationOptionsOrBuilder
public HeaderValidatorConfig.UriPathNormalizationOptionsOrBuilder getUriPathNormalizationOptionsOrBuilder()
The URI path normalization options. By default Envoy normalizes URI path using the default values of the :ref:`UriPathNormalizationOptions <envoy_v3_api_msg_extensions.http.header_validators.envoy_default.v3.HeaderValidatorConfig.UriPathNormalizationOptions>`. URI path transformations specified by the ``uri_path_normalization_options`` configuration can be applied to a portion of requests by setting the ``envoy_default_header_validator.uri_path_transformations`` runtime value. Caution: disabling path normalization may lead to path confusion vulnerabilities in access control or incorrect service selection.
.envoy.extensions.http.header_validators.envoy_default.v3.HeaderValidatorConfig.UriPathNormalizationOptions uri_path_normalization_options = 2;- Specified by:
getUriPathNormalizationOptionsOrBuilderin interfaceHeaderValidatorConfigOrBuilder
-
getRestrictHttpMethods
public boolean getRestrictHttpMethods()
Restrict HTTP methods to these defined in the `RFC 7231 section 4.1 <https://datatracker.ietf.org/doc/html/rfc7231#section-4.1>`_ Envoy will respond with 400 to requests with disallowed methods. By default methods with arbitrary names are accepted.
bool restrict_http_methods = 3;- Specified by:
getRestrictHttpMethodsin interfaceHeaderValidatorConfigOrBuilder- Returns:
- The restrictHttpMethods.
-
isInitialized
public final boolean isInitialized()
- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessageV3
-
writeTo
public void writeTo(com.google.protobuf.CodedOutputStream output) throws IOException- Specified by:
writeToin interfacecom.google.protobuf.MessageLite- Overrides:
writeToin classcom.google.protobuf.GeneratedMessageV3- Throws:
IOException
-
getSerializedSize
public int getSerializedSize()
- Specified by:
getSerializedSizein interfacecom.google.protobuf.MessageLite- Overrides:
getSerializedSizein classcom.google.protobuf.GeneratedMessageV3
-
equals
public boolean equals(Object obj)
- Specified by:
equalsin interfacecom.google.protobuf.Message- Overrides:
equalsin classcom.google.protobuf.AbstractMessage
-
hashCode
public int hashCode()
- Specified by:
hashCodein interfacecom.google.protobuf.Message- Overrides:
hashCodein classcom.google.protobuf.AbstractMessage
-
parseFrom
public static HeaderValidatorConfig parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static HeaderValidatorConfig parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static HeaderValidatorConfig parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static HeaderValidatorConfig parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static HeaderValidatorConfig parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static HeaderValidatorConfig parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static HeaderValidatorConfig parseFrom(InputStream input) throws IOException
- Throws:
IOException
-
parseFrom
public static HeaderValidatorConfig parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
- Throws:
IOException
-
parseDelimitedFrom
public static HeaderValidatorConfig parseDelimitedFrom(InputStream input) throws IOException
- Throws:
IOException
-
parseDelimitedFrom
public static HeaderValidatorConfig parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
- Throws:
IOException
-
parseFrom
public static HeaderValidatorConfig parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
- Throws:
IOException
-
parseFrom
public static HeaderValidatorConfig parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
- Throws:
IOException
-
newBuilderForType
public HeaderValidatorConfig.Builder newBuilderForType()
- Specified by:
newBuilderForTypein interfacecom.google.protobuf.Message- Specified by:
newBuilderForTypein interfacecom.google.protobuf.MessageLite
-
newBuilder
public static HeaderValidatorConfig.Builder newBuilder()
-
newBuilder
public static HeaderValidatorConfig.Builder newBuilder(HeaderValidatorConfig prototype)
-
toBuilder
public HeaderValidatorConfig.Builder toBuilder()
- Specified by:
toBuilderin interfacecom.google.protobuf.Message- Specified by:
toBuilderin interfacecom.google.protobuf.MessageLite
-
newBuilderForType
protected HeaderValidatorConfig.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
- Specified by:
newBuilderForTypein classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstance
public static HeaderValidatorConfig getDefaultInstance()
-
parser
public static com.google.protobuf.Parser<HeaderValidatorConfig> parser()
-
getParserForType
public com.google.protobuf.Parser<HeaderValidatorConfig> getParserForType()
- Specified by:
getParserForTypein interfacecom.google.protobuf.Message- Specified by:
getParserForTypein interfacecom.google.protobuf.MessageLite- Overrides:
getParserForTypein classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstanceForType
public HeaderValidatorConfig getDefaultInstanceForType()
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
-