Граф коммитов

9 Коммитов

Автор SHA1 Сообщение Дата
ashWhiteHat 1e60918472
close issue 70 and badge (#71)
* chore: fix actions badge

* test: fix assertion

* chore: fix array method and fmt actions
2024-09-19 11:19:57 -07:00
Srinath Setty f30375e498
fix build (#68)
* fix build

* address clippy, switch to stable

* fix build
2024-04-11 16:57:14 -07:00
Ashutosh Varma 2be72b2af2
Improve Support for WASM (#60)
* feat: use `XofReader` instead of `io::Read` for no_std compatibility

* feat: remove `thiserror` dependency

thiserror is not no_std safe

* feat: move deps std features behind new `std` feature

- add new `std` feature
- add `simd_backend`
- move `colored` dep behind profile feature

* feat: use old rand(v0.7) for cubic example.

since curve25519-dalek (v3) uses old rand(v0.7) we need this.
should upgrade curve25519-dalek to v4 once it out of pre release

* feat: only build bench & profile if std in enabled

* feat: remove rand_core as dependency

* feat(ci): add job to test wasm build

* fix: rollback rand to v7 and update debug test

* fix(ci): Cargo.toml patching

* feat: make clippy happy

* feat: add wasm doc in readme

* feat: readme formatting

* feat: derive `Default` for `ProofVerifyError`
2023-01-17 09:40:30 -08:00
Srinath Setty 94e507e948
support for stable Rust (#51)
* support for stable Rust

* add no default to stable

* add no default to stable

* update CI
2022-08-01 18:50:04 -07:00
Srinath Setty 19d1d63703
Update to latest Rust and fix Clippy warnings (#37)
* Update to latest Rust and fix Clippy warnings

* cleanup
2021-10-14 16:11:19 -07:00
Lef Ioannidis 7bbc366e5d
Arbitrary number of variables and contraints (#34)
* This commit makes adding an arbitrary number of variables and inputs possible and removes the
  implementation leaking to the interface for

  num_inps + 1 <= num_vars, num_vars: a power of 2, num_cons: a power of 2, but not 1.

  1. When creating a new R1CS Instance throught the public interface,
     it is required # constraints and # of vars be a power of 2. I remove
     that requirement by padding with dummy constraints and vars until the nearest
     power of 2.
  2. The sumcheck protocol in src/sumcheck.rs does not work for 1 constraint, even
     though 1 is a power of 2. I have to pad to a minimum of two constraints.
  3. Added a test in src/r1csproof.rs called test_padded_constraints.

* Move test to src/lib.rs

* Remove padding metadata

* remove unused use

* Simplify padding to power of 2

* run cargo fmt

* Fix indexing bug

* Rayon is optional, depending on 'multicore' feature

* Update rust toolchain

* cargo fmt

* cleaner to track num_vars_padded and num_cons_padded

* cleanup

* further cleanup

* Cleanup & comments

* small fixes

* adjust code for padding constraints

* fix a bug with pad call

* add comment about num_nz_entries

* extend padding to NIZK methods

extend padding to NIZK methods

Co-authored-by: Lef Ioannidis <elefthei@seas.upenn.edu>
Co-authored-by: Srinath Setty <srinath@microsoft.com>
2021-04-22 10:27:54 -07:00
Srinath Setty 096c07910a
upgrade to use crates.io (#32) 2021-01-12 12:20:30 -08:00
Jakub Konka 7b102a241f
Add example proving knowledge of cubic equation solution (#26) 2020-09-16 09:41:13 -07:00
Srinath Setty 95b9ad35a6 initial commit 2020-07-24 14:41:48 -07:00