Skip to content

Commit

Permalink
fix: fix da verifier row root node creation (#197)
Browse files Browse the repository at this point in the history
<!--
Please read and fill out this form before submitting your PR.

Please make sure you have reviewed our contributors guide before
submitting your
first PR.
-->

## Overview

<!-- 
Please provide an explanation of the PR, including the appropriate
context,
background, goal, and rationale. If there is an issue with this
information,
please provide a tl;dr and link the issue. 
-->

closes #193

The test that fails if this fix is absent is in here:
#160

## Checklist

<!-- 
Please complete the checklist to ensure that the PR is ready to be
reviewed.

IMPORTANT:
PRs should be left in Draft until the below checklist is completed.
-->

- [ ] New and updated code has appropriate documentation
- [ ] New and updated code has new and/or updated testing
- [ ] Required CI checks are passing
- [ ] Visual proof for any user facing features like CLI or
documentation updates
- [ ] Linked issues closed with keywords
  • Loading branch information
rach-id authored Sep 19, 2023
1 parent 288d9bb commit bf1dd38
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/lib/verifier/DAVerifier.sol
Original file line number Diff line number Diff line change
Expand Up @@ -107,11 +107,9 @@ library DAVerifier {
uint256 cursor = 0;
for (uint256 i = 0; i < _sharesProof.shareProofs.length; i++) {
uint256 sharesUsed = _sharesProof.shareProofs[i].endKey - _sharesProof.shareProofs[i].beginKey;
NamespaceNode memory rowRoot =
NamespaceNode(_sharesProof.namespace, _sharesProof.namespace, _sharesProof.rowRoots[i].digest);
if (
!NamespaceMerkleTree.verifyMulti(
rowRoot,
_sharesProof.rowRoots[i],
_sharesProof.shareProofs[i],
_sharesProof.namespace,
slice(_sharesProof.data, cursor, cursor + sharesUsed)
Expand Down

0 comments on commit bf1dd38

Please sign in to comment.