From b514fe0cebe5a294e0cf97b7b5349e6a523dc7b2 Mon Sep 17 00:00:00 2001 From: Jeff Ching Date: Tue, 26 Jan 2021 13:24:04 -0800 Subject: [PATCH] feat: promote IdToken and JWT features (#538) These features have been available for months and have not received bug reports. --- .../java/com/google/auth/oauth2/ComputeEngineCredentials.java | 2 -- oauth2_http/java/com/google/auth/oauth2/IdToken.java | 2 -- .../java/com/google/auth/oauth2/IdTokenCredentials.java | 2 -- oauth2_http/java/com/google/auth/oauth2/IdTokenProvider.java | 2 -- .../java/com/google/auth/oauth2/ImpersonatedCredentials.java | 2 -- oauth2_http/java/com/google/auth/oauth2/JwtProvider.java | 3 --- .../java/com/google/auth/oauth2/ServiceAccountCredentials.java | 2 -- oauth2_http/java/com/google/auth/oauth2/TokenVerifier.java | 2 -- 8 files changed, 17 deletions(-) diff --git a/oauth2_http/java/com/google/auth/oauth2/ComputeEngineCredentials.java b/oauth2_http/java/com/google/auth/oauth2/ComputeEngineCredentials.java index f4e95c2c9..ede42cee9 100644 --- a/oauth2_http/java/com/google/auth/oauth2/ComputeEngineCredentials.java +++ b/oauth2_http/java/com/google/auth/oauth2/ComputeEngineCredentials.java @@ -42,7 +42,6 @@ import com.google.api.client.util.GenericData; import com.google.auth.ServiceAccountSigner; import com.google.auth.http.HttpTransportFactory; -import com.google.common.annotations.Beta; import com.google.common.base.Joiner; import com.google.common.base.MoreObjects; import com.google.common.collect.ImmutableSet; @@ -212,7 +211,6 @@ public AccessToken refreshAccessToken() throws IOException { * @throws IOException if the attempt to get an IdToken failed * @return IdToken object which includes the raw id_token, JsonWebSignature */ - @Beta @Override public IdToken idTokenWithAudience(String targetAudience, List options) throws IOException { diff --git a/oauth2_http/java/com/google/auth/oauth2/IdToken.java b/oauth2_http/java/com/google/auth/oauth2/IdToken.java index 51986799a..ccd670bba 100644 --- a/oauth2_http/java/com/google/auth/oauth2/IdToken.java +++ b/oauth2_http/java/com/google/auth/oauth2/IdToken.java @@ -33,7 +33,6 @@ import com.google.api.client.json.JsonFactory; import com.google.api.client.json.webtoken.JsonWebSignature; -import com.google.common.annotations.Beta; import com.google.common.base.MoreObjects; import java.io.IOException; import java.io.ObjectInputStream; @@ -43,7 +42,6 @@ import java.util.Objects; /** Represents a temporary IdToken and its JsonWebSignature object */ -@Beta public class IdToken extends AccessToken implements Serializable { private static final long serialVersionUID = -8514239465808977353L; diff --git a/oauth2_http/java/com/google/auth/oauth2/IdTokenCredentials.java b/oauth2_http/java/com/google/auth/oauth2/IdTokenCredentials.java index 6b827c5f9..5629d4e81 100644 --- a/oauth2_http/java/com/google/auth/oauth2/IdTokenCredentials.java +++ b/oauth2_http/java/com/google/auth/oauth2/IdTokenCredentials.java @@ -32,7 +32,6 @@ package com.google.auth.oauth2; import com.google.api.client.util.Preconditions; -import com.google.common.annotations.Beta; import com.google.common.base.MoreObjects; import java.io.IOException; import java.util.List; @@ -101,7 +100,6 @@ * System.out.println(tokenCredential.getIdToken().getJsonWebSignature().getPayload().getExpirationTimeSeconds()); * */ -@Beta public class IdTokenCredentials extends OAuth2Credentials { private static final long serialVersionUID = -2133257318957588431L; diff --git a/oauth2_http/java/com/google/auth/oauth2/IdTokenProvider.java b/oauth2_http/java/com/google/auth/oauth2/IdTokenProvider.java index 83a8d6242..c5b9e9c44 100644 --- a/oauth2_http/java/com/google/auth/oauth2/IdTokenProvider.java +++ b/oauth2_http/java/com/google/auth/oauth2/IdTokenProvider.java @@ -31,12 +31,10 @@ package com.google.auth.oauth2; -import com.google.common.annotations.Beta; import java.io.IOException; import java.util.List; /** Interface for an Google OIDC token provider. This type represents a google issued OIDC token. */ -@Beta public interface IdTokenProvider { /** diff --git a/oauth2_http/java/com/google/auth/oauth2/ImpersonatedCredentials.java b/oauth2_http/java/com/google/auth/oauth2/ImpersonatedCredentials.java index 91e917a06..6ddb116cc 100644 --- a/oauth2_http/java/com/google/auth/oauth2/ImpersonatedCredentials.java +++ b/oauth2_http/java/com/google/auth/oauth2/ImpersonatedCredentials.java @@ -45,7 +45,6 @@ import com.google.auth.ServiceAccountSigner; import com.google.auth.http.HttpCredentialsAdapter; import com.google.auth.http.HttpTransportFactory; -import com.google.common.annotations.Beta; import com.google.common.base.MoreObjects; import com.google.common.collect.ImmutableMap; import java.io.IOException; @@ -303,7 +302,6 @@ public AccessToken refreshAccessToken() throws IOException { * @return IdToken object which includes the raw id_token, expiration, and audience * @throws IOException if the attempt to get an ID token failed */ - @Beta @Override public IdToken idTokenWithAudience(String targetAudience, List options) throws IOException { diff --git a/oauth2_http/java/com/google/auth/oauth2/JwtProvider.java b/oauth2_http/java/com/google/auth/oauth2/JwtProvider.java index 7a2352ac5..0e25d20e6 100644 --- a/oauth2_http/java/com/google/auth/oauth2/JwtProvider.java +++ b/oauth2_http/java/com/google/auth/oauth2/JwtProvider.java @@ -31,10 +31,7 @@ package com.google.auth.oauth2; -import com.google.common.annotations.Beta; - /** Interface for creating custom JWT tokens */ -@Beta public interface JwtProvider { /** diff --git a/oauth2_http/java/com/google/auth/oauth2/ServiceAccountCredentials.java b/oauth2_http/java/com/google/auth/oauth2/ServiceAccountCredentials.java index 64b5d0af2..e12f8d412 100644 --- a/oauth2_http/java/com/google/auth/oauth2/ServiceAccountCredentials.java +++ b/oauth2_http/java/com/google/auth/oauth2/ServiceAccountCredentials.java @@ -55,7 +55,6 @@ import com.google.api.client.util.SecurityUtils; import com.google.auth.ServiceAccountSigner; import com.google.auth.http.HttpTransportFactory; -import com.google.common.annotations.Beta; import com.google.common.annotations.VisibleForTesting; import com.google.common.base.MoreObjects; import com.google.common.collect.ImmutableSet; @@ -476,7 +475,6 @@ public boolean isRequired(HttpResponse response) { * @throws IOException if the attempt to get an IdToken failed * @return IdToken object which includes the raw id_token, expiration and audience */ - @Beta @Override public IdToken idTokenWithAudience(String targetAudience, List