zitadel/internal/user/model/otp.go
Livio Amstutz 38478efefb
fix: handle multiple webauthn origins (#1078)
* fix(grpc): return CredentialCreationData in webauthn public key

* return id of u2f tokens

* handle separate origins in webauthn

* param
2020-12-08 15:39:58 +01:00

39 lines
572 B
Go

package model
import (
"github.com/caos/zitadel/internal/crypto"
es_models "github.com/caos/zitadel/internal/eventstore/models"
)
type OTP struct {
es_models.ObjectRoot
Secret *crypto.CryptoValue
SecretString string
Url string
State MFAState
}
type MFAState int32
const (
MFAStateUnspecified MFAState = iota
MFAStateNotReady
MFAStateReady
)
type MultiFactor struct {
Type MFAType
State MFAState
Attribute string
ID string
}
type MFAType int32
const (
MFATypeUnspecified MFAType = iota
MFATypeOTP
MFATypeU2F
)