From 1df6c53ca08b9b9f2aeae6c5be50f6fcbcede0e7 Mon Sep 17 00:00:00 2001 From: G <28568419+s1fr0@users.noreply.github.com> Date: Mon, 3 Oct 2022 14:58:49 +0200 Subject: [PATCH] fix(rln): fix order of inputs in comments (#59) --- rln/src/public.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/rln/src/public.rs b/rln/src/public.rs index 6f684c5..933e313 100644 --- a/rln/src/public.rs +++ b/rln/src/public.rs @@ -248,7 +248,7 @@ impl RLN<'_> { // This API keeps partial compatibility with kilic's rln public API https://github.com/kilic/rln/blob/7ac74183f8b69b399e3bc96c1ae8ab61c026dc43/src/public.rs#L148 // input_data is [ id_key<32> | id_index<8> | epoch<32> | signal_len<8> | signal ] - // output_data is [ proof<128> | share_y<32> | nullifier<32> | root<32> | epoch<32> | share_x<32> | rln_identifier<32> ] + // output_data is [ proof<128> | root<32> | epoch<32> | share_x<32> | share_y<32> | nullifier<32> | rln_identifier<32> ] #[cfg(not(target_arch = "wasm32"))] pub fn generate_rln_proof( &mut self, @@ -278,7 +278,7 @@ impl RLN<'_> { /// Generate RLN Proof using a witness calculated from outside zerokit /// - /// output_data is [ proof<128> | share_y<32> | nullifier<32> | root<32> | epoch<32> | share_x<32> | rln_identifier<32> ] + /// output_data is [ proof<128> | root<32> | epoch<32> | share_x<32> | share_y<32> | nullifier<32> | rln_identifier<32> ] pub fn generate_rln_proof_with_witness( &mut self, calculated_witness: Vec, @@ -300,7 +300,7 @@ impl RLN<'_> { } // Input data is serialized for Curve as: - // [ proof<128> | share_y<32> | nullifier<32> | root<32> | epoch<32> | share_x<32> | rln_identifier<32> | signal_len<8> | signal ] + // [ proof<128> | root<32> | epoch<32> | share_x<32> | share_y<32> | nullifier<32> | rln_identifier<32> | signal_len<8> | signal ] pub fn verify_rln_proof(&self, mut input_data: R) -> io::Result { let mut serialized: Vec = Vec::new(); input_data.read_to_end(&mut serialized)?;