From 4828b176858e74732118bab25f19fdab8fd3fa88 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B8r=E2=88=82=C2=A1?= Date: Thu, 4 Feb 2021 20:38:09 +0100 Subject: [PATCH] Minor cleanup on the comments --- src/index.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/index.ts b/src/index.ts index 7439abc..1385691 100644 --- a/src/index.ts +++ b/src/index.ts @@ -57,9 +57,9 @@ export function newRequestParameters() { /** * Blinds the message for the signer R. - * @param {BigNumber} m - * @param {Point} signerR - * @returns {struct} {mBlinded: BigNumber, userSecretData: {a: BigNumber, b: BigNumber, f: Point}} + * @param m The message to blind + * @param signerR + * @returns The blinded signature and the user secret data */ export function blind(m: BigNumber, signerR: Point): { mBlinded: BigNumber, userSecretData: UserSecretData } { const u: UserSecretData = { a: new BigNumber(0), b: new BigNumber(0), f: G } @@ -84,6 +84,7 @@ export function blind(m: BigNumber, signerR: Point): { mBlinded: BigNumber, user return { mBlinded: mBlinded.mod(n), userSecretData: u } } +/** Performs a signature on a blinded message */ export function blindSign(sk: BigNumber, mBlinded: BigNumber, k: BigNumber): BigNumber { let sBlind = sk.mul(mBlinded) sBlind = sBlind.add(k)