Skip to content
Snippets Groups Projects
Unverified Commit 2ea1a80c authored by Maksim Nabokikh's avatar Maksim Nabokikh Committed by GitHub
Browse files

fix: propagate http client to userInfo requests for OIDC connector (#2781)

parent 62bd7989
No related branches found
No related tags found
No related merge requests found
......@@ -260,7 +260,7 @@ func (c *oidcConnector) HandleCallback(s connector.Scopes, r *http.Request) (ide
if err != nil {
return identity, fmt.Errorf("oidc: failed to get token: %v", err)
}
return c.createIdentity(r.Context(), identity, token, createCaller)
return c.createIdentity(ctx, identity, token, createCaller)
}
// Refresh is used to refresh a session with the refresh token provided by the IdP
......@@ -271,6 +271,8 @@ func (c *oidcConnector) Refresh(ctx context.Context, s connector.Scopes, identit
return identity, fmt.Errorf("oidc: failed to unmarshal connector data: %v", err)
}
ctx = context.WithValue(ctx, oauth2.HTTPClient, c.httpClient)
t := &oauth2.Token{
RefreshToken: string(cd.RefreshToken),
Expiry: time.Now().Add(-time.Hour),
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment