summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--packages/server/src/attestation/verifyAttestationResponse.ts20
1 files changed, 19 insertions, 1 deletions
diff --git a/packages/server/src/attestation/verifyAttestationResponse.ts b/packages/server/src/attestation/verifyAttestationResponse.ts
index c447379..d24b0f4 100644
--- a/packages/server/src/attestation/verifyAttestationResponse.ts
+++ b/packages/server/src/attestation/verifyAttestationResponse.ts
@@ -4,7 +4,10 @@ import {
COSEAlgorithmIdentifier,
} from '@simplewebauthn/typescript-types';
-import decodeAttestationObject, { AttestationFormat } from '../helpers/decodeAttestationObject';
+import decodeAttestationObject, {
+ AttestationFormat,
+ AttestationStatement,
+} from '../helpers/decodeAttestationObject';
import decodeClientDataJSON from '../helpers/decodeClientDataJSON';
import parseAuthenticatorData from '../helpers/parseAuthenticatorData';
import toHash from '../helpers/toHash';
@@ -289,3 +292,18 @@ export type VerifiedAttestation = {
attestationObject: Buffer;
};
};
+
+/**
+ * Values passed to all attestation format verifiers, from which they are free to use as they please
+ */
+export type AttestationFormatVerifierOpts = {
+ aaguid: Buffer;
+ attStmt: AttestationStatement;
+ authData: Buffer;
+ clientDataHash: Buffer;
+ credentialID: Buffer;
+ credentialPublicKey: Buffer;
+ rootCertificates: string[];
+ rpIdHash: Buffer;
+ verifyTimestampMS?: boolean;
+};