mirror of
https://github.com/logos-storage/nim-groth16.git
synced 2026-01-03 14:13:08 +00:00
18 lines
573 B
Nim
18 lines
573 B
Nim
|
|
import groth16/test_proof
|
|
import groth16/files/export_json
|
|
|
|
#-------------------------------------------------------------------------------
|
|
|
|
proc exampleProveAndVerify() =
|
|
let zkey_fname : string = "./build/product.zkey"
|
|
let wtns_fname : string = "./build/product.wtns"
|
|
let proof = testProveAndVerify( zkey_fname, wtns_fname)
|
|
|
|
exportPublicIO( "./build/nim_public.json" , proof )
|
|
exportProof( "./build/nim_proof.json" , proof )
|
|
|
|
#-------------------------------------------------------------------------------
|
|
|
|
when isMainModule:
|
|
exampleProveAndVerify() |