From 155a0e11d48eeb4df6e89430aa4085573df9b807 Mon Sep 17 00:00:00 2001 From: engrach Date: Mon, 27 Jul 2026 11:26:18 +0200 Subject: [PATCH] Correct PGPSign.mjs to use the clearsign function The PGPSign function should use the kbpgp.clearsign function instead of the kbpgp.box. The clearsign function returns a plaintext message instead of an armorded signature that is used for encryption. --- src/core/operations/PGPSign.mjs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/core/operations/PGPSign.mjs b/src/core/operations/PGPSign.mjs index e3063d891b..f56052d0f2 100644 --- a/src/core/operations/PGPSign.mjs +++ b/src/core/operations/PGPSign.mjs @@ -66,10 +66,9 @@ class PGPSign extends Operation { const privKey = await importPrivateKey(privateKey, passphrase); try { - signedMessage = await promisify(kbpgp.box)({ + signedMessage = await promisify(kbpgp.clearsign)({ "msg": message, - "sign_with": privKey, - "asp": ASP + "signing_key": privKey, }); } catch (err) { throw new OperationError(`Couldn't sign message: ${err}`);