diff --git a/oauth2_http/java/com/google/auth/oauth2/ServiceAccountCredentials.java b/oauth2_http/java/com/google/auth/oauth2/ServiceAccountCredentials.java index c0b3cab98..377b4dbf1 100644 --- a/oauth2_http/java/com/google/auth/oauth2/ServiceAccountCredentials.java +++ b/oauth2_http/java/com/google/auth/oauth2/ServiceAccountCredentials.java @@ -609,7 +609,10 @@ public boolean isRequired(HttpResponse response) { response = request.execute(); } catch (IOException e) { throw new IOException( - String.format("Error getting access token for service account: %s", e.getMessage()), e); + String.format( + "Error getting access token for service account: %s, iss: %s", + e.getMessage(), getIssuer()), + e); } GenericData responseData = response.parseAs(GenericData.class); @@ -648,7 +651,16 @@ public IdToken idTokenWithAudience(String targetAudience, List