mirror of
https://github.com/status-im/dagger-contracts.git
synced 2025-02-26 13:25:22 +00:00
Rename: vkX -> combination
This commit is contained in:
parent
a4ce10f4de
commit
f9637f192b
@ -138,15 +138,15 @@ contract Groth16Verifier {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Compute the linear combination vkX
|
// Compute the linear combination
|
||||||
G1Point memory vkX = _verifyingKey.ic[0];
|
G1Point memory combination = _verifyingKey.ic[0];
|
||||||
for (uint i = 0; i < input.length; i++) {
|
for (uint i = 0; i < input.length; i++) {
|
||||||
G1Point memory product;
|
G1Point memory product;
|
||||||
(success, product) = _multiply(_verifyingKey.ic[i + 1], input[i]);
|
(success, product) = _multiply(_verifyingKey.ic[i + 1], input[i]);
|
||||||
if (!success) {
|
if (!success) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
(success, vkX) = _add(vkX, product);
|
(success, combination) = _add(combination, product);
|
||||||
if (!success) {
|
if (!success) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -157,7 +157,7 @@ contract Groth16Verifier {
|
|||||||
proof.b,
|
proof.b,
|
||||||
_verifyingKey.alpha1,
|
_verifyingKey.alpha1,
|
||||||
_verifyingKey.beta2,
|
_verifyingKey.beta2,
|
||||||
vkX,
|
combination,
|
||||||
_verifyingKey.gamma2,
|
_verifyingKey.gamma2,
|
||||||
proof.c,
|
proof.c,
|
||||||
_verifyingKey.delta2
|
_verifyingKey.delta2
|
||||||
|
Loading…
x
Reference in New Issue
Block a user