Skip to content

Commit

Permalink
fix: add convert utfBytes for iterations more than 1
Browse files Browse the repository at this point in the history
  • Loading branch information
damartripamungkas committed Dec 4, 2023
1 parent abc8933 commit 407b849
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ <h1 class="mt-0">Custom Key Wallet Crypto</h1>
let pk = ethers.keccak256(utfBytes);

for (let index = 1; index < iterations; index++) {
pk = ethers.keccak256(pk);
pk = ethers.keccak256(ethers.toUtf8Bytes(pk));
}

const { address } = new ethers.Wallet(pk);
Expand Down

0 comments on commit 407b849

Please sign in to comment.