feat: Return X509 certificate chain as the subject token.#1746
Merged
nbayati merged 8 commits intogoogleapis:mainfrom May 12, 2025
Merged
feat: Return X509 certificate chain as the subject token.#1746nbayati merged 8 commits intogoogleapis:mainfrom
nbayati merged 8 commits intogoogleapis:mainfrom
Conversation
The CertificateIdentityPoolSubjectTokenSupplier's subjectToken function now returns the full X.509 certificate chain, including the leaf certificate and any provided trust chain certificates, as a JSON array of base64-encoded strings. This chain is used as the subject token for mTLS authentication.
lqiu96
reviewed
May 8, 2025
oauth2_http/java/com/google/auth/oauth2/CertificateIdentityPoolSubjectTokenSupplier.java
Outdated
Show resolved
Hide resolved
lqiu96
reviewed
May 8, 2025
oauth2_http/java/com/google/auth/oauth2/CertificateIdentityPoolSubjectTokenSupplier.java
Outdated
Show resolved
Hide resolved
lqiu96
reviewed
May 8, 2025
oauth2_http/java/com/google/auth/oauth2/CertificateIdentityPoolSubjectTokenSupplier.java
Outdated
Show resolved
Hide resolved
lqiu96
reviewed
May 8, 2025
oauth2_http/java/com/google/auth/oauth2/CertificateIdentityPoolSubjectTokenSupplier.java
Show resolved
Hide resolved
…certificate to the private helper method.
lsirac
approved these changes
May 9, 2025
lqiu96
reviewed
May 9, 2025
oauth2_http/java/com/google/auth/oauth2/CertificateIdentityPoolSubjectTokenSupplier.java
Outdated
Show resolved
Hide resolved
lqiu96
reviewed
May 9, 2025
oauth2_http/java/com/google/auth/oauth2/CertificateIdentityPoolSubjectTokenSupplier.java
Outdated
Show resolved
Hide resolved
andyrzhao
approved these changes
May 9, 2025
Contributor
andyrzhao
left a comment
There was a problem hiding this comment.
LGTM with some minor comments.
oauth2_http/java/com/google/auth/oauth2/CertificateIdentityPoolSubjectTokenSupplier.java
Outdated
Show resolved
Hide resolved
oauth2_http/java/com/google/auth/oauth2/CertificateIdentityPoolSubjectTokenSupplier.java
Show resolved
Hide resolved
zhumin8
reviewed
May 9, 2025
oauth2_http/java/com/google/auth/oauth2/CertificateIdentityPoolSubjectTokenSupplier.java
Outdated
Show resolved
Hide resolved
zhumin8
reviewed
May 9, 2025
oauth2_http/java/com/google/auth/oauth2/CertificateIdentityPoolSubjectTokenSupplier.java
Outdated
Show resolved
Hide resolved
oauth2_http/java/com/google/auth/oauth2/CertificateIdentityPoolSubjectTokenSupplier.java
Outdated
Show resolved
Hide resolved
oauth2_http/java/com/google/auth/oauth2/CertificateIdentityPoolSubjectTokenSupplier.java
Outdated
Show resolved
Hide resolved
oauth2_http/java/com/google/auth/oauth2/CertificateIdentityPoolSubjectTokenSupplier.java
Outdated
Show resolved
Hide resolved
lqiu96
reviewed
May 9, 2025
...2_http/javatests/com/google/auth/oauth2/CertificateIdentityPoolSubjectTokenSupplierTest.java
Outdated
Show resolved
Hide resolved
lqiu96
reviewed
May 9, 2025
...2_http/javatests/com/google/auth/oauth2/CertificateIdentityPoolSubjectTokenSupplierTest.java
Outdated
Show resolved
Hide resolved
lqiu96
reviewed
May 9, 2025
...2_http/javatests/com/google/auth/oauth2/CertificateIdentityPoolSubjectTokenSupplierTest.java
Show resolved
Hide resolved
lqiu96
reviewed
May 9, 2025
zhumin8
reviewed
May 12, 2025
...2_http/javatests/com/google/auth/oauth2/CertificateIdentityPoolSubjectTokenSupplierTest.java
Show resolved
Hide resolved
svc-squareup-copybara
pushed a commit
to cashapp/misk
that referenced
this pull request
May 13, 2025
| Package | Type | Package file | Manager | Update | Change | |---|---|---|---|---|---| | [com.google.auth:google-auth-library-oauth2-http](https://github.com/googleapis/google-auth-library-java) | dependencies | misk/gradle/libs.versions.toml | gradle | minor | `1.34.0` -> `1.35.0` | | [com.google.auth:google-auth-library-credentials](https://github.com/googleapis/google-auth-library-java) | dependencies | misk/gradle/libs.versions.toml | gradle | minor | `1.34.0` -> `1.35.0` | | [software.amazon.awssdk:sdk-core](https://aws.amazon.com/sdkforjava) | dependencies | misk/gradle/libs.versions.toml | gradle | patch | `2.31.40` -> `2.31.41` | | [software.amazon.awssdk:sqs](https://aws.amazon.com/sdkforjava) | dependencies | misk/gradle/libs.versions.toml | gradle | patch | `2.31.40` -> `2.31.41` | | [software.amazon.awssdk:dynamodb-enhanced](https://aws.amazon.com/sdkforjava) | dependencies | misk/gradle/libs.versions.toml | gradle | patch | `2.31.40` -> `2.31.41` | | [software.amazon.awssdk:dynamodb](https://aws.amazon.com/sdkforjava) | dependencies | misk/gradle/libs.versions.toml | gradle | patch | `2.31.40` -> `2.31.41` | --- ### Release Notes <details> <summary>googleapis/google-auth-library-java (com.google.auth:google-auth-library-oauth2-http)</summary> ### [`v1.35.0`](https://github.com/googleapis/google-auth-library-java/blob/HEAD/CHANGELOG.md#1350-2025-05-12) ##### Features - Add support for mTLS authentication via X.509 certificates ([#​1736](googleapis/google-auth-library-java#1736)) ([b347603](googleapis/google-auth-library-java@b347603)) - Return X509 certificate chain as the subject token. ([#​1746](googleapis/google-auth-library-java#1746)) ([6d05be8](googleapis/google-auth-library-java@6d05be8)) ##### Bug Fixes - Handle optional fields in ExternalAccountCredentials with null JSON value gracefully ([#​1706](googleapis/google-auth-library-java#1706)) ([f1f306d](googleapis/google-auth-library-java@f1f306d)) </details> --- ### Configuration 📅 **Schedule**: Branch creation - "after 6pm every weekday,before 2am every weekday" in timezone Australia/Melbourne, Automerge - At any time (no schedule defined). 🚦 **Automerge**: Enabled. ♻ **Rebasing**: Never, or you tick the rebase/retry checkbox. 👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://github.com/renovatebot/renovate/discussions) if that's undesired. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate). GitOrigin-RevId: abc60fba8102e94da5ecb2e7537ccaf5d3d8628f
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
design: go/x509-auth-lib-redesign
The CertificateIdentityPoolSubjectTokenSupplier's subjectToken function now returns the full X509 certificate chain, including the leaf certificate and any provided trust chain certificates, as a JSON array of base64-encoded strings. This chain is used as the subject token for mTLS authentication.
Similar work was done in the python and Go libraries.