Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Authenticator ¶
type Authenticator interface { GetSetupInfo(ctx context.Context, bizID string) (secretKey, qrCode string, status bizuserinters.Status) DoSetup(ctx context.Context, bizID, code string) (status bizuserinters.Status) Verify(ctx context.Context, bizID, code string) (status bizuserinters.Status) }
func NewAuthenticator ¶
func NewAuthenticator(model Model, issuer string) Authenticator
func NewAuthenticatorEx ¶
func NewAuthenticatorEx(model Model, issuer string, dc *DebugConfig) Authenticator
type DebugConfig ¶
type Model ¶
type Model interface { authenticator.Model GetGoogle2FASecretKey(ctx context.Context, bizID string) (secretKey string, status bizuserinters.Status) GetGoogle2FASetupUserInfo(ctx context.Context, bizID string) (name string, status bizuserinters.Status) CacheGoogle2FASecretKey(ctx context.Context, bizID, secretKey string) (status bizuserinters.Status) GetCachedGoogle2FASecretKey(ctx context.Context, bizID string) (secretKey string, status bizuserinters.Status) SetSetupGoogle2FACompleted(ctx context.Context, bizID string, secretKey string) (status bizuserinters.Status) SetVerifyGoogle2FACompleted(ctx context.Context, bizID string) (status bizuserinters.Status) }
Click to show internal directories.
Click to hide internal directories.