From 14c0580335867370103c66f235c7adccd9e91c11 Mon Sep 17 00:00:00 2001 From: thomaslavaur Date: Fri, 26 Jul 2024 08:02:54 +0200 Subject: [PATCH] moved hash circuit and circomlib properly. Changed the leadership circuit dependencies to reflect the different paths --- circom_circuits/circomlib | 1 + .../hash}/anemoi/anemoi_16_to_1_Jubjub.circom | 0 .../hash}/anemoi/anemoi_2_to_1_Jubjub.circom | 0 .../hash}/anemoi/anemoi_4_to_1_Jubjub.circom | 0 .../anemoi/anemoi_Jubjub_16_to_1_constants.circom | 0 .../hash}/anemoi/anemoi_Jubjub_2_to_1_constants.circom | 0 .../hash}/anemoi/anemoi_Jubjub_4_to_1_constants.circom | 0 .../hash}/anemoi/script_setup_prover.sh | 0 .../hash}/poseidon/poseidon_16_to_1_Jubjub.circom | 0 .../hash}/poseidon/poseidon_2_to_1_Jubjub.circom | 0 .../hash}/poseidon/poseidon_4_to_1_Jubjub.circom | 0 .../poseidon/poseidon_Jubjub_16_to_1_constants.circom | 0 .../poseidon/poseidon_Jubjub_2_to_1_constants.circom | 0 .../poseidon/poseidon_Jubjub_4_to_1_constants.circom | 0 proof_of_leadership/circom/leadership_anemoi.circom | 8 ++++---- .../circom/leadership_anemoi_sha.circom | 10 +++++----- proof_of_leadership/circom/leadership_poseidon.circom | 8 ++++---- .../circom/leadership_poseidon_sha.circom | 10 +++++----- proof_of_leadership/circom/leadership_sha256.circom | 4 ++-- 19 files changed, 21 insertions(+), 20 deletions(-) create mode 160000 circom_circuits/circomlib rename {proof_of_leadership/circom => circom_circuits/hash}/anemoi/anemoi_16_to_1_Jubjub.circom (100%) rename {proof_of_leadership/circom => circom_circuits/hash}/anemoi/anemoi_2_to_1_Jubjub.circom (100%) rename {proof_of_leadership/circom => circom_circuits/hash}/anemoi/anemoi_4_to_1_Jubjub.circom (100%) rename {proof_of_leadership/circom => circom_circuits/hash}/anemoi/anemoi_Jubjub_16_to_1_constants.circom (100%) rename {proof_of_leadership/circom => circom_circuits/hash}/anemoi/anemoi_Jubjub_2_to_1_constants.circom (100%) rename {proof_of_leadership/circom => circom_circuits/hash}/anemoi/anemoi_Jubjub_4_to_1_constants.circom (100%) rename {proof_of_leadership/circom => circom_circuits/hash}/anemoi/script_setup_prover.sh (100%) rename {proof_of_leadership/circom => circom_circuits/hash}/poseidon/poseidon_16_to_1_Jubjub.circom (100%) rename {proof_of_leadership/circom => circom_circuits/hash}/poseidon/poseidon_2_to_1_Jubjub.circom (100%) rename {proof_of_leadership/circom => circom_circuits/hash}/poseidon/poseidon_4_to_1_Jubjub.circom (100%) rename {proof_of_leadership/circom => circom_circuits/hash}/poseidon/poseidon_Jubjub_16_to_1_constants.circom (100%) rename {proof_of_leadership/circom => circom_circuits/hash}/poseidon/poseidon_Jubjub_2_to_1_constants.circom (100%) rename {proof_of_leadership/circom => circom_circuits/hash}/poseidon/poseidon_Jubjub_4_to_1_constants.circom (100%) diff --git a/circom_circuits/circomlib b/circom_circuits/circomlib new file mode 160000 index 0000000..cff5ab6 --- /dev/null +++ b/circom_circuits/circomlib @@ -0,0 +1 @@ +Subproject commit cff5ab6288b55ef23602221694a6a38a0239dcc0 diff --git a/proof_of_leadership/circom/anemoi/anemoi_16_to_1_Jubjub.circom b/circom_circuits/hash/anemoi/anemoi_16_to_1_Jubjub.circom similarity index 100% rename from proof_of_leadership/circom/anemoi/anemoi_16_to_1_Jubjub.circom rename to circom_circuits/hash/anemoi/anemoi_16_to_1_Jubjub.circom diff --git a/proof_of_leadership/circom/anemoi/anemoi_2_to_1_Jubjub.circom b/circom_circuits/hash/anemoi/anemoi_2_to_1_Jubjub.circom similarity index 100% rename from proof_of_leadership/circom/anemoi/anemoi_2_to_1_Jubjub.circom rename to circom_circuits/hash/anemoi/anemoi_2_to_1_Jubjub.circom diff --git a/proof_of_leadership/circom/anemoi/anemoi_4_to_1_Jubjub.circom b/circom_circuits/hash/anemoi/anemoi_4_to_1_Jubjub.circom similarity index 100% rename from proof_of_leadership/circom/anemoi/anemoi_4_to_1_Jubjub.circom rename to circom_circuits/hash/anemoi/anemoi_4_to_1_Jubjub.circom diff --git a/proof_of_leadership/circom/anemoi/anemoi_Jubjub_16_to_1_constants.circom b/circom_circuits/hash/anemoi/anemoi_Jubjub_16_to_1_constants.circom similarity index 100% rename from proof_of_leadership/circom/anemoi/anemoi_Jubjub_16_to_1_constants.circom rename to circom_circuits/hash/anemoi/anemoi_Jubjub_16_to_1_constants.circom diff --git a/proof_of_leadership/circom/anemoi/anemoi_Jubjub_2_to_1_constants.circom b/circom_circuits/hash/anemoi/anemoi_Jubjub_2_to_1_constants.circom similarity index 100% rename from proof_of_leadership/circom/anemoi/anemoi_Jubjub_2_to_1_constants.circom rename to circom_circuits/hash/anemoi/anemoi_Jubjub_2_to_1_constants.circom diff --git a/proof_of_leadership/circom/anemoi/anemoi_Jubjub_4_to_1_constants.circom b/circom_circuits/hash/anemoi/anemoi_Jubjub_4_to_1_constants.circom similarity index 100% rename from proof_of_leadership/circom/anemoi/anemoi_Jubjub_4_to_1_constants.circom rename to circom_circuits/hash/anemoi/anemoi_Jubjub_4_to_1_constants.circom diff --git a/proof_of_leadership/circom/anemoi/script_setup_prover.sh b/circom_circuits/hash/anemoi/script_setup_prover.sh similarity index 100% rename from proof_of_leadership/circom/anemoi/script_setup_prover.sh rename to circom_circuits/hash/anemoi/script_setup_prover.sh diff --git a/proof_of_leadership/circom/poseidon/poseidon_16_to_1_Jubjub.circom b/circom_circuits/hash/poseidon/poseidon_16_to_1_Jubjub.circom similarity index 100% rename from proof_of_leadership/circom/poseidon/poseidon_16_to_1_Jubjub.circom rename to circom_circuits/hash/poseidon/poseidon_16_to_1_Jubjub.circom diff --git a/proof_of_leadership/circom/poseidon/poseidon_2_to_1_Jubjub.circom b/circom_circuits/hash/poseidon/poseidon_2_to_1_Jubjub.circom similarity index 100% rename from proof_of_leadership/circom/poseidon/poseidon_2_to_1_Jubjub.circom rename to circom_circuits/hash/poseidon/poseidon_2_to_1_Jubjub.circom diff --git a/proof_of_leadership/circom/poseidon/poseidon_4_to_1_Jubjub.circom b/circom_circuits/hash/poseidon/poseidon_4_to_1_Jubjub.circom similarity index 100% rename from proof_of_leadership/circom/poseidon/poseidon_4_to_1_Jubjub.circom rename to circom_circuits/hash/poseidon/poseidon_4_to_1_Jubjub.circom diff --git a/proof_of_leadership/circom/poseidon/poseidon_Jubjub_16_to_1_constants.circom b/circom_circuits/hash/poseidon/poseidon_Jubjub_16_to_1_constants.circom similarity index 100% rename from proof_of_leadership/circom/poseidon/poseidon_Jubjub_16_to_1_constants.circom rename to circom_circuits/hash/poseidon/poseidon_Jubjub_16_to_1_constants.circom diff --git a/proof_of_leadership/circom/poseidon/poseidon_Jubjub_2_to_1_constants.circom b/circom_circuits/hash/poseidon/poseidon_Jubjub_2_to_1_constants.circom similarity index 100% rename from proof_of_leadership/circom/poseidon/poseidon_Jubjub_2_to_1_constants.circom rename to circom_circuits/hash/poseidon/poseidon_Jubjub_2_to_1_constants.circom diff --git a/proof_of_leadership/circom/poseidon/poseidon_Jubjub_4_to_1_constants.circom b/circom_circuits/hash/poseidon/poseidon_Jubjub_4_to_1_constants.circom similarity index 100% rename from proof_of_leadership/circom/poseidon/poseidon_Jubjub_4_to_1_constants.circom rename to circom_circuits/hash/poseidon/poseidon_Jubjub_4_to_1_constants.circom diff --git a/proof_of_leadership/circom/leadership_anemoi.circom b/proof_of_leadership/circom/leadership_anemoi.circom index e39e6e7..a0fa1c0 100644 --- a/proof_of_leadership/circom/leadership_anemoi.circom +++ b/proof_of_leadership/circom/leadership_anemoi.circom @@ -1,10 +1,10 @@ //test pragma circom 2.1.9; -include "anemoi/anemoi_2_to_1_Jubjub.circom"; -include "anemoi/anemoi_4_to_1_Jubjub.circom"; -include "anemoi/anemoi_16_to_1_Jubjub.circom"; -include "../../circomlib-master/circuits/bitify.circom"; +include "../../circom_circuits/hash/anemoi/anemoi_2_to_1_Jubjub.circom"; +include "../../circom_circuits/hash/anemoi/anemoi_4_to_1_Jubjub.circom"; +include "../../circom_circuits/hash/anemoi/anemoi_16_to_1_Jubjub.circom"; +include ".../../circom_circuits/circomlib/circuits/bitify.circom"; template BLSLessThan(n) { assert(n <= 253); diff --git a/proof_of_leadership/circom/leadership_anemoi_sha.circom b/proof_of_leadership/circom/leadership_anemoi_sha.circom index ed04d75..d848391 100644 --- a/proof_of_leadership/circom/leadership_anemoi_sha.circom +++ b/proof_of_leadership/circom/leadership_anemoi_sha.circom @@ -1,11 +1,11 @@ //test pragma circom 2.1.9; -include "anemoi/anemoi_2_to_1_Jubjub.circom"; -include "anemoi/anemoi_4_to_1_Jubjub.circom"; -include "anemoi/anemoi_16_to_1_Jubjub.circom"; -include "../../circomlib-master/circuits/bitify.circom"; -include "../../circomlib-master/circuits/sha256/sha256.circom"; +include "../../circom_circuits/hash/anemoi/anemoi_2_to_1_Jubjub.circom"; +include "../../circom_circuits/hash/anemoi/anemoi_4_to_1_Jubjub.circom"; +include "../../circom_circuits/hash/anemoi/anemoi_16_to_1_Jubjub.circom"; +include "../../circom_circuits/circomlib/circuits/bitify.circom"; +include "../../circom_circuits/circomlib/circuits/sha256/sha256.circom"; template BLSLessThan(n) { assert(n <= 253); diff --git a/proof_of_leadership/circom/leadership_poseidon.circom b/proof_of_leadership/circom/leadership_poseidon.circom index 411c015..a131db3 100644 --- a/proof_of_leadership/circom/leadership_poseidon.circom +++ b/proof_of_leadership/circom/leadership_poseidon.circom @@ -1,10 +1,10 @@ //test pragma circom 2.1.9; -include "poseidon/poseidon_2_to_1_Jubjub.circom"; -include "poseidon/poseidon_4_to_1_Jubjub.circom"; -include "poseidon/poseidon_16_to_1_Jubjub.circom"; -include "../../circomlib-master/circuits/bitify.circom"; +include "../../circom_circuits/hash/poseidon/poseidon_2_to_1_Jubjub.circom"; +include "../../circom_circuits/hash/poseidon/poseidon_4_to_1_Jubjub.circom"; +include "../../circom_circuits/hash/poseidon/poseidon_16_to_1_Jubjub.circom"; +include "../../circom_circuits/circomlib/circuits/bitify.circom"; template BLSLessThan(n) { assert(n <= 253); diff --git a/proof_of_leadership/circom/leadership_poseidon_sha.circom b/proof_of_leadership/circom/leadership_poseidon_sha.circom index b6ea34b..16684e9 100644 --- a/proof_of_leadership/circom/leadership_poseidon_sha.circom +++ b/proof_of_leadership/circom/leadership_poseidon_sha.circom @@ -1,11 +1,11 @@ //test pragma circom 2.1.9; -include "poseidon/poseidon_2_to_1_Jubjub.circom"; -include "poseidon/poseidon_4_to_1_Jubjub.circom"; -include "poseidon/poseidon_16_to_1_Jubjub.circom"; -include "../../circomlib-master/circuits/bitify.circom"; -include "../../circomlib-master/circuits/sha256/sha256.circom"; +include "../../circom_circuits/hash/poseidon/poseidon_2_to_1_Jubjub.circom"; +include "../../circom_circuits/hash/poseidon/poseidon_4_to_1_Jubjub.circom"; +include "../../circom_circuits/hash/poseidon/poseidon_16_to_1_Jubjub.circom"; +include "../../circom_circuits/circomlib/circuits/bitify.circom"; +include ".../../circom_circuits/circomlib/circuits/sha256/sha256.circom"; template BLSLessThan(n) { assert(n <= 253); diff --git a/proof_of_leadership/circom/leadership_sha256.circom b/proof_of_leadership/circom/leadership_sha256.circom index cbe7e65..87eb9be 100644 --- a/proof_of_leadership/circom/leadership_sha256.circom +++ b/proof_of_leadership/circom/leadership_sha256.circom @@ -1,8 +1,8 @@ //test pragma circom 2.1.9; -include "../../circomlib-master/circuits/sha256/sha256.circom"; -include "../../circomlib-master/circuits/bitify.circom"; +include "../../circom_circuits/circomlib/circuits/sha256/sha256.circom"; +include "../../circom_circuits/circomlib/circuits/bitify.circom"; template BLSLessThan(n) { assert(n <= 253);