OIDC CRI: change provider location

This commit is contained in:
nemunaire 2020-09-14 10:23:44 +02:00
parent 6aeca0226b
commit 3b6683cb55
1 changed files with 6 additions and 6 deletions

View File

@ -15,11 +15,11 @@ import (
)
var (
oidcClientID = ""
oidcSecret = ""
oidcClientID = ""
oidcSecret = ""
oidcRedirectURL = "https://srs.nemunai.re"
oauth2Config oauth2.Config
oidcVerifier *oidc.IDTokenVerifier
oauth2Config oauth2.Config
oidcVerifier *oidc.IDTokenVerifier
)
func init() {
@ -33,7 +33,7 @@ func init() {
func initializeOIDC() {
if oidcClientID != "" && oidcSecret != "" {
provider, err := oidc.NewProvider(context.Background(), "https://cri.epita.fr/oidc")
provider, err := oidc.NewProvider(context.Background(), "https://cri.epita.fr")
if err != nil {
log.Fatal("Unable to setup oidc:", err)
}
@ -51,7 +51,7 @@ func initializeOIDC() {
}
oidcConfig := oidc.Config{
ClientID: oidcClientID,
ClientID: oidcClientID,
}
oidcVerifier = provider.Verifier(&oidcConfig)
}