diff --git a/src/file/file.route.ts b/src/file/file.route.ts index 415a14f..b7dcd90 100644 --- a/src/file/file.route.ts +++ b/src/file/file.route.ts @@ -29,6 +29,10 @@ export async function fileRoutes(fastify: FastifyInstance) { { schema: { params: { type: "object", properties: { fileId: { type: "string" } } }, + querystring: { + type: "object", + properties: { direct: { type: "boolean" } }, + }, response: { 200: $file("downloadFileResponse"), }, diff --git a/src/webauthn/webauthn.route.ts b/src/webauthn/webauthn.route.ts index e73e01c..cb92435 100644 --- a/src/webauthn/webauthn.route.ts +++ b/src/webauthn/webauthn.route.ts @@ -235,8 +235,16 @@ export async function webAuthnRoutes(fastify: FastifyInstance) { expectedChallenge: userInDB.challenge.value as string, expectedRPID: rpID, expectedOrigin: origin, - // @ts-ignore - credential: credential, + credential: { + // @ts-ignore + id: credential.credentialID, + // @ts-ignore + publicKey: credential.credentialPublicKey.buffer, + // @ts-ignore + counter: credential.counter, + // @ts-ignore + transports: credential.transports, + }, }); if (!verification.verified)