credential

package
v0.11.1 Latest Latest
Warning

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

Go to latest
Published: May 14, 2026 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AuthenticatorTransport

type AuthenticatorTransport string

AuthenticatorTransport defines hints as to how clients might communicate with a particular authenticator in order to obtain an assertion for a specific credential. https://www.w3.org/TR/webauthn-3/#enumdef-authenticatortransport

const (
	AuthenticatorTransportUSB       AuthenticatorTransport = "usb"
	AuthenticatorTransportNFC       AuthenticatorTransport = "nfc"
	AuthenticatorTransportBLE       AuthenticatorTransport = "ble"
	AuthenticatorTransportSmartCard AuthenticatorTransport = "smart-card"
	AuthenticatorTransportHybrid    AuthenticatorTransport = "hybrid"
	AuthenticatorTransportInternal  AuthenticatorTransport = "internal"
)

type PublicKeyCredentialDescriptor

type PublicKeyCredentialDescriptor struct {
	Type       PublicKeyCredentialType  `cbor:"type" json:"type"`
	ID         []byte                   `cbor:"id" json:"id"`
	Transports []AuthenticatorTransport `cbor:"transports,omitempty" json:"transports,omitempty"`
}

PublicKeyCredentialDescriptor identifies a specific public key credential. https://www.w3.org/TR/webauthn-3/#dictdef-publickeycredentialdescriptor

type PublicKeyCredentialHint

type PublicKeyCredentialHint string

PublicKeyCredentialHint is used by WebAuthn Relying Parties to communicate hints to the user-agent about how a request may be best completed. https://www.w3.org/TR/webauthn-3/#enum-hints

const (
	PublicKeyCredentialHintSecurityKey  PublicKeyCredentialHint = "security-key"
	PublicKeyCredentialHintClientDevice PublicKeyCredentialHint = "client-device"
	PublicKeyCredentialHintHybrid       PublicKeyCredentialHint = "hybrid"
)

type PublicKeyCredentialParameters

type PublicKeyCredentialParameters struct {
	Type      PublicKeyCredentialType `cbor:"type" json:"type"`
	Algorithm key.Alg                 `cbor:"alg" json:"alg"`
}

PublicKeyCredentialParameters is used to supply additional parameters when creating a new credential. https://www.w3.org/TR/webauthn-3/#dictdef-publickeycredentialparameters

type PublicKeyCredentialRpEntity

type PublicKeyCredentialRpEntity struct {
	ID   string `cbor:"id" json:"id"`
	Name string `cbor:"name,omitempty" json:"name"`
}

PublicKeyCredentialRpEntity is used to supply additional Relying Party attributes when creating a new credential. https://www.w3.org/TR/webauthn-3/#dictdef-publickeycredentialrpentity

type PublicKeyCredentialType

type PublicKeyCredentialType string

PublicKeyCredentialType defines the valid credential types. https://www.w3.org/TR/webauthn-3/#enumdef-publickeycredentialtype

const (
	PublicKeyCredentialTypePublicKey PublicKeyCredentialType = "public-key"
)

type PublicKeyCredentialUserEntity

type PublicKeyCredentialUserEntity struct {
	ID          []byte `cbor:"id" json:"id"`
	DisplayName string `cbor:"displayName" json:"displayName"`
	Name        string `cbor:"name" json:"name"`
	Icon        string `cbor:"icon,omitempty" json:"icon,omitempty"` // deprecated
}

PublicKeyCredentialUserEntity is used to supply additional user account attributes when creating a new credential. https://www.w3.org/TR/webauthn-3/#dictdef-publickeycredentialuserentity

Jump to

Keyboard shortcuts

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