| Package | Description |
|---|---|
| com.google.auth.oauth2 |
| Modifier and Type | Class and Description |
|---|---|
class |
AwsCredentials
Credentials representing an AWS third-party identity for calling Google APIs.
|
class |
CloudShellCredentials
OAuth2 credentials representing the built-in service account for Google Cloud Shell.
|
class |
ComputeEngineCredentials
OAuth2 credentials representing the built-in service account for a Google Compute Engine VM.
|
class |
ExternalAccountAuthorizedUserCredentials
OAuth2 credentials sourced using external identities through Workforce Identity Federation.
|
class |
ExternalAccountCredentials
Base external account credentials class.
|
class |
GdchCredentials |
class |
IdentityPoolCredentials
Url-sourced, file-sourced, or user provided supplier method-sourced external account credentials.
|
class |
ImpersonatedCredentials
ImpersonatedCredentials allowing credentials issued to a user or service account to impersonate
another.
|
class |
PluggableAuthCredentials
PluggableAuthCredentials enables the exchange of workload identity pool external credentials for
Google access tokens by retrieving 3rd party tokens through a user supplied executable.
|
class |
ServiceAccountCredentials
OAuth2 credentials representing a Service Account for calling Google APIs.
|
class |
UserCredentials
OAuth2 Credentials representing a user's identity and consent.
|
| Modifier and Type | Method and Description |
|---|---|
GoogleCredentials |
GoogleCredentials.Builder.build() |
static GoogleCredentials |
GoogleCredentials.create(AccessToken accessToken)
Returns the credentials instance from the given access token.
|
static GoogleCredentials |
GoogleCredentials.create(String universeDomain,
AccessToken accessToken)
Returns the credentials instance from the given access token and universe domain.
|
GoogleCredentials |
ServiceAccountCredentials.createDelegated(String user) |
GoogleCredentials |
GoogleCredentials.createDelegated(String user)
If the credentials support domain-wide delegation, creates a copy of the identity so that it
impersonates the specified user; otherwise, returns the same instance.
|
GoogleCredentials |
ServiceAccountCredentials.createScoped(Collection<String> newScopes)
Clones the service account with the specified scopes.
|
GoogleCredentials |
ImpersonatedCredentials.createScoped(Collection<String> scopes) |
GoogleCredentials |
GoogleCredentials.createScoped(Collection<String> scopes)
If the credentials support scopes, creates a copy of the identity with the specified scopes,
invalidates the existing scoped access token; otherwise, return the same instance.
|
GoogleCredentials |
ComputeEngineCredentials.createScoped(Collection<String> newScopes)
Clones the compute engine account with the specified scopes.
|
GoogleCredentials |
AwsCredentials.createScoped(Collection<String> newScopes)
Clones the AwsCredentials with the specified scopes.
|
GoogleCredentials |
ServiceAccountCredentials.createScoped(Collection<String> newScopes,
Collection<String> newDefaultScopes)
Clones the service account with the specified scopes.
|
GoogleCredentials |
GoogleCredentials.createScoped(Collection<String> scopes,
Collection<String> defaultScopes)
If the credentials support scopes, creates a copy of the identity with the specified scopes and
default scopes; otherwise, returns the same instance.
|
GoogleCredentials |
ComputeEngineCredentials.createScoped(Collection<String> newScopes,
Collection<String> newDefaultScopes)
Clones the compute engine account with the specified scopes and default scopes.
|
GoogleCredentials |
GoogleCredentials.createScoped(String... scopes)
If the credentials support scopes, creates a copy of the identity with the specified scopes;
otherwise, returns the same instance.
|
GoogleCredentials |
GoogleCredentials.createWithCustomRetryStrategy(boolean defaultRetriesEnabled)
If the credentials support automatic retries, creates a copy of the identity with the provided
retry strategy
|
GoogleCredentials |
GoogleCredentials.createWithQuotaProject(String quotaProject)
Creates a credential with the provided quota project.
|
static GoogleCredentials |
GoogleCredentials.fromStream(InputStream credentialsStream)
Returns credentials defined by a JSON file stream.
|
static GoogleCredentials |
GoogleCredentials.fromStream(InputStream credentialsStream,
HttpTransportFactory transportFactory)
Returns credentials defined by a JSON file stream.
|
static GoogleCredentials |
GoogleCredentials.getApplicationDefault()
Returns the Application Default Credentials.
|
static GoogleCredentials |
GoogleCredentials.getApplicationDefault(HttpTransportFactory transportFactory)
Returns the Application Default Credentials.
|
GoogleCredentials |
ImpersonatedCredentials.getSourceCredentials() |
GoogleCredentials |
ImpersonatedCredentials.Builder.getSourceCredentials() |
GoogleCredentials |
DownscopedCredentials.getSourceCredentials() |
| Modifier and Type | Method and Description |
|---|---|
static ImpersonatedCredentials |
ImpersonatedCredentials.create(GoogleCredentials sourceCredentials,
String targetPrincipal,
List<String> delegates,
List<String> scopes,
int lifetime) |
static ImpersonatedCredentials |
ImpersonatedCredentials.create(GoogleCredentials sourceCredentials,
String targetPrincipal,
List<String> delegates,
List<String> scopes,
int lifetime,
HttpTransportFactory transportFactory) |
static ImpersonatedCredentials |
ImpersonatedCredentials.create(GoogleCredentials sourceCredentials,
String targetPrincipal,
List<String> delegates,
List<String> scopes,
int lifetime,
HttpTransportFactory transportFactory,
String quotaProjectId) |
static ImpersonatedCredentials |
ImpersonatedCredentials.create(GoogleCredentials sourceCredentials,
String targetPrincipal,
List<String> delegates,
List<String> scopes,
int lifetime,
HttpTransportFactory transportFactory,
String quotaProjectId,
String iamEndpointOverride) |
DownscopedCredentials.Builder |
DownscopedCredentials.Builder.setSourceCredential(GoogleCredentials sourceCredential)
Sets the required source credential used to acquire the downscoped credential.
|
ImpersonatedCredentials.Builder |
ImpersonatedCredentials.Builder.setSourceCredentials(GoogleCredentials sourceCredentials) |
| Constructor and Description |
|---|
Builder(GoogleCredentials credentials) |
Builder(GoogleCredentials sourceCredentials,
String targetPrincipal)
Deprecated.
Use
Builder(ImpersonatedCredentials) instead. This constructor will be
removed in a future release. |
Copyright © 2024 Google. All rights reserved.