mirror of
https://github.com/pomerium/pomerium.git
synced 2025-08-03 08:50:42 +02:00
apple: fix userinfo (#3974)
This commit is contained in:
parent
ad35915782
commit
f2a5bda162
2 changed files with 60 additions and 67 deletions
|
@ -121,16 +121,16 @@ func (cs *Store) LoadSession(r *http.Request) (string, error) {
|
|||
if len(cookies) == 0 {
|
||||
return "", sessions.ErrNoSessionFound
|
||||
}
|
||||
var err error
|
||||
for _, cookie := range cookies {
|
||||
jwt := loadChunkedCookie(r, cookie)
|
||||
|
||||
session := &sessions.State{}
|
||||
err := cs.decoder.Unmarshal([]byte(jwt), session)
|
||||
err = cs.decoder.Unmarshal([]byte(jwt), session)
|
||||
if err == nil {
|
||||
return jwt, nil
|
||||
}
|
||||
}
|
||||
return "", sessions.ErrMalformed
|
||||
return "", fmt.Errorf("%w: %s", sessions.ErrMalformed, err)
|
||||
}
|
||||
|
||||
// SaveSession saves a session state to a request's cookie store.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue