passwdidp

package
v0.14.0 Latest Latest
Warning

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

Go to latest
Published: Apr 24, 2024 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

View Source
const (
	OrderWhiteLabelTemplateFS = 0
	OrderTemplateFSOverwrite  = OrderWhiteLabelTemplateFS - 1000
)
View Source
const (
	PwdAuthPropertiesPrefix = "security.idp.internal"
)

Variables

View Source
var Module = &bootstrap.Module{
	Name:       "password IDP",
	Precedence: security.MaxSecurityPrecedence - 100,
	Options: []fx.Option{
		appconfig.FxEmbeddedDefaults(defaultConfigFS),
		fx.Provide(BindPwdAuthProperties),
		fx.Invoke(register),
	},
}

Functions

func NewWhiteLabelLoginFormController

func NewWhiteLabelLoginFormController() web.Controller

func Use

func Use()

Types

type Options

type Options func(opt *option)

func WithMFAListeners

func WithMFAListeners(listeners ...passwd.MFAEventListenerFunc) Options

func WithProperties

func WithProperties(props *PwdAuthProperties) Options

type PasswdIdentityProvider

type PasswdIdentityProvider struct {
	PasswdIdpDetails
}

PasswdIdentityProvider implements idp.IdentityProvider and idp.AuthenticationFlowAware

func NewIdentityProvider

func NewIdentityProvider(opts ...PasswdIdpOptions) *PasswdIdentityProvider

func (PasswdIdentityProvider) AuthenticationFlow

func (s PasswdIdentityProvider) AuthenticationFlow() idp.AuthenticationFlow

func (PasswdIdentityProvider) Domain

func (s PasswdIdentityProvider) Domain() string

type PasswdIdpDetails

type PasswdIdpDetails struct {
	Domain string
}

type PasswdIdpOptions

type PasswdIdpOptions func(opt *PasswdIdpDetails)

type PasswordIdpSecurityConfigurer

type PasswordIdpSecurityConfigurer struct {
	// contains filtered or unexported fields
}

PasswordIdpSecurityConfigurer implements authserver.IdpSecurityConfigurer

func NewPasswordIdpSecurityConfigurer

func NewPasswordIdpSecurityConfigurer(opts ...Options) *PasswordIdpSecurityConfigurer

func (*PasswordIdpSecurityConfigurer) Configure

type PwdAuthEndpointProperties

type PwdAuthEndpointProperties struct {
	FormLogin            string `json:"form-login"`
	FormLoginProcess     string `json:"form-login-process"`
	FormLoginError       string `json:"form-login-error"`
	OtpVerify            string `json:"otp-verify"`
	OtpVerifyProcess     string `json:"otp-verify-process"`
	OtpVerifyResend      string `json:"otp-verify-resend"`
	OtpVerifyError       string `json:"otp-verify-error"`
	ResetPasswordPageUrl string `json:"reset-password-page-url"`
}

type PwdAuthMfaProperties

type PwdAuthMfaProperties struct {
	Enabled        bool           `json:"enabled"`
	OtpLength      uint           `json:"otp-length"`
	OtpSecretSize  uint           `json:"otp-secret-size"`
	OtpTTL         utils.Duration `json:"otp-ttl"`
	OtpMaxAttempts uint           `json:"otp-max-attempts"`
	OtpResendLimit uint           `json:"otp-resend-limit"`
}

type PwdAuthProperties

type PwdAuthProperties struct {
	Enabled                   bool                      `json:"enabled"`
	Domain                    string                    `json:"domain"`
	SessionExpiredRedirectUrl string                    `json:"session-expired-redirect-url"`
	Endpoints                 PwdAuthEndpointProperties `json:"endpoints"`
	MFA                       PwdAuthMfaProperties      `json:"mfa"`
	RememberMe                RememberMeProperties      `json:"remember-me"`
}

func NewPwdAuthProperties

func NewPwdAuthProperties() *PwdAuthProperties

type RememberMeProperties

type RememberMeProperties struct {
	CookieDomain    string         `json:"cookie-domain"`
	UseSecureCookie bool           `json:"use-secure-cookie"`
	CookieValidity  utils.Duration `json:"cookie-validity"`
}

Jump to

Keyboard shortcuts

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