Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement proofs of page inclusion #289

Merged
merged 6 commits into from
Nov 9, 2023
Merged

Implement proofs of page inclusion #289

merged 6 commits into from
Nov 9, 2023

Conversation

ureeves
Copy link
Member

@ureeves ureeves commented Oct 31, 2023

Introduces Session::memory_pages, returning an iterator over a contract's pages, together with an inclusion proof - expressed in a new type PageOpening.

PageOpening leverages dusk-merkle to allow for verification that a page is indeed in a state with the given root.

Resolves #273

A `Module` now contains an actual `dusk_wasmtime::Module`, as opposed to
just some bytes, since it allows us to check for some invariants.
@ureeves ureeves force-pushed the tree-inclusion-273 branch from 8020e66 to 2f58949 Compare November 1, 2023 16:09
Two different trees are created - one for 32-bit and another for 64-bit
- and ensure they're properly distinguished.
@ureeves ureeves force-pushed the tree-inclusion-273 branch from 2f58949 to 7733fd7 Compare November 1, 2023 16:09
Eduardo Leegwater Simões added 3 commits November 6, 2023 15:45
Introduces `Session::memory_pages`, returning an iterator over a
contract's pages, together with an inclusion proof - expressed in a new
type `PageOpening`.

`PageOpening` leverages `dusk-merkle` to allow for verification that a
page is indeed in a state with the given root.

Resolves #273
@ureeves ureeves marked this pull request as ready for review November 6, 2023 15:20
Copy link
Member

@HDauven HDauven left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Copy link
Contributor

@miloszm miloszm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Member

@moCello moCello left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

piecrust/src/store.rs Outdated Show resolved Hide resolved
@ureeves ureeves merged commit 893d044 into main Nov 9, 2023
4 checks passed
@ureeves ureeves deleted the tree-inclusion-273 branch November 9, 2023 09:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement memory page proof of inclusion
4 participants