* unify fe/be NativeOp and NativePred
* remove Origin in favour of PodId
* Combine string and hash in Key
* use middleware::AnchoredKey in frontend
* merge frontend/middleware types
* refactor custom predicates
* clean up a bit
* fix middleware custom tests
* clean up
* clean up 2
* add acronyms in typos list
* sync spec & code
* move primitives (merkletree) into the backend
* comment on the ops spec and link to issue #108
* typo
* fix github-ci mdbook-publish pages
* wip
* prototype custom predicates 1b
* feat: implement custom pred recursion
* files reorg, add github CI for rustfmt checks
* start sparsemerkletree. impl add_leaf method, initial Leaf & Intermediate types with methods
* mt: add hash computation of all the nodes in the tree, add method to print the tree to visualize it as a graphviz
* mt: add (till the leaf) method which is used by get,contains,prove methods
* mt: add verify (of inclusion) method
* mt: update 'down' method to reuse siblings, update get,contains,prove methods (the three use 'down' under the hood)
* Add nonexistence proofs and iterator
* Add iterator test
* migrate usage of old merkletree to the new merkletree impl in POD2 code
---------
Co-authored-by: Eduard S. <eduardsanou@posteo.net>
Co-authored-by: Ahmad <root@ahmadafuni.com>
* Implement Containers (Dictionary,Set,Array) on top of MerkleTree. And restructure the code.
- Reorganize the code grouping backends, middleware, frontend, (crypto) primitives.
- Add types Dictionary,Set,Array at the middleware layer, so that
it can be used both by the backend and frontend. The Dictionary, Set,
Array use the merkletree differently as specified at
f2575d1524/book/src/values.md (dictionary-array-set)
- The containers introduce the trait Container, which has the
method 'cm()'. At the current version this uses a merkletree
under the hood, and the method 'cm' returns the merkle root.
- Ideally neither frontend nor backend use the MerkleTree type, and they
use the wrappers {Dictionary,Set,Array}. Note that the current commit
the MerkleTree is used at the mock-backend to check internal values, but
not at the struct types.
- updated the spec's merkletree section updating the defined interface
- add github ci to run the tests
---------
Co-authored-by: Ahmad Afuni <root@ahmadafuni.com>
Co-authored-by: Eduard S. <eduardsanou@posteo.net>
* Progress towards mock MainPod verification
* add MockMainPod.pub_statements logic so that when originid==SELF it is replaced by self.id()
* Basic op checking for mock MainPOD
* More op checking
* wip
* feat: add great boy example
* feat: put examples under cfg(test)
---------
Co-authored-by: Ahmad <root@ahmadafuni.com>
Co-authored-by: arnaucube <git@arnaucube.com>
Add initial MerkleTree implementation, which is a wrapper on top of
Plonky2's MerkleTree, with the idea that the future iteration will
replace it by the MerkleTree specified at
https://0xparc.github.io/pod2/merkletree.html .