-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
30 changed files
with
6,916 additions
and
4,181 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
95 changes: 95 additions & 0 deletions
95
assets/registerIdentityLight256.dev/RegisterIdentityLight256.groth16.vkey.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,95 @@ | ||
{ | ||
"protocol": "groth16", | ||
"curve": "bn128", | ||
"nPublic": 3, | ||
"vk_alpha_1": [ | ||
"20491192805390485299153009773594534940189261866228447918068658471970481763042", | ||
"9383485363053290200918347156157836566562967994039712273449902621266178545958", | ||
"1" | ||
], | ||
"vk_beta_2": [ | ||
[ | ||
"6375614351688725206403948262868962793625744043794305715222011528459656738731", | ||
"4252822878758300859123897981450591353533073413197771768651442665752259397132" | ||
], | ||
[ | ||
"10505242626370262277552901082094356697409835680220590971873171140371331206856", | ||
"21847035105528745403288232691147584728191162732299865338377159692350059136679" | ||
], | ||
["1", "0"] | ||
], | ||
"vk_gamma_2": [ | ||
[ | ||
"10857046999023057135944570762232829481370756359578518086990519993285655852781", | ||
"11559732032986387107991004021392285783925812861821192530917403151452391805634" | ||
], | ||
[ | ||
"8495653923123431417604973247489272438418190587263600148770280649306958101930", | ||
"4082367875863433681332203403145435568316851327593401208105741076214120093531" | ||
], | ||
["1", "0"] | ||
], | ||
"vk_delta_2": [ | ||
[ | ||
"10024655051728395812564307039738346388454604848124933406202507965194273799917", | ||
"10937043963655185952891449223625636213959039570715537527210240567875698546497" | ||
], | ||
[ | ||
"19680239487707527798110040460768721884036997340435808307578785917462138857357", | ||
"3288878702757913739253373321195210173509136075843368700533242800223626150044" | ||
], | ||
["1", "0"] | ||
], | ||
"vk_alphabeta_12": [ | ||
[ | ||
[ | ||
"2029413683389138792403550203267699914886160938906632433982220835551125967885", | ||
"21072700047562757817161031222997517981543347628379360635925549008442030252106" | ||
], | ||
[ | ||
"5940354580057074848093997050200682056184807770593307860589430076672439820312", | ||
"12156638873931618554171829126792193045421052652279363021382169897324752428276" | ||
], | ||
[ | ||
"7898200236362823042373859371574133993780991612861777490112507062703164551277", | ||
"7074218545237549455313236346927434013100842096812539264420499035217050630853" | ||
] | ||
], | ||
[ | ||
[ | ||
"7077479683546002997211712695946002074877511277312570035766170199895071832130", | ||
"10093483419865920389913245021038182291233451549023025229112148274109565435465" | ||
], | ||
[ | ||
"4595479056700221319381530156280926371456704509942304414423590385166031118820", | ||
"19831328484489333784475432780421641293929726139240675179672856274388269393268" | ||
], | ||
[ | ||
"11934129596455521040620786944827826205713621633706285934057045369193958244500", | ||
"8037395052364110730298837004334506829870972346962140206007064471173334027475" | ||
] | ||
] | ||
], | ||
"IC": [ | ||
[ | ||
"4179432338433124082507168334716073369977625424306513458535481875746097550658", | ||
"12714499129458131796726486922435073908760835207347394165560527204719372283417", | ||
"1" | ||
], | ||
[ | ||
"15796010941534208751370774490726059448355760291220049636894135052670536978530", | ||
"4411190147057228862091306245729888086078023337791017667104000774333055394870", | ||
"1" | ||
], | ||
[ | ||
"18796505394079206082600292661633691936761371596120188411147722737603294837590", | ||
"1121894399568100959910413213468154592683150638260580461512139659150923719975", | ||
"1" | ||
], | ||
[ | ||
"4678945113863386760438849690757650811219476819937609876975421977973533253953", | ||
"14173498963267645827891248481396713947897070300527005985896563335692207023061", | ||
"1" | ||
] | ||
] | ||
} |
Binary file added
BIN
+31.6 MB
assets/registerIdentityLight256.dev/RegisterIdentityLight256.groth16.zkey
Binary file not shown.
Binary file added
BIN
+2.83 MB
...ts/registerIdentityLight256.dev/registerIdentityLight256_js/RegisterIdentityLight256.wasm
Binary file not shown.
20 changes: 20 additions & 0 deletions
20
assets/registerIdentityLight256.dev/registerIdentityLight256_js/generate_witness.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
const wc = require("./witness_calculator.js"); | ||
const { readFileSync, writeFile } = require("fs"); | ||
|
||
if (process.argv.length != 5) { | ||
console.log("Usage: node generate_witness.js <file.wasm> <input.json> <output.wtns>"); | ||
} else { | ||
const input = JSON.parse(readFileSync(process.argv[3], "utf8")); | ||
|
||
const buffer = readFileSync(process.argv[2]); | ||
wc(buffer).then(async witnessCalculator => { | ||
// const w= await witnessCalculator.calculateWitness(input,0); | ||
// for (let i=0; i< w.length; i++){ | ||
// console.log(w[i]); | ||
// } | ||
const buff= await witnessCalculator.calculateWTNSBin(input,0); | ||
writeFile(process.argv[4], buff, function(err) { | ||
if (err) throw err; | ||
}); | ||
}); | ||
} |
Oops, something went wrong.