From d66925d6f6b706d4c8f024481953f5e09f8e2b0f Mon Sep 17 00:00:00 2001 From: Matthew Miller Date: Wed, 27 Apr 2022 09:24:20 -0700 Subject: Add "cable" support --- packages/typescript-types/src/index.ts | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'packages/typescript-types/src') diff --git a/packages/typescript-types/src/index.ts b/packages/typescript-types/src/index.ts index a930861..751474a 100644 --- a/packages/typescript-types/src/index.ts +++ b/packages/typescript-types/src/index.ts @@ -6,7 +6,6 @@ import type { AuthenticatorAssertionResponse, AuthenticatorAttestationResponse, - AuthenticatorTransport, COSEAlgorithmIdentifier, PublicKeyCredential, PublicKeyCredentialCreationOptions, @@ -43,8 +42,9 @@ export interface PublicKeyCredentialRequestOptionsJSON } export interface PublicKeyCredentialDescriptorJSON - extends Omit { + extends Omit { id: Base64URLString; + transports?: AuthenticatorTransport[]; } export interface PublicKeyCredentialUserEntityJSON @@ -146,3 +146,9 @@ export interface AuthenticatorAttestationResponseFuture extends AuthenticatorAtt getPublicKey?: () => ArrayBuffer; getPublicKeyAlgorithm?: () => COSEAlgorithmIdentifier[]; } + +/** + * Communication methods by which an authenticator can talk with the browser to perform WebAuthn + * registration and authentication. + */ +export type AuthenticatorTransport = "ble" | "internal" | "nfc" | "usb" | "cable"; -- cgit v1.2.3