Class BasicAuth.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessageV3.Builder<BasicAuth.Builder>
io.envoyproxy.envoy.extensions.filters.http.basic_auth.v3.BasicAuth.Builder
- All Implemented Interfaces:
com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,BasicAuthOrBuilder,Cloneable
- Enclosing class:
- BasicAuth
public static final class BasicAuth.Builder
extends com.google.protobuf.GeneratedMessageV3.Builder<BasicAuth.Builder>
implements BasicAuthOrBuilder
Basic HTTP authentication.
Example:
.. code-block:: yaml
users:
inline_string: |-
user1:{SHA}hashed_user1_password
user2:{SHA}hashed_user2_password
Protobuf type envoy.extensions.filters.http.basic_auth.v3.BasicAuth-
Method Summary
Modifier and TypeMethodDescriptionaddRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value) build()clear()This field specifies the request header to load the basic credential from.clearField(com.google.protobuf.Descriptors.FieldDescriptor field) This field specifies the header name to forward a successfully authenticated user to the backend.clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) Username-password pairs used to verify user credentials in the "Authorization" header.clone()This field specifies the request header to load the basic credential from.com.google.protobuf.ByteStringThis field specifies the request header to load the basic credential from.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.DescriptorThis field specifies the header name to forward a successfully authenticated user to the backend.com.google.protobuf.ByteStringThis field specifies the header name to forward a successfully authenticated user to the backend.getUsers()Username-password pairs used to verify user credentials in the "Authorization" header.Username-password pairs used to verify user credentials in the "Authorization" header.Username-password pairs used to verify user credentials in the "Authorization" header.booleanhasUsers()Username-password pairs used to verify user credentials in the "Authorization" header.protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTablefinal booleanmergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) final BasicAuth.BuildermergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) mergeUsers(DataSource value) Username-password pairs used to verify user credentials in the "Authorization" header.setAuthenticationHeader(String value) This field specifies the request header to load the basic credential from.setAuthenticationHeaderBytes(com.google.protobuf.ByteString value) This field specifies the request header to load the basic credential from.setForwardUsernameHeader(String value) This field specifies the header name to forward a successfully authenticated user to the backend.setForwardUsernameHeaderBytes(com.google.protobuf.ByteString value) This field specifies the header name to forward a successfully authenticated user to the backend.setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) final BasicAuth.BuildersetUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) setUsers(DataSource value) Username-password pairs used to verify user credentials in the "Authorization" header.setUsers(DataSource.Builder builderForValue) Username-password pairs used to verify user credentials in the "Authorization" header.Methods inherited from class com.google.protobuf.GeneratedMessageV3.Builder
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setUnknownFieldSetBuilder, setUnknownFieldsProto3Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.Message.Builder
mergeDelimitedFrom, mergeDelimitedFromMethods inherited from interface com.google.protobuf.MessageLite.Builder
mergeFromMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
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.Builder<BasicAuth.Builder>
-
clear
- Specified by:
clearin interfacecom.google.protobuf.Message.Builder- Specified by:
clearin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clearin classcom.google.protobuf.GeneratedMessageV3.Builder<BasicAuth.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.Message.Builder- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.MessageOrBuilder- Overrides:
getDescriptorForTypein classcom.google.protobuf.GeneratedMessageV3.Builder<BasicAuth.Builder>
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
build
- Specified by:
buildin interfacecom.google.protobuf.Message.Builder- Specified by:
buildin interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
- Specified by:
buildPartialin interfacecom.google.protobuf.Message.Builder- Specified by:
buildPartialin interfacecom.google.protobuf.MessageLite.Builder
-
clone
- Specified by:
clonein interfacecom.google.protobuf.Message.Builder- Specified by:
clonein interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clonein classcom.google.protobuf.GeneratedMessageV3.Builder<BasicAuth.Builder>
-
setField
public BasicAuth.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value) - Specified by:
setFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
setFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<BasicAuth.Builder>
-
clearField
- Specified by:
clearFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
clearFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<BasicAuth.Builder>
-
clearOneof
- Specified by:
clearOneofin interfacecom.google.protobuf.Message.Builder- Overrides:
clearOneofin classcom.google.protobuf.GeneratedMessageV3.Builder<BasicAuth.Builder>
-
setRepeatedField
public BasicAuth.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) - Specified by:
setRepeatedFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
setRepeatedFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<BasicAuth.Builder>
-
addRepeatedField
public BasicAuth.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value) - Specified by:
addRepeatedFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
addRepeatedFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<BasicAuth.Builder>
-
mergeFrom
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<BasicAuth.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessageV3.Builder<BasicAuth.Builder>
-
mergeFrom
public BasicAuth.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Specified by:
mergeFromin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<BasicAuth.Builder>- Throws:
IOException
-
hasUsers
public boolean hasUsers()Username-password pairs used to verify user credentials in the "Authorization" header. The value needs to be the htpasswd format. Reference to https://httpd.apache.org/docs/2.4/programs/htpasswd.html
.envoy.config.core.v3.DataSource users = 1 [(.udpa.annotations.sensitive) = true];- Specified by:
hasUsersin interfaceBasicAuthOrBuilder- Returns:
- Whether the users field is set.
-
getUsers
Username-password pairs used to verify user credentials in the "Authorization" header. The value needs to be the htpasswd format. Reference to https://httpd.apache.org/docs/2.4/programs/htpasswd.html
.envoy.config.core.v3.DataSource users = 1 [(.udpa.annotations.sensitive) = true];- Specified by:
getUsersin interfaceBasicAuthOrBuilder- Returns:
- The users.
-
setUsers
Username-password pairs used to verify user credentials in the "Authorization" header. The value needs to be the htpasswd format. Reference to https://httpd.apache.org/docs/2.4/programs/htpasswd.html
.envoy.config.core.v3.DataSource users = 1 [(.udpa.annotations.sensitive) = true]; -
setUsers
Username-password pairs used to verify user credentials in the "Authorization" header. The value needs to be the htpasswd format. Reference to https://httpd.apache.org/docs/2.4/programs/htpasswd.html
.envoy.config.core.v3.DataSource users = 1 [(.udpa.annotations.sensitive) = true]; -
mergeUsers
Username-password pairs used to verify user credentials in the "Authorization" header. The value needs to be the htpasswd format. Reference to https://httpd.apache.org/docs/2.4/programs/htpasswd.html
.envoy.config.core.v3.DataSource users = 1 [(.udpa.annotations.sensitive) = true]; -
clearUsers
Username-password pairs used to verify user credentials in the "Authorization" header. The value needs to be the htpasswd format. Reference to https://httpd.apache.org/docs/2.4/programs/htpasswd.html
.envoy.config.core.v3.DataSource users = 1 [(.udpa.annotations.sensitive) = true]; -
getUsersBuilder
Username-password pairs used to verify user credentials in the "Authorization" header. The value needs to be the htpasswd format. Reference to https://httpd.apache.org/docs/2.4/programs/htpasswd.html
.envoy.config.core.v3.DataSource users = 1 [(.udpa.annotations.sensitive) = true]; -
getUsersOrBuilder
Username-password pairs used to verify user credentials in the "Authorization" header. The value needs to be the htpasswd format. Reference to https://httpd.apache.org/docs/2.4/programs/htpasswd.html
.envoy.config.core.v3.DataSource users = 1 [(.udpa.annotations.sensitive) = true];- Specified by:
getUsersOrBuilderin interfaceBasicAuthOrBuilder
-
getForwardUsernameHeader
This field specifies the header name to forward a successfully authenticated user to the backend. The header will be added to the request with the username as the value. If it is not specified, the username will not be forwarded.
string forward_username_header = 2 [(.validate.rules) = { ... }- Specified by:
getForwardUsernameHeaderin interfaceBasicAuthOrBuilder- Returns:
- The forwardUsernameHeader.
-
getForwardUsernameHeaderBytes
public com.google.protobuf.ByteString getForwardUsernameHeaderBytes()This field specifies the header name to forward a successfully authenticated user to the backend. The header will be added to the request with the username as the value. If it is not specified, the username will not be forwarded.
string forward_username_header = 2 [(.validate.rules) = { ... }- Specified by:
getForwardUsernameHeaderBytesin interfaceBasicAuthOrBuilder- Returns:
- The bytes for forwardUsernameHeader.
-
setForwardUsernameHeader
This field specifies the header name to forward a successfully authenticated user to the backend. The header will be added to the request with the username as the value. If it is not specified, the username will not be forwarded.
string forward_username_header = 2 [(.validate.rules) = { ... }- Parameters:
value- The forwardUsernameHeader to set.- Returns:
- This builder for chaining.
-
clearForwardUsernameHeader
This field specifies the header name to forward a successfully authenticated user to the backend. The header will be added to the request with the username as the value. If it is not specified, the username will not be forwarded.
string forward_username_header = 2 [(.validate.rules) = { ... }- Returns:
- This builder for chaining.
-
setForwardUsernameHeaderBytes
This field specifies the header name to forward a successfully authenticated user to the backend. The header will be added to the request with the username as the value. If it is not specified, the username will not be forwarded.
string forward_username_header = 2 [(.validate.rules) = { ... }- Parameters:
value- The bytes for forwardUsernameHeader to set.- Returns:
- This builder for chaining.
-
getAuthenticationHeader
This field specifies the request header to load the basic credential from. If it is not specified, the filter loads the credential from the "Authorization" header.
string authentication_header = 3 [(.validate.rules) = { ... }- Specified by:
getAuthenticationHeaderin interfaceBasicAuthOrBuilder- Returns:
- The authenticationHeader.
-
getAuthenticationHeaderBytes
public com.google.protobuf.ByteString getAuthenticationHeaderBytes()This field specifies the request header to load the basic credential from. If it is not specified, the filter loads the credential from the "Authorization" header.
string authentication_header = 3 [(.validate.rules) = { ... }- Specified by:
getAuthenticationHeaderBytesin interfaceBasicAuthOrBuilder- Returns:
- The bytes for authenticationHeader.
-
setAuthenticationHeader
This field specifies the request header to load the basic credential from. If it is not specified, the filter loads the credential from the "Authorization" header.
string authentication_header = 3 [(.validate.rules) = { ... }- Parameters:
value- The authenticationHeader to set.- Returns:
- This builder for chaining.
-
clearAuthenticationHeader
This field specifies the request header to load the basic credential from. If it is not specified, the filter loads the credential from the "Authorization" header.
string authentication_header = 3 [(.validate.rules) = { ... }- Returns:
- This builder for chaining.
-
setAuthenticationHeaderBytes
This field specifies the request header to load the basic credential from. If it is not specified, the filter loads the credential from the "Authorization" header.
string authentication_header = 3 [(.validate.rules) = { ... }- Parameters:
value- The bytes for authenticationHeader to set.- Returns:
- This builder for chaining.
-
setUnknownFields
- Specified by:
setUnknownFieldsin interfacecom.google.protobuf.Message.Builder- Overrides:
setUnknownFieldsin classcom.google.protobuf.GeneratedMessageV3.Builder<BasicAuth.Builder>
-
mergeUnknownFields
public final BasicAuth.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) - Specified by:
mergeUnknownFieldsin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeUnknownFieldsin classcom.google.protobuf.GeneratedMessageV3.Builder<BasicAuth.Builder>
-