spec(deps): update @simplewebauthn/server to 8.3.5 (MisskeyIO#198)

This commit is contained in:
まっちゃとーにゅ 2023-10-30 00:41:31 +09:00 committed by GitHub
parent 16f213ef0c
commit 462b5470b7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 1219 additions and 201 deletions

View File

@ -74,7 +74,7 @@
"@nestjs/core": "10.1.0", "@nestjs/core": "10.1.0",
"@nestjs/testing": "10.1.0", "@nestjs/testing": "10.1.0",
"@peertube/http-signature": "1.7.0", "@peertube/http-signature": "1.7.0",
"@simplewebauthn/server": "^7.4.0", "@simplewebauthn/server": "^8.3.5",
"@sinonjs/fake-timers": "10.3.0", "@sinonjs/fake-timers": "10.3.0",
"@swc/cli": "0.1.62", "@swc/cli": "0.1.62",
"@swc/core": "1.3.70", "@swc/core": "1.3.70",
@ -164,7 +164,7 @@
}, },
"devDependencies": { "devDependencies": {
"@jest/globals": "29.6.1", "@jest/globals": "29.6.1",
"@simplewebauthn/typescript-types": "^7.4.0", "@simplewebauthn/typescript-types": "^8.3.4",
"@swc/jest": "0.2.26", "@swc/jest": "0.2.26",
"@types/accepts": "1.3.5", "@types/accepts": "1.3.5",
"@types/archiver": "5.3.2", "@types/archiver": "5.3.2",

View File

@ -7,7 +7,8 @@ import { Inject, Injectable } from '@nestjs/common';
import * as Redis from 'ioredis'; import * as Redis from 'ioredis';
import { import {
generateAuthenticationOptions, generateAuthenticationOptions,
generateRegistrationOptions, verifyAuthenticationResponse, generateRegistrationOptions,
verifyAuthenticationResponse,
verifyRegistrationResponse, verifyRegistrationResponse,
} from '@simplewebauthn/server'; } from '@simplewebauthn/server';
import { AttestationFormat, isoCBOR } from '@simplewebauthn/server/helpers'; import { AttestationFormat, isoCBOR } from '@simplewebauthn/server/helpers';
@ -60,7 +61,7 @@ export class WebAuthnService {
userId: userId, userId: userId,
}); });
const registrationOptions = generateRegistrationOptions({ const registrationOptions = await generateRegistrationOptions({
rpName: relyingParty.rpName, rpName: relyingParty.rpName,
rpID: relyingParty.rpId, rpID: relyingParty.rpId,
userID: userId, userID: userId,
@ -150,7 +151,7 @@ export class WebAuthnService {
throw new IdentifiableError('f27fd449-9af4-4841-9249-1f989b9fa4a4', 'no keys found'); throw new IdentifiableError('f27fd449-9af4-4841-9249-1f989b9fa4a4', 'no keys found');
} }
const authenticationOptions = generateAuthenticationOptions({ const authenticationOptions = await generateAuthenticationOptions({
allowCredentials: keys.map(key => (<PublicKeyCredentialDescriptorFuture>{ allowCredentials: keys.map(key => (<PublicKeyCredentialDescriptorFuture>{
id: Buffer.from(key.id, 'base64url'), id: Buffer.from(key.id, 'base64url'),
type: 'public-key', type: 'public-key',

File diff suppressed because it is too large Load Diff