Module webauthn_rs::proto[][src]

JSON Protocol Structs and representations for communication with authenticators and clients.

Structs

AllowCredentials

A descriptor of a credential that can be used.

AttestationObject

Attestation Object

AuthenticatorAssertionResponseRaw

https://w3c.github.io/webauthn/#authenticatorassertionresponse

AuthenticatorAttestationResponseRaw

https://w3c.github.io/webauthn/#authenticatorattestationresponse

AuthenticatorData

https://w3c.github.io/webauthn/#sctn-attestation

AuthenticatorSelectionCriteria

https://www.w3.org/TR/webauthn/#dictdef-authenticatorselectioncriteria

COSEEC2Key

A COSE Eliptic Curve Public Key. This is generally the provided credential that an authenticator registers, and is used to authenticate the user. You will likely never need to interact with this value, as it is part of the Credential API.

COSEKey

A COSE Key as provided by the Authenticator. You should never need to alter or change these values.

COSERSAKey

A COSE RSA PublicKey. This is a provided credential from a registered authenticator. You will likely never need to interact with this value, as it is part of the Credential API.

Challenge

A challenge issued by the server. This contains a set of random bytes

CollectedClientData

The data collected and hashed in the operation.

CreationChallengeResponse

A JSON serialisable challenge which is issued to the user’s webbrowser for handling. This is meant to be opaque, that is, you should not need to inspect or alter the content of the struct - you should serialise it and transmit it to the client only.

Credential

A user’s authenticator credential. It contains an id, the public key and a counter of how many times the authenticator has been used.

PubKeyCredParams

Public key cryptographic parameters

PublicKeyCredential

A client response to an authentication challenge. This contains all required information to asses and assert trust in a credentials legitimacy, followed by authentication to a user.

PublicKeyCredentialCreationOptions

https://w3c.github.io/webauthn/#dictionary-makecredentialoptions

PublicKeyCredentialDescriptor

https://www.w3.org/TR/webauthn/#dictdef-publickeycredentialdescriptor

PublicKeyCredentialRequestOptions

The requested options for the authentication

RegisterPublicKeyCredential

A client response to a registration challenge. This contains all required information to asses and assert trust in a credentials legitimacy, followed by registration to a user.

RelyingParty

Relying Party Entity

RequestChallengeResponse

A JSON serialisable challenge which is issued to the user’s webbrowser for handling. This is meant to be opaque, that is, you should not need to inspect or alter the content of the struct - you should serialise it and transmit it to the client only.

TokenBinding

Token binding

TpmsAttest

Tpm attestation structure.

TpmsClockInfo

Information about the TPM’s clock. May be obsfucated.

TpmsRsaParms

Rsa Parameters.

TpmtPublic

Tpm Public Key Structure

TpmtRsaScheme

The Rsa Scheme. Unused in webauthn.

TpmtSymDefObject

Symmetric crypto definition. Unused in webauthn

User

User Entity

Enums

AttestationConveyancePreference

https://www.w3.org/TR/webauthn/#enumdef-attestationconveyancepreference

AuthenticatorAttachment

The authenticator attachment hint. This is NOT enforced, and is only used to help a user select a relevant authenticator type.

AuthenticatorTransport

https://www.w3.org/TR/webauthn/#enumdef-authenticatortransport

COSEContentType

A COSE Key Content type, indicating the type of key and hash type that should be used with this key. You shouldn’t need to alter or use this value.

COSEKeyType

The type of Key contained within a COSE value. You should never need to alter or change this type.

ECDSACurve

An ECDSACurve identifier. You probabably will never need to alter or use this value, as it is set inside the Credential for you.

Tpm2bName

Tpm name enumeration.

TpmAlgId

The tpm cryptographic algorithm that may be in use.

TpmSt

Tpm statement types.

TpmtSignature

A TPM Signature.

TpmuAttest

Tpm attestation union, switched by TpmSt.

TpmuPublicId

Asymetric Public Key

TpmuPublicParms

Asymetric Public Parameters

UserVerificationPolicy

Defines the User Authenticator Verification policy. This is documented https://w3c.github.io/webauthn/#enumdef-userverificationrequirement, and each variant lists it’s effects.

Constants

TPM_GENERATED_VALUE

A magic constant that defines that a Tpm attestation comes from a TPM

Type Definitions

Aaguid

Representation of an AAGUID https://www.w3.org/TR/webauthn/#aaguid

Counter

Representation of a device counter

CredentialID

A credential ID type. At the moment this is a vector of bytes, but it could also be a future change for this to be base64 string instead.

UserId

Representation of a UserId