mirror of
https://github.com/alibaba/higress.git
synced 2026-06-09 04:37:31 +08:00
fix(oidc): fix Set-Cookie header corruption during session refresh (#3928)
Signed-off-by: jingze <daijingze.djz@alibaba-inc.com> Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -84,7 +84,11 @@ func onHttpRequestHeaders(ctx wrapper.HttpContext, config PluginConfig, log log.
|
||||
func onHttpResponseHeaders(ctx wrapper.HttpContext, config PluginConfig, log log.Log) types.Action {
|
||||
value := ctx.GetContext(oidc.SetCookieHeader)
|
||||
if value != nil {
|
||||
proxywasm.AddHttpResponseHeader(oidc.SetCookieHeader, value.(string))
|
||||
if cookies, ok := value.([]string); ok {
|
||||
for _, c := range cookies {
|
||||
proxywasm.AddHttpResponseHeader(oidc.SetCookieHeader, c)
|
||||
}
|
||||
}
|
||||
}
|
||||
config.oidcHandler.SetContext(nil)
|
||||
return types.ActionContinue
|
||||
|
||||
Reference in New Issue
Block a user