Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateToken ¶
GenerateToken returns a cryptographically random hex string of the given byte length. Used by OAuth state and session token generation.
Types ¶
type Identity ¶
type Identity struct {
UserID int64
Email string
Method MethodType
}
Identity represents a verified user from any auth method.
type MethodType ¶
type MethodType string
MethodType identifies how a user proved their identity.
const ( MethodOTP MethodType = "otp" MethodOAuth MethodType = "oauth" )
Click to show internal directories.
Click to hide internal directories.