├── .eslintignore ├── .eslintrc.json ├── .github └── workflows │ └── push.yml ├── .gitignore ├── .husky ├── .gitignore └── pre-commit ├── .mocharc.json ├── .npmrc ├── .prettierignore ├── .releaserc.yml ├── LICENSE ├── README.md ├── circuits ├── common │ ├── verify-hydra-commitment.circom │ └── verify-merkle-path.circom └── hydra-s1.circom ├── hardhat.config.ts ├── package.json ├── package ├── README.md ├── contracts │ └── HydraS1Verifier.sol ├── package.json ├── rollup.config.js ├── scripts │ ├── copy-files-in-lib.sh │ └── copy-wasm-zkey.sh ├── src │ ├── index.ts │ ├── prover │ │ ├── @types │ │ │ └── index.d.ts │ │ ├── constants.ts │ │ ├── files-cjs.ts │ │ ├── files-esm.ts │ │ ├── files.ts │ │ ├── hydra-s1-prover.ts │ │ ├── hydra-s1.wasm │ │ ├── hydra-s1.zkey │ │ ├── index.ts │ │ ├── snark-proof.ts │ │ ├── types.ts │ │ └── utils │ │ │ ├── fill.ts │ │ │ └── verify-commitment.ts │ └── verifier │ │ ├── @types │ │ └── index.d.ts │ │ ├── hydra-s1-verification-key.json │ │ ├── hydra-s1-verifier.ts │ │ └── index.ts ├── tsconfig.json └── yarn.lock ├── scripts ├── clean.sh ├── compile-circuit.sh └── generate-contract.sh ├── test ├── circuits.test.ts ├── prover.test.ts ├── utils │ └── circuit-should-fail.ts ├── verifier-contract.test.ts └── verifier.test.ts ├── tsconfig.json └── yarn.lock /.eslintignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/.eslintignore -------------------------------------------------------------------------------- /.eslintrc.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/.eslintrc.json -------------------------------------------------------------------------------- /.github/workflows/push.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/.github/workflows/push.yml -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/.gitignore -------------------------------------------------------------------------------- /.husky/.gitignore: -------------------------------------------------------------------------------- 1 | _ 2 | -------------------------------------------------------------------------------- /.husky/pre-commit: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | . "$(dirname "$0")/_/husky.sh" 3 | 4 | npx lint-staged 5 | -------------------------------------------------------------------------------- /.mocharc.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/.mocharc.json -------------------------------------------------------------------------------- /.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict = true -------------------------------------------------------------------------------- /.prettierignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/.prettierignore -------------------------------------------------------------------------------- /.releaserc.yml: -------------------------------------------------------------------------------- 1 | { 2 | "branches": ["main"] 3 | } -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/README.md -------------------------------------------------------------------------------- /circuits/common/verify-hydra-commitment.circom: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/circuits/common/verify-hydra-commitment.circom -------------------------------------------------------------------------------- /circuits/common/verify-merkle-path.circom: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/circuits/common/verify-merkle-path.circom -------------------------------------------------------------------------------- /circuits/hydra-s1.circom: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/circuits/hydra-s1.circom -------------------------------------------------------------------------------- /hardhat.config.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/hardhat.config.ts -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package.json -------------------------------------------------------------------------------- /package/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/README.md -------------------------------------------------------------------------------- /package/contracts/HydraS1Verifier.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/contracts/HydraS1Verifier.sol -------------------------------------------------------------------------------- /package/package.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/package.json -------------------------------------------------------------------------------- /package/rollup.config.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/rollup.config.js -------------------------------------------------------------------------------- /package/scripts/copy-files-in-lib.sh: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/scripts/copy-files-in-lib.sh -------------------------------------------------------------------------------- /package/scripts/copy-wasm-zkey.sh: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/scripts/copy-wasm-zkey.sh -------------------------------------------------------------------------------- /package/src/index.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/src/index.ts -------------------------------------------------------------------------------- /package/src/prover/@types/index.d.ts: -------------------------------------------------------------------------------- 1 | declare module "snarkjs"; 2 | -------------------------------------------------------------------------------- /package/src/prover/constants.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/src/prover/constants.ts -------------------------------------------------------------------------------- /package/src/prover/files-cjs.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/src/prover/files-cjs.ts -------------------------------------------------------------------------------- /package/src/prover/files-esm.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/src/prover/files-esm.ts -------------------------------------------------------------------------------- /package/src/prover/files.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/src/prover/files.ts -------------------------------------------------------------------------------- /package/src/prover/hydra-s1-prover.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/src/prover/hydra-s1-prover.ts -------------------------------------------------------------------------------- /package/src/prover/hydra-s1.wasm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/src/prover/hydra-s1.wasm -------------------------------------------------------------------------------- /package/src/prover/hydra-s1.zkey: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/src/prover/hydra-s1.zkey -------------------------------------------------------------------------------- /package/src/prover/index.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/src/prover/index.ts -------------------------------------------------------------------------------- /package/src/prover/snark-proof.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/src/prover/snark-proof.ts -------------------------------------------------------------------------------- /package/src/prover/types.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/src/prover/types.ts -------------------------------------------------------------------------------- /package/src/prover/utils/fill.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/src/prover/utils/fill.ts -------------------------------------------------------------------------------- /package/src/prover/utils/verify-commitment.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/src/prover/utils/verify-commitment.ts -------------------------------------------------------------------------------- /package/src/verifier/@types/index.d.ts: -------------------------------------------------------------------------------- 1 | declare module "snarkjs"; 2 | -------------------------------------------------------------------------------- /package/src/verifier/hydra-s1-verification-key.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/src/verifier/hydra-s1-verification-key.json -------------------------------------------------------------------------------- /package/src/verifier/hydra-s1-verifier.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/src/verifier/hydra-s1-verifier.ts -------------------------------------------------------------------------------- /package/src/verifier/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./hydra-s1-verifier"; 2 | -------------------------------------------------------------------------------- /package/tsconfig.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/tsconfig.json -------------------------------------------------------------------------------- /package/yarn.lock: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/package/yarn.lock -------------------------------------------------------------------------------- /scripts/clean.sh: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/scripts/clean.sh -------------------------------------------------------------------------------- /scripts/compile-circuit.sh: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/scripts/compile-circuit.sh -------------------------------------------------------------------------------- /scripts/generate-contract.sh: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/scripts/generate-contract.sh -------------------------------------------------------------------------------- /test/circuits.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/test/circuits.test.ts -------------------------------------------------------------------------------- /test/prover.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/test/prover.test.ts -------------------------------------------------------------------------------- /test/utils/circuit-should-fail.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/test/utils/circuit-should-fail.ts -------------------------------------------------------------------------------- /test/verifier-contract.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/test/verifier-contract.test.ts -------------------------------------------------------------------------------- /test/verifier.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/test/verifier.test.ts -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/tsconfig.json -------------------------------------------------------------------------------- /yarn.lock: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sismo-core/hydra-s1-zkps/HEAD/yarn.lock --------------------------------------------------------------------------------