1
0
mirror of https://github.com/misskey-dev/misskey.git synced 2026-05-24 13:54:12 +02:00

perf: rsa sign on slacc (#17322)

* perf: rsa sign on slacc

* fix: missing async/await

* fix: threadPoolSize is always number

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

* test(backend): init slacc in unit setup and await ap-request signing

* test(backend): move slacc init to unit testEnvironment

* test(backend): delete unused file

* docs: update CHANGELOG

* docs: fix indent

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

* chore: migrate to vitest

* fix

* fix: fix changelog

* chore: regenerate lockfile

* docs: changelog

---------

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: kakkokari-gtyih <67428053+kakkokari-gtyih@users.noreply.github.com>
This commit is contained in:
Acid Chicken
2026-05-12 17:36:49 +09:00
committed by GitHub
parent a19da1258d
commit b950f905e5
18 changed files with 201 additions and 130 deletions

View File

@@ -0,0 +1,10 @@
/*
* SPDX-FileCopyrightText: syuilo and misskey-project
* SPDX-License-Identifier: AGPL-3.0-only
*/
import { init } from 'slacc';
import { builtinEnvironments } from 'vitest/runtime';
init(1);
export default builtinEnvironments.node;

View File

@@ -42,7 +42,7 @@ describe('ap-request', () => {
'User-Agent': 'UA',
};
const req = ApRequestCreator.createSignedPost({ key, url, body, additionalHeaders: headers });
const req = await ApRequestCreator.createSignedPost({ key, url, body, additionalHeaders: headers });
const parsed = buildParsedSignature(req.signingString, req.signature, 'rsa-sha256');
@@ -58,7 +58,7 @@ describe('ap-request', () => {
'User-Agent': 'UA',
};
const req = ApRequestCreator.createSignedGet({ key, url, additionalHeaders: headers });
const req = await ApRequestCreator.createSignedGet({ key, url, additionalHeaders: headers });
const parsed = buildParsedSignature(req.signingString, req.signature, 'rsa-sha256');