From 7b085bcd31b8979bd798cf4f4fe572f9d6d68f0d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20=27birdy=27=20Danjou?= Date: Thu, 5 Dec 2024 18:31:55 +0100 Subject: [PATCH 1/2] fix: fix checksum for encryption --- src/sdk/encrypt.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/sdk/encrypt.ts b/src/sdk/encrypt.ts index 7f4647c..b5ef264 100644 --- a/src/sdk/encrypt.ts +++ b/src/sdk/encrypt.ts @@ -1,4 +1,4 @@ -import { isAddress } from 'ethers'; +import { getAddress, isAddress } from 'ethers'; import createKeccakHash from 'keccak'; import { TfheCompactPublicKey, @@ -272,8 +272,8 @@ export const createEncryptedInput = const closestPP = this._getClosestPP(); const ppId = publicParams[closestPP]!.publicParamsId; const payload = { - contract_address: contractAddress, - caller_address: callerAddress, + contract_address: getAddress(contractAddress), + caller_address: getAddress(callerAddress), ct_proof: ciphertext.toString('hex'), key_id: publicKeyId, crs_id: ppId, From e64e0adfc68639e86170a3f8ab597ddfab4f5153 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20=27birdy=27=20Danjou?= Date: Thu, 5 Dec 2024 21:03:07 +0100 Subject: [PATCH 2/2] 0.6.0 --- package-lock.json | 4 ++-- package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package-lock.json b/package-lock.json index 9e8a771..357c444 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "fhevmjs", - "version": "0.6.0-19", + "version": "0.6.0", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "fhevmjs", - "version": "0.6.0-19", + "version": "0.6.0", "license": "BSD-3-Clause-Clear", "dependencies": { "bigint-buffer": "^1.1.5", diff --git a/package.json b/package.json index 4e005f4..dc60234 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "fhevmjs", - "version": "0.6.0-19", + "version": "0.6.0", "description": "fhEVM SDK for blockchain using TFHE", "main": "lib/node.js", "types": "lib/node/node.d.ts",