From ecf3e8d45c618765f46ab7dab8dea6cb293fa510 Mon Sep 17 00:00:00 2001 From: Akamig Date: Mon, 30 Oct 2023 15:23:12 +0900 Subject: [PATCH] Add isDigest --- @planetarium/account-aws-kms/src/AwsKmsAccount.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/@planetarium/account-aws-kms/src/AwsKmsAccount.ts b/@planetarium/account-aws-kms/src/AwsKmsAccount.ts index 1e54663fff9..5b775cc5044 100644 --- a/@planetarium/account-aws-kms/src/AwsKmsAccount.ts +++ b/@planetarium/account-aws-kms/src/AwsKmsAccount.ts @@ -35,10 +35,11 @@ export class AwsKmsAccount implements Account { return Promise.resolve(this.publicKey); } - async sign(message: Message): Promise { + async sign(message: Message, isDigest: boolean = false): Promise { const cmd = new SignCommand({ KeyId: this.keyId, Message: message, + MessageType: isDigest ? "DIGEST" : "RAW", SigningAlgorithm: "ECDSA_SHA_256", }); const response = await this.#client.send(cmd);