Package change name

This commit is contained in:
Jordi Baylina 2018-12-20 08:28:11 +01:00
parent 9cab539698
commit 345f040b41
No known key found for this signature in database
GPG Key ID: 7480C80C1BE43112
6 changed files with 51 additions and 4 deletions

BIN
doc/rollup_tx.monopic Normal file

Binary file not shown.

BIN
doc/root_transfer.monopic Normal file

Binary file not shown.

Binary file not shown.

BIN
doc/voting.monopic Normal file

Binary file not shown.

@ -1,7 +1,7 @@
{ {
"name": "cirpedersen", "name": "circomlib",
"version": "0.0.3", "version": "0.0.1",
"description": "Pesersen Circuit for Circom", "description": "Basic circuits library for Circom",
"main": "index.js", "main": "index.js",
"directories": { "directories": {
"test": "test" "test": "test"
@ -17,7 +17,11 @@
"circom", "circom",
"zksnark" "zksnark"
], ],
"author": "Jordi Baylina", "repository": {
"type": "git",
"url": "https://github.com/iden3/circomlib.git"
},
"author": "0Kims",
"license": "GPL-3.0", "license": "GPL-3.0",
"dependencies": { "dependencies": {
"blake-hash": "^1.1.0", "blake-hash": "^1.1.0",

43
rolluptx.circom Normal file

@ -0,0 +1,43 @@
/*
fnc[0] fn[1] Function S1 S2 S3 S4
0 0 NOP 0 0 0 0
0 1 TRANSFER 0 1 0 1
1 0 ENTRY 0 1 0 1
1 1 EXIT 1 0 1 1
*/
template rollupTx(nLevels) {
signal input fromIdx; // 24
signal input toIdx; // 24
signal input fpTxAmount; // 24
signal input fnc[2]; // 2
signal oldRoot;
signal newRoot;
signal input sigR8;
signal input sigS;
// State 1
signal input Ax1;
signal input Ay1;
signal input St1;
signal input siblings1[nlevels];
// Required for inserts and delete
signal input isOld0_1; // 1
signal input oldKey;
signal input oldValue;
// State 2
signal input Ax2;
signal input Ay2;
signal input St2;
signal input siblings2[nlevels];
signal input isOld0_1; // 1
signal input oldKey;
signal input oldValue;
}