app_totp

package
v0.7.6 Latest Latest
Warning

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

Go to latest
Published: Sep 6, 2024 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

View Source
const (
	SetupNonceName  = "app-totp--setup--nonce"
	SetupNonceKey   = "app-totp--setup--form"
	RevokeNonceName = "app-totp--revoke--nonce"
	RevokeNonceKey  = "app-totp--revoke--form"
	ManageNonceName = "app-totp--manage--nonce"
	ManageNonceKey  = "app-totp--manage--form"
)
View Source
const Tag feature.Tag = "site-auth-otp-app-totp"

Variables

This section is empty.

Functions

This section is empty.

Types

type CFeature

type CFeature struct {
	site.CSiteFeature[MakeFeature]
	// contains filtered or unexported fields
}

func (*CFeature) Build

func (f *CFeature) Build(b feature.Buildable) (err error)

func (*CFeature) CurrentUserFactorsReady

func (f *CFeature) CurrentUserFactorsReady(r *http.Request) (names []string)

func (*CFeature) CurrentUserFactorsReadyCount

func (f *CFeature) CurrentUserFactorsReadyCount(r *http.Request) (count int)

func (*CFeature) Init

func (f *CFeature) Init(this interface{})

func (*CFeature) IsMultiFactorBackup

func (f *CFeature) IsMultiFactorBackup() (backup bool)

func (*CFeature) Make

func (f *CFeature) Make() (feat Feature)

func (*CFeature) MakeHandleSiteSettingsPanel

func (f *CFeature) MakeHandleSiteSettingsPanel(settingsPath string, saf feature.SiteAuthFeature) (serve http.HandlerFunc)

func (*CFeature) MakeServeSiteSettingsPanel

func (f *CFeature) MakeServeSiteSettingsPanel(settingsPath string, saf feature.SiteAuthFeature) (serve http.HandlerFunc)

func (*CFeature) ProcessChallenge

func (f *CFeature) ProcessChallenge(name, challenge string, saf feature.SiteAuthFeature, claims *feature.CSiteAuthClaims, w http.ResponseWriter, r *http.Request) (handled bool, redirect string)

func (*CFeature) ProcessSetupPage

func (f *CFeature) ProcessSetupPage(saf feature.SiteAuthFeature, w http.ResponseWriter, r *http.Request) (handled bool)

func (*CFeature) ProcessVerification

func (f *CFeature) ProcessVerification(verifyTarget, name, challenge string, saf feature.SiteAuthFeature, claims *feature.CSiteAuthClaims, w http.ResponseWriter, r *http.Request) (handled bool, redirect string)

func (*CFeature) ResetUserFactors

func (f *CFeature) ResetUserFactors(r *http.Request, eid string) (err error)

func (*CFeature) ServeManagePage

func (f *CFeature) ServeManagePage(settingsPath string, saf feature.SiteAuthFeature, w http.ResponseWriter, r *http.Request) (handled bool, redirect string)

func (*CFeature) ServeRevokePage

func (f *CFeature) ServeRevokePage(settingsPath string, saf feature.SiteAuthFeature, w http.ResponseWriter, r *http.Request) (handled bool, redirect string)

func (*CFeature) SetupSiteAuthProvider

func (f *CFeature) SetupSiteAuthProvider(saf feature.SiteAuthFeature)

func (*CFeature) SiteAuthSettingsPanel

func (f *CFeature) SiteAuthSettingsPanel(settingsPath string, saf feature.SiteAuthFeature) (serve, handle http.HandlerFunc)

func (*CFeature) SiteFeatureInfo

func (f *CFeature) SiteFeatureInfo(r *http.Request) (info *feature.CSiteFeatureInfo)

func (*CFeature) SiteFeatureMenu

func (f *CFeature) SiteFeatureMenu(r *http.Request) (m menu.Menu)

func (*CFeature) SiteMultiFactorInfo

func (f *CFeature) SiteMultiFactorInfo(r *http.Request) (info *feature.CSiteAuthMultiFactorInfo)

func (*CFeature) SiteMultiFactorKey

func (f *CFeature) SiteMultiFactorKey() (key string)

func (*CFeature) SiteMultiFactorLabel

func (f *CFeature) SiteMultiFactorLabel(printer *message.Printer) (label string)

func (*CFeature) SiteUserSetupStageHandler

func (f *CFeature) SiteUserSetupStageHandler(saf feature.SiteAuthFeature, w http.ResponseWriter, r *http.Request)

func (*CFeature) SiteUserSetupStageReady

func (f *CFeature) SiteUserSetupStageReady(eid string, r *http.Request) (ready bool)

func (*CFeature) Startup

func (f *CFeature) Startup(ctx *cli.Context) (err error)

func (*CFeature) UserActions

func (f *CFeature) UserActions() (list feature.Actions)

func (*CFeature) VerifyClaimFactor

func (f *CFeature) VerifyClaimFactor(claim *feature.CSiteAuthClaimsFactor, saf feature.SiteAuthFeature, r *http.Request) (verified bool)

type Feature

type Feature interface {
	feature.SiteFeature
	feature.SiteMultiFactorProvider
}

type MakeFeature

type MakeFeature interface {
	feature.SiteMakeFeature[MakeFeature]

	Make() Feature
}

func New

func New() MakeFeature

func NewTagged

func NewTagged(tag feature.Tag) MakeFeature

Jump to

Keyboard shortcuts

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