hermeznetwork / circuits

Implements hermez network zk-Snarks circuits
GNU Affero General Public License v3.0
55 stars 21 forks source link

force auxToIdx in L2TxData if toIdx == 0 #22

Closed krlosMata closed 3 years ago

krlosMata commented 3 years ago

Issue

Since in transferToEthAddr or transferToBjj the toIdx signed is IDX 0, it does not provide enough information as data-availability to reconstruct the state tree

Fix

Circuit must force to use auxToIdx in case of an L2 transaction with toIdx == IDX 0