Repository navigation
docs(auth): fix invalid Javadoc tags, raw backticks, broken links, and dropped comments #15311
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -50,18 +50,19 @@ public class AwsCredentialSource extends ExternalAccountCredentials.CredentialSo | |||||||||||||
| final @Nullable String imdsv2SessionTokenUrl; | ||||||||||||||
|
|
||||||||||||||
| /** | ||||||||||||||
| * The source of the AWS credential. The credential source map must contain the | ||||||||||||||
| * `regional_cred_verification_url` field. | ||||||||||||||
| * The source of the AWS credential. The credential source map must contain the {@code | ||||||||||||||
| * regional_cred_verification_url} and {@code environment_id} fields. | ||||||||||||||
| * | ||||||||||||||
| * <p>The `regional_cred_verification_url` is the regional GetCallerIdentity action URL, used to | ||||||||||||||
| * determine the account ID and its roles. | ||||||||||||||
| * <p>The {@code regional_cred_verification_url} is the regional GetCallerIdentity action URL, | ||||||||||||||
| * used to determine the account ID and its roles. | ||||||||||||||
| * | ||||||||||||||
| * <p>The `environment_id` is the environment identifier, in the format “aws${version}”. This | ||||||||||||||
| * indicates whether breaking changes were introduced to the underlying AWS implementation. | ||||||||||||||
| * <p>The {@code environment_id} is the environment identifier, in the format {@code | ||||||||||||||
| * aws${version}}. This indicates whether breaking changes were introduced to the underlying AWS | ||||||||||||||
| * implementation. | ||||||||||||||
|
Comment on lines
+59
to
+61
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The
Suggested change
|
||||||||||||||
| * | ||||||||||||||
| * <p>The `region_url` identifies the targeted region. Optional. | ||||||||||||||
| * <p>The {@code region_url} identifies the targeted region. Optional. | ||||||||||||||
| * | ||||||||||||||
| * <p>The `url` locates the metadata server used to retrieve the AWS credentials. Optional. | ||||||||||||||
| * <p>The {@code url} locates the metadata server used to retrieve the AWS credentials. Optional. | ||||||||||||||
| */ | ||||||||||||||
| public AwsCredentialSource(Map<String, Object> credentialSourceMap) { | ||||||||||||||
| super(credentialSourceMap); | ||||||||||||||
|
|
||||||||||||||
| Original file line number | Diff line number | Diff line change | ||||||
|---|---|---|---|---|---|---|---|---|
|
|
@@ -279,8 +279,8 @@ public Builder setAwsSecurityCredentialsSupplier( | |||||||
| /** | ||||||||
| * Sets the AWS regional credential verification URL. If set, will override any credential | ||||||||
| * verification URL provided in the credential source. If not set, the credential verification | ||||||||
| * URL will default to | ||||||||
| * `https://sts.{region}.amazonaws.com?Action=GetCallerIdentity&Version=2011-06-15` | ||||||||
| * URL will default to {@code | ||||||||
| * https://sts.{region}.amazonaws.com?Action=GetCallerIdentity&Version=2011-06-15} | ||||||||
|
Comment on lines
+282
to
+283
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The default URL inside the
Suggested change
|
||||||||
| * | ||||||||
| * @param regionalCredentialVerificationUrlOverride the AWS credential verification url to set. | ||||||||
| * @return this {@code Builder} object | ||||||||
|
|
||||||||
| Original file line number | Diff line number | Diff line change | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -144,8 +144,8 @@ public class GdchCredentials extends GoogleCredentials { | |||||||||
| * external source for authentication to Google Cloud Platform, you must validate it before | ||||||||||
| * providing it to any Google API or library. Providing an unvalidated credential configuration to | ||||||||||
| * Google APIs can compromise the security of your systems and data. For more information, refer | ||||||||||
| * to {@see <a | ||||||||||
| * href="https://cloud.google.com/docs/authentication/external/externally-sourced-credentials">documentation</a>}. | ||||||||||
| * to <a | ||||||||||
| * href="https://docs.cloud.google.com/docs/authentication/client-libraries#external-credentials">documentation</a>. | ||||||||||
| * | ||||||||||
| * @param credentialsStream the stream with the credential definition. | ||||||||||
| * @return the credential defined by the credentialsStream. | ||||||||||
|
|
@@ -163,8 +163,8 @@ public static GdchCredentials fromStream(InputStream credentialsStream) throws I | |||||||||
| * external source for authentication to Google Cloud Platform, you must validate it before | ||||||||||
| * providing it to any Google API or library. Providing an unvalidated credential configuration to | ||||||||||
| * Google APIs can compromise the security of your systems and data. For more information, refer | ||||||||||
| * to {@see <a | ||||||||||
| * href="https://cloud.google.com/docs/authentication/external/externally-sourced-credentials">documentation</a>}. | ||||||||||
| * to <a | ||||||||||
| * href="https://docs.cloud.google.com/docs/authentication/client-libraries#external-credentials">documentation</a>. | ||||||||||
| * | ||||||||||
| * @param credentialsStream the stream with the credential definition. | ||||||||||
| * @param transportFactory HTTP transport factory, creates the transport used to get access | ||||||||||
|
|
@@ -285,7 +285,7 @@ static GdchCredentials fromPem(String privateKeyPem, GdchCredentials.Builder bui | |||||||||
| } | ||||||||||
|
|
||||||||||
| /** | ||||||||||
| * This method is obsolete. Please use {@link #createWithGdchAudience(String)}} instead. Create a | ||||||||||
| * This method is obsolete. Please use {@link #createWithGdchAudience(String)} instead. Create a | ||||||||||
| * copy of GDCH credentials with the specified audience. | ||||||||||
| * | ||||||||||
| * @param apiAudience The intended audience for GDCH credentials. | ||||||||||
|
|
@@ -377,8 +377,9 @@ public AccessToken refreshAccessToken() throws IOException { | |||||||||
| * Create a self-signed JWT for GDCH authentication flow. | ||||||||||
| * | ||||||||||
| * <p>The self-signed JWT is used to exchange access token from GDCH authentication | ||||||||||
| * (tokenServerUri), not for API call. It uses the serviceIdentityName as the `iss` and `sub` | ||||||||||
| * claim, and the tokenServerUri as the `aud` claim. The JWT is signed with the privateKey. | ||||||||||
| * (tokenServerUri), not for API call. It uses {@link #getIssuerSubjectValue(String, String)} as | ||||||||||
| * the {@code iss} and {@code sub} claims, and the tokenServerUri as the {@code aud} claim. The | ||||||||||
| * JWT is signed with the privateKey. | ||||||||||
| */ | ||||||||||
| String createAssertion(JsonFactory jsonFactory, long currentTime) throws IOException { | ||||||||||
| JsonWebSignature.Header header = new JsonWebSignature.Header(); | ||||||||||
|
|
@@ -407,8 +408,8 @@ String createAssertion(JsonFactory jsonFactory, long currentTime) throws IOExcep | |||||||||
| /** | ||||||||||
| * Get the issuer and subject value in the format GDCH token server required. | ||||||||||
| * | ||||||||||
| * <p>This value is specific to GDCH and combined parameter used for both `iss` and `sub` fields | ||||||||||
| * in JWT claim. | ||||||||||
| * <p>This value is specific to GDCH and combined parameter used for both {@code iss} and {@code | ||||||||||
| * sub} fields in JWT claim. | ||||||||||
|
Comment on lines
+411
to
+412
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The
Suggested change
|
||||||||||
| */ | ||||||||||
| @VisibleForTesting | ||||||||||
| static String getIssuerSubjectValue(String projectId, String serviceIdentityName) { | ||||||||||
|
|
||||||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The
{@code}tag is split across lines. In Javadoc, any whitespace (including newlines and leading spaces/asterisks) inside{@code ...}is preserved literally, which can cause the rendered HTML to contain an unwanted leading space or newline inside the code block. It is recommended to keep the entire{@code ...}tag on a single line.