Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AllowCredential ¶
type AllowCredential struct { Type string `json:"type"` ID string `json:"id"` Transports []CredentialTransport `json:"transports"` }
type AllowCredentials ¶
type AllowCredentials struct { Key []AllowCredential `json:"key"` Webauthn []AllowCredential `json:"webauthn"` }
type CredentialAssertion ¶
type CredentialTransport ¶
type CredentialTransport string
const ( USB CredentialTransport = "usb" NFC CredentialTransport = "nfc" BLE CredentialTransport = "ble" Internal CredentialTransport = "internal" )
type ICredentialSigner ¶
type ICredentialSigner interface {
Sign(ctx context.Context, userActionChallenge *UserActionChallenge) (*KeyAssertion, error)
}
For not it returns a KeyAssertion. But we can make it more generic afterward
type KeyAssertion ¶
type KeyAssertion struct { Kind CredentialKind `json:"kind"` CredentialAssertion CredentialAssertion `json:"credentialAssertion"` }
type NotAllowedCredentialsError ¶
type NotAllowedCredentialsError struct { CredID string AllowedCreds []AllowCredential }
NotAllowedCredentialsError indicates that the provided credential ID is not among the allowed credentials.
func (*NotAllowedCredentialsError) Error ¶
func (e *NotAllowedCredentialsError) Error() string
Error returns the error message.
type UserActionChallenge ¶
type UserActionChallenge struct { Challenge string AllowCredentials *AllowCredentials }
UserActionChallenge contains the challenge to sign
Click to show internal directories.
Click to hide internal directories.