Package com.google.rpc.context
Class AttributeContext.Auth
- java.lang.Object
-
- com.google.protobuf.AbstractMessageLite
-
- com.google.protobuf.AbstractMessage
-
- com.google.protobuf.GeneratedMessageV3
-
- com.google.rpc.context.AttributeContext.Auth
-
- All Implemented Interfaces:
com.google.protobuf.Message,com.google.protobuf.MessageLite,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,AttributeContext.AuthOrBuilder,java.io.Serializable
- Enclosing class:
- AttributeContext
public static final class AttributeContext.Auth extends com.google.protobuf.GeneratedMessageV3 implements AttributeContext.AuthOrBuilder
This message defines request authentication attributes. Terminology is based on the JSON Web Token (JWT) standard, but the terms also correlate to concepts in other standards.
Protobuf typegoogle.rpc.context.AttributeContext.Auth- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classAttributeContext.Auth.BuilderThis message defines request authentication attributes.-
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 intACCESS_LEVELS_FIELD_NUMBERstatic intAUDIENCES_FIELD_NUMBERstatic intCLAIMS_FIELD_NUMBERstatic intPRESENTER_FIELD_NUMBERstatic intPRINCIPAL_FIELD_NUMBER
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object obj)java.lang.StringgetAccessLevels(int index)A list of access level resource names that allow resources to be accessed by authenticated requester.com.google.protobuf.ByteStringgetAccessLevelsBytes(int index)A list of access level resource names that allow resources to be accessed by authenticated requester.intgetAccessLevelsCount()A list of access level resource names that allow resources to be accessed by authenticated requester.com.google.protobuf.ProtocolStringListgetAccessLevelsList()A list of access level resource names that allow resources to be accessed by authenticated requester.java.lang.StringgetAudiences(int index)The intended audience(s) for this authentication information.com.google.protobuf.ByteStringgetAudiencesBytes(int index)The intended audience(s) for this authentication information.intgetAudiencesCount()The intended audience(s) for this authentication information.com.google.protobuf.ProtocolStringListgetAudiencesList()The intended audience(s) for this authentication information.com.google.protobuf.StructgetClaims()Structured claims presented with the credential.com.google.protobuf.StructOrBuildergetClaimsOrBuilder()Structured claims presented with the credential.static AttributeContext.AuthgetDefaultInstance()AttributeContext.AuthgetDefaultInstanceForType()static com.google.protobuf.Descriptors.DescriptorgetDescriptor()com.google.protobuf.Parser<AttributeContext.Auth>getParserForType()java.lang.StringgetPresenter()The authorized presenter of the credential.com.google.protobuf.ByteStringgetPresenterBytes()The authorized presenter of the credential.java.lang.StringgetPrincipal()The authenticated principal.com.google.protobuf.ByteStringgetPrincipalBytes()The authenticated principal.intgetSerializedSize()com.google.protobuf.UnknownFieldSetgetUnknownFields()booleanhasClaims()Structured claims presented with the credential.inthashCode()protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTableinternalGetFieldAccessorTable()booleanisInitialized()static AttributeContext.Auth.BuildernewBuilder()static AttributeContext.Auth.BuildernewBuilder(AttributeContext.Auth prototype)AttributeContext.Auth.BuildernewBuilderForType()protected AttributeContext.Auth.BuildernewBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)protected java.lang.ObjectnewInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)static AttributeContext.AuthparseDelimitedFrom(java.io.InputStream input)static AttributeContext.AuthparseDelimitedFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static AttributeContext.AuthparseFrom(byte[] data)static AttributeContext.AuthparseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static AttributeContext.AuthparseFrom(com.google.protobuf.ByteString data)static AttributeContext.AuthparseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static AttributeContext.AuthparseFrom(com.google.protobuf.CodedInputStream input)static AttributeContext.AuthparseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static AttributeContext.AuthparseFrom(java.io.InputStream input)static AttributeContext.AuthparseFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static AttributeContext.AuthparseFrom(java.nio.ByteBuffer data)static AttributeContext.AuthparseFrom(java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static com.google.protobuf.Parser<AttributeContext.Auth>parser()AttributeContext.Auth.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
-
PRINCIPAL_FIELD_NUMBER
public static final int PRINCIPAL_FIELD_NUMBER
- See Also:
- Constant Field Values
-
AUDIENCES_FIELD_NUMBER
public static final int AUDIENCES_FIELD_NUMBER
- See Also:
- Constant Field Values
-
PRESENTER_FIELD_NUMBER
public static final int PRESENTER_FIELD_NUMBER
- See Also:
- Constant Field Values
-
CLAIMS_FIELD_NUMBER
public static final int CLAIMS_FIELD_NUMBER
- See Also:
- Constant Field Values
-
ACCESS_LEVELS_FIELD_NUMBER
public static final int ACCESS_LEVELS_FIELD_NUMBER
- See Also:
- Constant Field Values
-
-
Method Detail
-
newInstance
protected java.lang.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
-
getPrincipal
public java.lang.String getPrincipal()
The authenticated principal. Reflects the issuer (`iss`) and subject (`sub`) claims within a JWT. The issuer and subject should be `/` delimited, with `/` percent-encoded within the subject fragment. For Google accounts, the principal format is: "https://accounts.google.com/{id}"string principal = 1;- Specified by:
getPrincipalin interfaceAttributeContext.AuthOrBuilder- Returns:
- The principal.
-
getPrincipalBytes
public com.google.protobuf.ByteString getPrincipalBytes()
The authenticated principal. Reflects the issuer (`iss`) and subject (`sub`) claims within a JWT. The issuer and subject should be `/` delimited, with `/` percent-encoded within the subject fragment. For Google accounts, the principal format is: "https://accounts.google.com/{id}"string principal = 1;- Specified by:
getPrincipalBytesin interfaceAttributeContext.AuthOrBuilder- Returns:
- The bytes for principal.
-
getAudiencesList
public com.google.protobuf.ProtocolStringList getAudiencesList()
The intended audience(s) for this authentication information. Reflects the audience (`aud`) claim within a JWT. The audience value(s) depends on the `issuer`, but typically include one or more of the following pieces of information: * The services intended to receive the credential. For example, ["https://pubsub.googleapis.com/", "https://storage.googleapis.com/"]. * A set of service-based scopes. For example, ["https://www.googleapis.com/auth/cloud-platform"]. * The client id of an app, such as the Firebase project id for JWTs from Firebase Auth. Consult the documentation for the credential issuer to determine the information provided.repeated string audiences = 2;- Specified by:
getAudiencesListin interfaceAttributeContext.AuthOrBuilder- Returns:
- A list containing the audiences.
-
getAudiencesCount
public int getAudiencesCount()
The intended audience(s) for this authentication information. Reflects the audience (`aud`) claim within a JWT. The audience value(s) depends on the `issuer`, but typically include one or more of the following pieces of information: * The services intended to receive the credential. For example, ["https://pubsub.googleapis.com/", "https://storage.googleapis.com/"]. * A set of service-based scopes. For example, ["https://www.googleapis.com/auth/cloud-platform"]. * The client id of an app, such as the Firebase project id for JWTs from Firebase Auth. Consult the documentation for the credential issuer to determine the information provided.repeated string audiences = 2;- Specified by:
getAudiencesCountin interfaceAttributeContext.AuthOrBuilder- Returns:
- The count of audiences.
-
getAudiences
public java.lang.String getAudiences(int index)
The intended audience(s) for this authentication information. Reflects the audience (`aud`) claim within a JWT. The audience value(s) depends on the `issuer`, but typically include one or more of the following pieces of information: * The services intended to receive the credential. For example, ["https://pubsub.googleapis.com/", "https://storage.googleapis.com/"]. * A set of service-based scopes. For example, ["https://www.googleapis.com/auth/cloud-platform"]. * The client id of an app, such as the Firebase project id for JWTs from Firebase Auth. Consult the documentation for the credential issuer to determine the information provided.repeated string audiences = 2;- Specified by:
getAudiencesin interfaceAttributeContext.AuthOrBuilder- Parameters:
index- The index of the element to return.- Returns:
- The audiences at the given index.
-
getAudiencesBytes
public com.google.protobuf.ByteString getAudiencesBytes(int index)
The intended audience(s) for this authentication information. Reflects the audience (`aud`) claim within a JWT. The audience value(s) depends on the `issuer`, but typically include one or more of the following pieces of information: * The services intended to receive the credential. For example, ["https://pubsub.googleapis.com/", "https://storage.googleapis.com/"]. * A set of service-based scopes. For example, ["https://www.googleapis.com/auth/cloud-platform"]. * The client id of an app, such as the Firebase project id for JWTs from Firebase Auth. Consult the documentation for the credential issuer to determine the information provided.repeated string audiences = 2;- Specified by:
getAudiencesBytesin interfaceAttributeContext.AuthOrBuilder- Parameters:
index- The index of the value to return.- Returns:
- The bytes of the audiences at the given index.
-
getPresenter
public java.lang.String getPresenter()
The authorized presenter of the credential. Reflects the optional Authorized Presenter (`azp`) claim within a JWT or the OAuth client id. For example, a Google Cloud Platform client id looks as follows: "123456789012.apps.googleusercontent.com".
string presenter = 3;- Specified by:
getPresenterin interfaceAttributeContext.AuthOrBuilder- Returns:
- The presenter.
-
getPresenterBytes
public com.google.protobuf.ByteString getPresenterBytes()
The authorized presenter of the credential. Reflects the optional Authorized Presenter (`azp`) claim within a JWT or the OAuth client id. For example, a Google Cloud Platform client id looks as follows: "123456789012.apps.googleusercontent.com".
string presenter = 3;- Specified by:
getPresenterBytesin interfaceAttributeContext.AuthOrBuilder- Returns:
- The bytes for presenter.
-
hasClaims
public boolean hasClaims()
Structured claims presented with the credential. JWTs include `{key: value}` pairs for standard and private claims. The following is a subset of the standard required and optional claims that would typically be presented for a Google-based JWT: {'iss': 'accounts.google.com', 'sub': '113289723416554971153', 'aud': ['123456789012', 'pubsub.googleapis.com'], 'azp': '123456789012.apps.googleusercontent.com', 'email': 'jsmith@example.com', 'iat': 1353601026, 'exp': 1353604926} SAML assertions are similarly specified, but with an identity provider dependent structure..google.protobuf.Struct claims = 4;- Specified by:
hasClaimsin interfaceAttributeContext.AuthOrBuilder- Returns:
- Whether the claims field is set.
-
getClaims
public com.google.protobuf.Struct getClaims()
Structured claims presented with the credential. JWTs include `{key: value}` pairs for standard and private claims. The following is a subset of the standard required and optional claims that would typically be presented for a Google-based JWT: {'iss': 'accounts.google.com', 'sub': '113289723416554971153', 'aud': ['123456789012', 'pubsub.googleapis.com'], 'azp': '123456789012.apps.googleusercontent.com', 'email': 'jsmith@example.com', 'iat': 1353601026, 'exp': 1353604926} SAML assertions are similarly specified, but with an identity provider dependent structure..google.protobuf.Struct claims = 4;- Specified by:
getClaimsin interfaceAttributeContext.AuthOrBuilder- Returns:
- The claims.
-
getClaimsOrBuilder
public com.google.protobuf.StructOrBuilder getClaimsOrBuilder()
Structured claims presented with the credential. JWTs include `{key: value}` pairs for standard and private claims. The following is a subset of the standard required and optional claims that would typically be presented for a Google-based JWT: {'iss': 'accounts.google.com', 'sub': '113289723416554971153', 'aud': ['123456789012', 'pubsub.googleapis.com'], 'azp': '123456789012.apps.googleusercontent.com', 'email': 'jsmith@example.com', 'iat': 1353601026, 'exp': 1353604926} SAML assertions are similarly specified, but with an identity provider dependent structure..google.protobuf.Struct claims = 4;- Specified by:
getClaimsOrBuilderin interfaceAttributeContext.AuthOrBuilder
-
getAccessLevelsList
public com.google.protobuf.ProtocolStringList getAccessLevelsList()
A list of access level resource names that allow resources to be accessed by authenticated requester. It is part of Secure GCP processing for the incoming request. An access level string has the format: "//{api_service_name}/accessPolicies/{policy_id}/accessLevels/{short_name}" Example: "//accesscontextmanager.googleapis.com/accessPolicies/MY_POLICY_ID/accessLevels/MY_LEVEL"repeated string access_levels = 5;- Specified by:
getAccessLevelsListin interfaceAttributeContext.AuthOrBuilder- Returns:
- A list containing the accessLevels.
-
getAccessLevelsCount
public int getAccessLevelsCount()
A list of access level resource names that allow resources to be accessed by authenticated requester. It is part of Secure GCP processing for the incoming request. An access level string has the format: "//{api_service_name}/accessPolicies/{policy_id}/accessLevels/{short_name}" Example: "//accesscontextmanager.googleapis.com/accessPolicies/MY_POLICY_ID/accessLevels/MY_LEVEL"repeated string access_levels = 5;- Specified by:
getAccessLevelsCountin interfaceAttributeContext.AuthOrBuilder- Returns:
- The count of accessLevels.
-
getAccessLevels
public java.lang.String getAccessLevels(int index)
A list of access level resource names that allow resources to be accessed by authenticated requester. It is part of Secure GCP processing for the incoming request. An access level string has the format: "//{api_service_name}/accessPolicies/{policy_id}/accessLevels/{short_name}" Example: "//accesscontextmanager.googleapis.com/accessPolicies/MY_POLICY_ID/accessLevels/MY_LEVEL"repeated string access_levels = 5;- Specified by:
getAccessLevelsin interfaceAttributeContext.AuthOrBuilder- Parameters:
index- The index of the element to return.- Returns:
- The accessLevels at the given index.
-
getAccessLevelsBytes
public com.google.protobuf.ByteString getAccessLevelsBytes(int index)
A list of access level resource names that allow resources to be accessed by authenticated requester. It is part of Secure GCP processing for the incoming request. An access level string has the format: "//{api_service_name}/accessPolicies/{policy_id}/accessLevels/{short_name}" Example: "//accesscontextmanager.googleapis.com/accessPolicies/MY_POLICY_ID/accessLevels/MY_LEVEL"repeated string access_levels = 5;- Specified by:
getAccessLevelsBytesin interfaceAttributeContext.AuthOrBuilder- Parameters:
index- The index of the value to return.- Returns:
- The bytes of the accessLevels at the given index.
-
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 java.io.IOException- Specified by:
writeToin interfacecom.google.protobuf.MessageLite- Overrides:
writeToin classcom.google.protobuf.GeneratedMessageV3- Throws:
java.io.IOException
-
getSerializedSize
public int getSerializedSize()
- Specified by:
getSerializedSizein interfacecom.google.protobuf.MessageLite- Overrides:
getSerializedSizein classcom.google.protobuf.GeneratedMessageV3
-
equals
public boolean equals(java.lang.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 AttributeContext.Auth parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static AttributeContext.Auth parseFrom(java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static AttributeContext.Auth parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static AttributeContext.Auth parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static AttributeContext.Auth parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static AttributeContext.Auth parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static AttributeContext.Auth parseFrom(java.io.InputStream input) throws java.io.IOException
- Throws:
java.io.IOException
-
parseFrom
public static AttributeContext.Auth parseFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
- Throws:
java.io.IOException
-
parseDelimitedFrom
public static AttributeContext.Auth parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException
- Throws:
java.io.IOException
-
parseDelimitedFrom
public static AttributeContext.Auth parseDelimitedFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
- Throws:
java.io.IOException
-
parseFrom
public static AttributeContext.Auth parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException
- Throws:
java.io.IOException
-
parseFrom
public static AttributeContext.Auth parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
- Throws:
java.io.IOException
-
newBuilderForType
public AttributeContext.Auth.Builder newBuilderForType()
- Specified by:
newBuilderForTypein interfacecom.google.protobuf.Message- Specified by:
newBuilderForTypein interfacecom.google.protobuf.MessageLite
-
newBuilder
public static AttributeContext.Auth.Builder newBuilder()
-
newBuilder
public static AttributeContext.Auth.Builder newBuilder(AttributeContext.Auth prototype)
-
toBuilder
public AttributeContext.Auth.Builder toBuilder()
- Specified by:
toBuilderin interfacecom.google.protobuf.Message- Specified by:
toBuilderin interfacecom.google.protobuf.MessageLite
-
newBuilderForType
protected AttributeContext.Auth.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
- Specified by:
newBuilderForTypein classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstance
public static AttributeContext.Auth getDefaultInstance()
-
parser
public static com.google.protobuf.Parser<AttributeContext.Auth> parser()
-
getParserForType
public com.google.protobuf.Parser<AttributeContext.Auth> getParserForType()
- Specified by:
getParserForTypein interfacecom.google.protobuf.Message- Specified by:
getParserForTypein interfacecom.google.protobuf.MessageLite- Overrides:
getParserForTypein classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstanceForType
public AttributeContext.Auth getDefaultInstanceForType()
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
-