Class SPIFFECertValidatorConfig
java.lang.Object
com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessage
com.google.protobuf.GeneratedMessageV3
io.envoyproxy.envoy.extensions.transport_sockets.tls.v3.SPIFFECertValidatorConfig
- All Implemented Interfaces:
com.google.protobuf.Message,com.google.protobuf.MessageLite,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,SPIFFECertValidatorConfigOrBuilder,Serializable
public final class SPIFFECertValidatorConfig
extends com.google.protobuf.GeneratedMessageV3
implements SPIFFECertValidatorConfigOrBuilder
Configuration specific to the `SPIFFE <https://github.com/spiffe/spiffe>`_ certificate validator.
Example:
.. validated-code-block:: yaml
:type-name: envoy.extensions.transport_sockets.tls.v3.CertificateValidationContext
custom_validator_config:
name: envoy.tls.cert_validator.spiffe
typed_config:
"@type": type.googleapis.com/envoy.extensions.transport_sockets.tls.v3.SPIFFECertValidatorConfig
trust_domains:
- name: foo.com
trust_bundle:
filename: "foo.pem"
- name: envoy.com
trust_bundle:
filename: "envoy.pem"
In this example, a presented peer certificate whose SAN matches ``spiffe://foo.com/**`` is validated against
the "foo.pem" x.509 certificate. All the trust bundles are isolated from each other, so no trust domain can mint
a SVID belonging to another trust domain. That means, in this example, a SVID signed by ``envoy.com``'s CA with ``spiffe://foo.com/**``
SAN would be rejected since Envoy selects the trust bundle according to the presented SAN before validate the certificate.
Note that SPIFFE validator inherits and uses the following options from :ref:`CertificateValidationContext <envoy_v3_api_msg_extensions.transport_sockets.tls.v3.CertificateValidationContext>`.
- :ref:`allow_expired_certificate <envoy_v3_api_field_extensions.transport_sockets.tls.v3.CertificateValidationContext.allow_expired_certificate>` to allow expired certificates.
- :ref:`match_typed_subject_alt_names <envoy_v3_api_field_extensions.transport_sockets.tls.v3.CertificateValidationContext.match_typed_subject_alt_names>` to match **URI** SAN of certificates. Unlike the default validator, SPIFFE validator only matches **URI** SAN (which equals to SVID in SPIFFE terminology) and ignore other SAN types.
Protobuf type envoy.extensions.transport_sockets.tls.v3.SPIFFECertValidatorConfig- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classConfiguration specific to the `SPIFFE <https://github.com/spiffe/spiffe>`_ certificate validator.static final classProtobuf typeenvoy.extensions.transport_sockets.tls.v3.SPIFFECertValidatorConfig.TrustDomainstatic interfaceNested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageV3
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT, BuilderT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessageLite.InternalOneOfEnum -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intFields inherited from class com.google.protobuf.GeneratedMessageV3
alwaysUseFieldBuilders, unknownFieldsFields inherited from class com.google.protobuf.AbstractMessage
memoizedSizeFields inherited from class com.google.protobuf.AbstractMessageLite
memoizedHashCode -
Method Summary
Modifier and TypeMethodDescriptionbooleanstatic SPIFFECertValidatorConfigstatic final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Parser<SPIFFECertValidatorConfig>intThis field specifies all trust bundles as a single DataSource.This field specifies all trust bundles as a single DataSource.getTrustDomains(int index) This field specifies trust domains used for validating incoming X.509-SVID(s).intThis field specifies trust domains used for validating incoming X.509-SVID(s).This field specifies trust domains used for validating incoming X.509-SVID(s).getTrustDomainsOrBuilder(int index) This field specifies trust domains used for validating incoming X.509-SVID(s).This field specifies trust domains used for validating incoming X.509-SVID(s).inthashCode()booleanThis field specifies all trust bundles as a single DataSource.protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTablefinal booleannewBuilder(SPIFFECertValidatorConfig prototype) protected SPIFFECertValidatorConfig.BuildernewBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) protected ObjectnewInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused) static SPIFFECertValidatorConfigparseDelimitedFrom(InputStream input) static SPIFFECertValidatorConfigparseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static SPIFFECertValidatorConfigparseFrom(byte[] data) static SPIFFECertValidatorConfigparseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static SPIFFECertValidatorConfigparseFrom(com.google.protobuf.ByteString data) static SPIFFECertValidatorConfigparseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static SPIFFECertValidatorConfigparseFrom(com.google.protobuf.CodedInputStream input) static SPIFFECertValidatorConfigparseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static SPIFFECertValidatorConfigparseFrom(InputStream input) static SPIFFECertValidatorConfigparseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static SPIFFECertValidatorConfigparseFrom(ByteBuffer data) static SPIFFECertValidatorConfigparseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static com.google.protobuf.Parser<SPIFFECertValidatorConfig>parser()voidwriteTo(com.google.protobuf.CodedOutputStream output) Methods inherited from class com.google.protobuf.GeneratedMessageV3
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, isStringEmpty, makeExtensionsImmutable, makeMutableCopy, makeMutableCopy, 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, writeStringNoTagMethods inherited from class com.google.protobuf.AbstractMessage
findInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite
addAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.MessageLite
toByteArray, toByteString, writeDelimitedTo, writeToMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Field Details
-
TRUST_DOMAINS_FIELD_NUMBER
public static final int TRUST_DOMAINS_FIELD_NUMBER- See Also:
-
TRUST_BUNDLES_FIELD_NUMBER
public static final int TRUST_BUNDLES_FIELD_NUMBER- See Also:
-
-
Method Details
-
newInstance
- Overrides:
newInstancein 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
-
getTrustDomainsList
This field specifies trust domains used for validating incoming X.509-SVID(s).
repeated .envoy.extensions.transport_sockets.tls.v3.SPIFFECertValidatorConfig.TrustDomain trust_domains = 1 [(.validate.rules) = { ... }- Specified by:
getTrustDomainsListin interfaceSPIFFECertValidatorConfigOrBuilder
-
getTrustDomainsOrBuilderList
public List<? extends SPIFFECertValidatorConfig.TrustDomainOrBuilder> getTrustDomainsOrBuilderList()This field specifies trust domains used for validating incoming X.509-SVID(s).
repeated .envoy.extensions.transport_sockets.tls.v3.SPIFFECertValidatorConfig.TrustDomain trust_domains = 1 [(.validate.rules) = { ... }- Specified by:
getTrustDomainsOrBuilderListin interfaceSPIFFECertValidatorConfigOrBuilder
-
getTrustDomainsCount
public int getTrustDomainsCount()This field specifies trust domains used for validating incoming X.509-SVID(s).
repeated .envoy.extensions.transport_sockets.tls.v3.SPIFFECertValidatorConfig.TrustDomain trust_domains = 1 [(.validate.rules) = { ... }- Specified by:
getTrustDomainsCountin interfaceSPIFFECertValidatorConfigOrBuilder
-
getTrustDomains
This field specifies trust domains used for validating incoming X.509-SVID(s).
repeated .envoy.extensions.transport_sockets.tls.v3.SPIFFECertValidatorConfig.TrustDomain trust_domains = 1 [(.validate.rules) = { ... }- Specified by:
getTrustDomainsin interfaceSPIFFECertValidatorConfigOrBuilder
-
getTrustDomainsOrBuilder
This field specifies trust domains used for validating incoming X.509-SVID(s).
repeated .envoy.extensions.transport_sockets.tls.v3.SPIFFECertValidatorConfig.TrustDomain trust_domains = 1 [(.validate.rules) = { ... }- Specified by:
getTrustDomainsOrBuilderin interfaceSPIFFECertValidatorConfigOrBuilder
-
hasTrustBundles
public boolean hasTrustBundles()This field specifies all trust bundles as a single DataSource. If both trust_bundles and trust_domains are specified, trust_bundles will take precedence. Currently assumes file will be a SPIFFE Trust Bundle Map. If DataSource is a file, dynamic file watching will be enabled, and updates to the specified file will trigger a refresh of the trust_bundles.
.envoy.config.core.v3.DataSource trust_bundles = 2;- Specified by:
hasTrustBundlesin interfaceSPIFFECertValidatorConfigOrBuilder- Returns:
- Whether the trustBundles field is set.
-
getTrustBundles
This field specifies all trust bundles as a single DataSource. If both trust_bundles and trust_domains are specified, trust_bundles will take precedence. Currently assumes file will be a SPIFFE Trust Bundle Map. If DataSource is a file, dynamic file watching will be enabled, and updates to the specified file will trigger a refresh of the trust_bundles.
.envoy.config.core.v3.DataSource trust_bundles = 2;- Specified by:
getTrustBundlesin interfaceSPIFFECertValidatorConfigOrBuilder- Returns:
- The trustBundles.
-
getTrustBundlesOrBuilder
This field specifies all trust bundles as a single DataSource. If both trust_bundles and trust_domains are specified, trust_bundles will take precedence. Currently assumes file will be a SPIFFE Trust Bundle Map. If DataSource is a file, dynamic file watching will be enabled, and updates to the specified file will trigger a refresh of the trust_bundles.
.envoy.config.core.v3.DataSource trust_bundles = 2;- Specified by:
getTrustBundlesOrBuilderin interfaceSPIFFECertValidatorConfigOrBuilder
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessageV3
-
writeTo
- 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
- 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 SPIFFECertValidatorConfig parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static SPIFFECertValidatorConfig parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static SPIFFECertValidatorConfig parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static SPIFFECertValidatorConfig parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static SPIFFECertValidatorConfig parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static SPIFFECertValidatorConfig parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static SPIFFECertValidatorConfig parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseDelimitedFrom
- Throws:
IOException
-
parseDelimitedFrom
public static SPIFFECertValidatorConfig parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseFrom
public static SPIFFECertValidatorConfig parseFrom(com.google.protobuf.CodedInputStream input) throws IOException - Throws:
IOException
-
parseFrom
public static SPIFFECertValidatorConfig parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
newBuilderForType
- Specified by:
newBuilderForTypein interfacecom.google.protobuf.Message- Specified by:
newBuilderForTypein interfacecom.google.protobuf.MessageLite
-
newBuilder
-
newBuilder
-
toBuilder
- Specified by:
toBuilderin interfacecom.google.protobuf.Message- Specified by:
toBuilderin interfacecom.google.protobuf.MessageLite
-
newBuilderForType
protected SPIFFECertValidatorConfig.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) - Specified by:
newBuilderForTypein classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstance
-
parser
-
getParserForType
- Specified by:
getParserForTypein interfacecom.google.protobuf.Message- Specified by:
getParserForTypein interfacecom.google.protobuf.MessageLite- Overrides:
getParserForTypein classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-