You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
My Expectation:
After processing the request, APISIX should forward a modified request to the upstream. The response from httpbin.org should show that:
The X-User-ID header is present with the value of the sub claim.
The X-Username header is present with the value of the username claim.
The original Authorization header has been removed.
Operating system (run uname -a): Linux fdb825996d73 4.19.90-52.22.v2207.ky10.x86_64 change: added doc of how to load plugin. #1 SMP Tue Mar 14 12:19:10 CST 2023 x86_64 GNU/Linux
OpenResty / Nginx version (run openresty -V or nginx -V): nginx version: openresty/1.27.1.2
Description
Consumer Configuration:
Route Configuration:
JWT Payload:
{ "key": "shared-app-key", "username": "lyz", "iss": "user-service", "sub": "41062bf0-ba38-4993-aa11-edb7cee1ac5c", "aud": [ "api-gateway" ], "exp": 1760082649, "iat": 1759996249, "jti": "1e010168-2d9b-44be-b9c5-52934e778383" }Request Command:
My Expectation:
After processing the request, APISIX should forward a modified request to the upstream. The response from httpbin.org should show that:
{ "headers": { "Accept": "*/*", "Host": "httpbin.org", "User-Agent": "curl/8.5.0", "X-Amzn-Trace-Id": "...", "X-Consumer-Username": "shared-app", "X-Forwarded-Host": "10.30.60.116", "X-User-ID": "41062bf0-ba38-4993-aa11-edb7cee1ac5c", "X-Username": "lyz" } }Actual Result:
no expect header.
{ "headers": { "Accept": "*/*", "Authorization": "Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...", "Host": "10.30.60.116", "User-Agent": "curl/8.5.0", "X-Amzn-Trace-Id": "Root=1-68e77893-36d0062d14cbafee30970631", "X-Consumer-Username": "shared-app-key", "X-Forwarded-Host": "10.30.60.116" } }Environment
apisix version): 3.13.0uname -a): Linux fdb825996d73 4.19.90-52.22.v2207.ky10.x86_64 change: added doc of how to load plugin. #1 SMP Tue Mar 14 12:19:10 CST 2023 x86_64 GNU/Linuxopenresty -Vornginx -V): nginx version: openresty/1.27.1.2