mirror of
https://github.com/alibaba/higress.git
synced 2026-02-06 23:21:08 +08:00
fix wasm-go/jwt-auth claims_to_headers bug (#2057)
Co-authored-by: Kent Dong <ch3cho@qq.com>
This commit is contained in:
@@ -26,8 +26,9 @@ func claimsToHeader(claims map[string]any, cth []cfg.ClaimsToHeader) {
|
||||
if v, ok := claims[cth[i].Claim]; ok {
|
||||
if *cth[i].Override {
|
||||
proxywasm.ReplaceHttpRequestHeader(cth[i].Header, fmt.Sprint(v))
|
||||
} else {
|
||||
proxywasm.AddHttpRequestHeader(cth[i].Header, fmt.Sprint(v))
|
||||
}
|
||||
proxywasm.AddHttpRequestHeader(cth[i].Header, fmt.Sprint(v))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user