Fix bug where ciphertexts could end up negative
This commit is contained in:
@ -76,12 +76,12 @@ class Strength {
|
||||
const data = ev.detail;
|
||||
|
||||
if (data.region === region && data.stage === "PROOF") {
|
||||
if (proofSessionVerifier.verify(BigInt(data.z))) {
|
||||
console.log("verified");
|
||||
let result = proofSessionVerifier.verify(BigInt(data.z));
|
||||
if (result > 0) {
|
||||
this.assumedStrength = plainText;
|
||||
controller.abort();
|
||||
} else {
|
||||
console.warn("Failed to verify ciphertext!");
|
||||
console.warn(`Failed to verify ciphertext! ${result}`);
|
||||
}
|
||||
}
|
||||
},
|
||||
|
Reference in New Issue
Block a user