We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fee1f70 commit deb6b71Copy full SHA for deb6b71
src/clsag/sign.rs
@@ -29,7 +29,7 @@ pub fn sign(
29
L: EdwardsPoint,
30
R: EdwardsPoint,
31
I: EdwardsPoint,
32
-) -> Clsag {
+) -> (Clsag, Scalar) {
33
let D = z * H_p_pk;
34
let D_inv_8 = D * INV_EIGHT;
35
let adjusted_commitment_ring =
@@ -97,11 +97,16 @@ pub fn sign(
97
h_prev = h
98
}
99
100
- responses[signing_key_index] = alpha - h_prev * ((mu_P * signing_key) + (mu_C * z));
+ let stupid_constant = h_prev * mu_C * z;
101
102
- Clsag {
103
- s: responses.to_vec(),
104
- c1: h_0,
105
- D: D_inv_8,
106
- }
+ responses[signing_key_index] = alpha - h_prev * mu_P * signing_key - stupid_constant;
+
+ (
+ Clsag {
+ s: responses.to_vec(),
107
+ c1: h_0,
108
+ D: D_inv_8,
109
+ },
110
+ stupid_constant,
111
+ )
112
0 commit comments