resolvedldap

package
v0.29.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 13, 2024 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrUnexpectedUpstreamLDAPError is returned by Login when there was an unexpected error during LDAP auth.
	// The error returned from Login() should be compared to this using errors.Is().
	ErrUnexpectedUpstreamLDAPError = &fosite.RFC6749Error{
		ErrorField:       "error",
		DescriptionField: "Unexpected error during upstream LDAP authentication.",
		CodeField:        http.StatusBadGateway,
	}

	// ErrAccessDeniedDueToUsernamePasswordNotAccepted is returned by Login when the LDAP auth failed due to a
	// bad username or password. Due to the way that fosite implements RFC6749Error.Is(), you must use "=="
	// to compare this error to an error returned from Login().
	ErrAccessDeniedDueToUsernamePasswordNotAccepted = &fosite.RFC6749Error{
		ErrorField:       "access_denied",
		DescriptionField: "The resource owner or authorization server denied the request.",
		HintField:        "Username/password not accepted by LDAP provider.",
		CodeField:        http.StatusForbidden,
	}
)

These are special errors that can be returned by Login for a FederationDomainResolvedLDAPIdentityProvider.

Functions

This section is empty.

Types

type FederationDomainResolvedLDAPIdentityProvider

type FederationDomainResolvedLDAPIdentityProvider struct {
	DisplayName         string
	Provider            upstreamprovider.UpstreamLDAPIdentityProviderI
	SessionProviderType psession.ProviderType
	Transforms          *idtransform.TransformationPipeline
}

FederationDomainResolvedLDAPIdentityProvider represents a FederationDomainIdentityProvider which has been resolved dynamically based on the currently loaded IDP CRs to include the provider.UpstreamLDAPIdentityProviderI and other metadata about the provider.

func (*FederationDomainResolvedLDAPIdentityProvider) ApplyIDPSpecificSessionDataToSession

func (p *FederationDomainResolvedLDAPIdentityProvider) ApplyIDPSpecificSessionDataToSession(session *psession.CustomSessionData, idpSpecificSessionData interface{})

func (*FederationDomainResolvedLDAPIdentityProvider) CloneIDPSpecificSessionDataFromSession

func (p *FederationDomainResolvedLDAPIdentityProvider) CloneIDPSpecificSessionDataFromSession(session *psession.CustomSessionData) interface{}

func (*FederationDomainResolvedLDAPIdentityProvider) GetDisplayName

func (*FederationDomainResolvedLDAPIdentityProvider) GetIDPDiscoveryFlows

func (*FederationDomainResolvedLDAPIdentityProvider) GetIDPDiscoveryType

func (*FederationDomainResolvedLDAPIdentityProvider) GetProvider

func (*FederationDomainResolvedLDAPIdentityProvider) GetSessionProviderType

func (*FederationDomainResolvedLDAPIdentityProvider) GetTransforms

func (*FederationDomainResolvedLDAPIdentityProvider) Login

func (*FederationDomainResolvedLDAPIdentityProvider) LoginFromCallback

func (*FederationDomainResolvedLDAPIdentityProvider) UpstreamAuthorizeRedirectURL

func (p *FederationDomainResolvedLDAPIdentityProvider) UpstreamAuthorizeRedirectURL(state *resolvedprovider.UpstreamAuthorizeRequestState, downstreamIssuerURL string) (string, error)

func (*FederationDomainResolvedLDAPIdentityProvider) UpstreamRefresh

func (p *FederationDomainResolvedLDAPIdentityProvider) UpstreamRefresh(
	ctx context.Context,
	identity *resolvedprovider.Identity,
) (refreshedIdentity *resolvedprovider.RefreshedIdentity, err error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL