-
Notifications
You must be signed in to change notification settings - Fork 460
feat: validate JWT token and use projected token #5871
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
Conversation
Codecov ReportAttention: Patch coverage is
❌ Your patch status has failed because the patch coverage (32.29%) is below the target coverage (60.00%). You can increase the patch coverage or adjust the target coverage. Additional details and impacted files@@ Coverage Diff @@
## main #5871 +/- ##
==========================================
+ Coverage 65.80% 65.81% +0.01%
==========================================
Files 217 217
Lines 36020 36077 +57
==========================================
+ Hits 23703 23745 +42
- Misses 10836 10857 +21
+ Partials 1481 1475 -6 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
c4308f3
to
92ad344
Compare
I will seperate feature with infrastructure controller namespace into separate PR |
9be1dad
to
a13a272
Compare
@cnvergence Talked with @arkodg offline, and he mentioned that we don't need to support Example: JWT claim: "username": "system:serviceaccount:default:envoy-default-eg-e41e7b31" We can construct the expected service account using the @arkodg feel free to add anything if I haven't captured our discussion correctly. |
d77b9e6
to
8ed4cda
Compare
99dcc03
to
726f64f
Compare
Signed-off-by: Karol Szwaj <[email protected]>
Signed-off-by: Karol Szwaj <[email protected]>
Signed-off-by: Karol Szwaj <[email protected]>
Signed-off-by: Karol Szwaj <[email protected]>
Signed-off-by: Karol Szwaj <[email protected]>
Signed-off-by: Karol Szwaj <[email protected]>
Signed-off-by: Karol Szwaj <[email protected]>
Signed-off-by: Karol Szwaj <[email protected]>
Signed-off-by: Karol Szwaj <[email protected]>
Signed-off-by: Karol Szwaj <[email protected]>
This reverts commit b2fa2ca. Signed-off-by: Karol Szwaj <[email protected]>
Signed-off-by: Karol Szwaj <[email protected]>
Signed-off-by: Karol Szwaj <[email protected]>
Signed-off-by: Huabing (Robin) Zhao <[email protected]>
Signed-off-by: Karol Szwaj <[email protected]>
Signed-off-by: Karol Szwaj <[email protected]>
726f64f
to
6f0a844
Compare
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.
LGTM.
Discussed with @arkodg , to prevent an envoy from requesting xDS not belong to it, we also need to enforce authz, which can be addressed in a follow-up PR.
Or you can simply revert b0748a0 to add pod check back @cnvergence
This reverts commit b0748a0. Signed-off-by: Huabing (Robin) Zhao <[email protected]>
654a617
to
7049ed6
Compare
Signed-off-by: Karol Szwaj <[email protected]>
* Add proxyMetadata to xds config and validate JWT Signed-off-by: Karol Szwaj <[email protected]> * Add controller namespace to infra Signed-off-by: Karol Szwaj <[email protected]> * Add Metadata envoy bootstrap struct Signed-off-by: Karol Szwaj <[email protected]> * Add release note Signed-off-by: Karol Szwaj <[email protected]> * fix lint Signed-off-by: Karol Szwaj <[email protected]> * fix doc Signed-off-by: Karol Szwaj <[email protected]> * use projected service account tokens with eg audience Signed-off-by: Karol Szwaj <[email protected]> * lint code Signed-off-by: Karol Szwaj <[email protected]> * make gen Signed-off-by: Karol Szwaj <[email protected]> * make gen Signed-off-by: Karol Szwaj <[email protected]> * Revert "Add controller namespace to infra" This reverts commit b2fa2caf58982432e5d5b31bd7d95a5ad523ed5e. Signed-off-by: Karol Szwaj <[email protected]> * fetch the node id and initial metadata from first msg Signed-off-by: Karol Szwaj <[email protected]> * update codegen Signed-off-by: Karol Szwaj <[email protected]> * verify service account Signed-off-by: Huabing (Robin) Zhao <[email protected]> * validate only sa Signed-off-by: Karol Szwaj <[email protected]> * add local hash name func Signed-off-by: Karol Szwaj <[email protected]> * Verify pod name for authz This reverts commit b0748a066c9f6a41920df95f728ace5f84ed1acb. Signed-off-by: Huabing (Robin) Zhao <[email protected]> * lint code Signed-off-by: Karol Szwaj <[email protected]> --------- Signed-off-by: Karol Szwaj <[email protected]> Signed-off-by: Huabing (Robin) Zhao <[email protected]> Co-authored-by: Huabing (Robin) Zhao <[email protected]> Signed-off-by: melsal13 <[email protected]>
What type of PR is this?
What this PR does / why we need it:
Which issue(s) this PR fixes:
Fixes #5863
Followup to the #5137
Release Notes: Yes