Fixes #2 : Adds Microsoft Azure Active Directory provider support (#5)

This commit is contained in:
bdd 2019-01-05 01:28:13 -08:00 committed by GitHub
parent 46ac3293a8
commit 5a75ace403
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
22 changed files with 205 additions and 4 deletions

View file

@ -8,12 +8,15 @@ import (
"time"
oidc "github.com/pomerium/go-oidc"
"golang.org/x/oauth2"
"github.com/pomerium/pomerium/internal/log"
"github.com/pomerium/pomerium/internal/sessions"
"golang.org/x/oauth2"
)
const (
// AzureProviderName identifies the Azure provider
AzureProviderName = "azure"
// GoogleProviderName identifies the Google provider
GoogleProviderName = "google"
// OIDCProviderName identifes a generic OpenID connect provider
@ -44,6 +47,12 @@ func New(provider string, p *ProviderData) (Provider, error) {
return nil, err
}
return p, nil
case AzureProviderName:
p, err := NewAzureProvider(p)
if err != nil {
return nil, err
}
return p, nil
case OktaProviderName:
p, err := NewOktaProvider(p)
if err != nil {