taiga icon indicating copy to clipboard operation
taiga copied to clipboard

Implement prototype validity predicates

Open ghost opened this issue 4 years ago • 2 comments

We need simple validity predicate circuits for testing, such as:

  1. Always-allow
  2. Always-deny
  3. Verify-signature

and some others, for both shielded addresses and tokens. Right now the bigger concern is designing and testing the VP circuit interfaces, and not writing perfect VPs that are for production use.

ghost avatar Oct 13 '21 02:10 ghost

We should try to implement every single example VP/example userflow to ensure the base protocol supports all of them.

There is a lot to do.

Signature support:

  • [ ] Implement external signature check support (key re-randomization) - 1 external check per VP
  • [ ] Implement in-circuit signature check
  • [ ] MuSig support for multisig

Spending VPs:

  • [ ] Single signature check simple transfer VP
  • [ ] Multisig check simple transfer VP
  • [ ] Content-based multisig check
  • [ ] Subscription
  • [ ] Conditional spend/joint funding of public good
  • [ ] Trade/swap intent (perhaps in conjunction with special trade intent token/token VP)

Receiving VP:

  • [ ] Allow all
  • [ ] Reject all
  • [ ] Whitelist sending address
  • [ ] Whitelist asset type

Token VP:

  • [ ] Check tx is balanced
  • [ ] Shield/unshield tokens
  • [ ] Token-type swap; mint/burn new/old token

VP features/misc:

  • [ ] Implement storing mutable VP data/state in a special NFT asset type
  • [ ] Implement self-referential and mutually-referential VPs by simultaneous derivation (@joebebel's suggestion)
  • [ ] Implement self-referential and mutually-referential VPs by signature-authenticated data (@clvv 's suggestion)
  • [ ] heliaxdev/pbc-playground#6
  • [ ] Write VP in Juvix heliaxdev/pbc-playground#16
  • [ ] Support VPs written in ark-plonk
  • [ ] Document all VPs in spec
  • [ ] Tests for all example VPs and features

Any other userflows we can think of (the more the better)

joebebel avatar Dec 09 '21 09:12 joebebel

What we should do here is:

  • Pick a small number of examples to implement in Rust in Taiga directly (maybe: signature check, simple barter, Sudoku)
  • Assign all the other examples to other teams & coordinate on integration with Taiga

cwgoes avatar Jan 17 '23 16:01 cwgoes