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

bug: simulator oracle getNotes' leaf index does not match private data tree #788

Closed
dbanks12 opened this issue Jun 9, 2023 · 0 comments
Closed

Comments

@dbanks12
Copy link
Collaborator

dbanks12 commented Jun 9, 2023

This bug was discovered with the introduction of read requests. Prior to this there were 0 membership checks occurring for reads of private notes/commitments.

In client_execution_context.ts's fetchNotes, the calll simulator oracle's getNotes retrieves a leaf index from the DB that does not match its location in the private data tree. Debugging the e2e cross chain messaging test led to the discovery that when leafIndex 5 is communicated from the simulator (via getNotes2), the corresponding leaf is 0, but the commitment described by its read request lives at leaf index 17.

I debugged this by adding in helper functions on the kernel oracle and aztec node to get leaf index by value etc. This exposed that when the the simulator oracle says there is a valid note at index 5, the node says there is no commitment at that index, and in fact that commitment exists at leaf index 17.

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

No branches or pull requests

1 participant