feat: Support ForwardUsernameHeader field in the BasicAuth #5331
feat: Support ForwardUsernameHeader field in the BasicAuth #5331zirain merged 18 commits intoenvoyproxy:mainfrom
Conversation
…ection of SecurityPolicy. It enables the Envoy to forward the username of a successfully authenticated user to the backend services via a specified HTTP header. The field is optional. If it's not specified, the username will not be forwarded. Signed-off-by: Suren Raju <suren.1988@gmail.com>
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #5331 +/- ##
==========================================
+ Coverage 65.05% 65.11% +0.05%
==========================================
Files 213 213
Lines 33588 33586 -2
==========================================
+ Hits 21851 21869 +18
+ Misses 10405 10394 -11
+ Partials 1332 1323 -9 ☔ View full report in Codecov by Sentry. |
|
Hey can you run 'make testdata' and 'make generate' and commit those changes ? |
Signed-off-by: Suren Raju <suren.1988@gmail.com>
Signed-off-by: Suren Raju <suren.1988@gmail.com>
Signed-off-by: Suren Raju <suren.1988@gmail.com>
|
please send API PR first, otherwise there would be too much rework on conflict and naming. |
Signed-off-by: Suren Raju <suren.1988@gmail.com>
|
@zirain please review |
|
@surenraju can you make ci happy? |
Signed-off-by: Suren Raju <suren.1988@gmail.com>
Signed-off-by: Suren Raju <suren.1988@gmail.com>
Signed-off-by: Suren Raju <suren.1988@gmail.com>
|
@zirain tests are passing except conformance-test (v1.30.6) Wondering if this is related to my change. |
|
it just a flaky |
|
/retest |
|
This PR looks great! @surenraju could you please also modify the e2e test to add the username header and verify it in the forwarded request?
|
Signed-off-by: Suren Raju <suren.1988@gmail.com>
Signed-off-by: Suren Raju <suren.1988@gmail.com>
|
@surenraju Could you please add a line to the release note? |
Signed-off-by: Suren Raju <suren.1988@gmail.com>
Signed-off-by: Suren Raju <suren.1988@gmail.com>
Signed-off-by: Suren Raju <suren.1988@gmail.com>
Signed-off-by: Suren Raju <suren.1988@gmail.com>
Signed-off-by: Suren Raju <suren.1988@gmail.com>
Signed-off-by: Suren Raju <suren.1988@gmail.com>
Signed-off-by: Suren Raju <suren.1988@gmail.com>
|
/retest |
Signed-off-by: Suren Raju <suren.1988@gmail.com>
|
/retest |
1 similar comment
|
/retest |
|
@zirain @zhaohuabing all checks passed. Please review. |
What type of PR is this?
Type of PR
Feature
What this PR does / why we need it:
#2947
This PR introduces the
ForwardUsernameHeaderfield in theBasicAuthsection ofSecurityPolicy. It enables the Envoy to forward the username of a successfully authenticated user to the backend services via a specified HTTP header.The field is optional. If it's not specified, the username will not be forwarded.
Which issue(s) this PR fixes:
Fixes 2947
User-Facing Changes
Added
ForwardUsernameHeaderinBasicAuthofSecurityPolicyto enable username forwarding to backend services.Release Notes: No