StateDB ZKInputs generation compatible with circom

- Add SignatureConstant to L1Tx.TxCompressedData
- ZKInputs generation works initial version working and compatible with circom Hermez circuit
    - Lots of small updates for circuits compatibility
- Update version (with new changes) of `go-iden3-crypto` & `go-merkletree`
This commit is contained in:
arnaucube
2020-12-01 22:15:19 +01:00
parent d306f4890a
commit 80cbac24f9
13 changed files with 187 additions and 105 deletions

View File

@@ -60,9 +60,9 @@ func TestL1TxCompressedData(t *testing.T) {
assert.Nil(t, err)
// test vector value generated from javascript implementation
expectedStr := "7307597389635308713748674793997299267460566876160"
expectedStr := "7307597389635308713748674793997299267459594577423"
assert.Equal(t, expectedStr, txCompressedData.String())
assert.Equal(t, "050004000000000003000000000002000100000000", hex.EncodeToString(txCompressedData.Bytes()))
assert.Equal(t, "0500040000000000030000000000020000c60be60f", hex.EncodeToString(txCompressedData.Bytes()))
}
func TestBytesDataAvailability(t *testing.T) {