
This adds the oauth2 provider `oidc`. It needs an additional argument, the OIDC discovery endpoint to figure out where the auth and token URLs are. Configuration is similar to setting up the Google Authentication with these changes: * `OAUTH2_PROVIDER = oidc` * `OAUTH2_OIDC_DISCOVERY_ENDPOINT = https://auth.exampe.org/discovery`
13 lines
437 B
Go
13 lines
437 B
Go
// Copyright 2017 Frédéric Guillot. All rights reserved.
|
|
// Use of this source code is governed by the Apache 2.0
|
|
// license that can be found in the LICENSE file.
|
|
|
|
package oauth2 // import "miniflux.app/oauth2"
|
|
import "context"
|
|
|
|
// Provider is an interface for OAuth2 providers.
|
|
type Provider interface {
|
|
GetUserExtraKey() string
|
|
GetRedirectURL(state string) string
|
|
GetProfile(ctx context.Context, code string) (*Profile, error)
|
|
}
|