debugging for analyzing token

This commit is contained in:
2023-11-06 18:15:03 +01:00
parent c4317b7503
commit 5828a9a5a2
6 changed files with 23 additions and 5 deletions

View File

@ -8,6 +8,8 @@ import (
"net/http"
"golang.org/x/oauth2"
"github.com/sirupsen/logrus"
)
// GenericOAuth provider
@ -29,7 +31,7 @@ func (o *GenericOAuth) Name() string {
}
// Setup performs validation and setup
func (o *GenericOAuth) Setup() error {
func (o *GenericOAuth) Setup(log *logrus.Logger) error {
// Check parmas
if o.AuthURL == "" || o.TokenURL == "" || o.UserURL == "" || o.ClientID == "" || o.ClientSecret == "" {
return errors.New("providers.generic-oauth.auth-url, providers.generic-oauth.token-url, providers.generic-oauth.user-url, providers.generic-oauth.client-id, providers.generic-oauth.client-secret must be set")