Skip to content

Commit

Permalink
fix(blob): potential inclusion proof has bug (#1832)
Browse files Browse the repository at this point in the history
  • Loading branch information
itsdevbear authored Jul 31, 2024
1 parent 90772c9 commit f6f3f66
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 2 additions & 0 deletions mod/consensus-types/pkg/types/body.go
Original file line number Diff line number Diff line change
Expand Up @@ -298,6 +298,8 @@ func (b *BeaconBlockBody) GetTopLevelRoots() []common.Root {
b.GetGraffiti().HashTreeRoot(),
Deposits(b.GetDeposits()).HashTreeRoot(),
b.GetExecutionPayload().HashTreeRoot(),
// I think this is a bug.
common.Root{},
}
}

Expand Down
3 changes: 1 addition & 2 deletions mod/da/pkg/blob/factory.go
Original file line number Diff line number Diff line change
Expand Up @@ -137,9 +137,8 @@ func (f *SidecarFactory[BeaconBlockT, BeaconBlockBodyT]) BuildBlockBodyProof(
) ([]common.Root, error) {
startTime := time.Now()
defer f.metrics.measureBuildBlockBodyProofDuration(startTime)
membersRoots := body.GetTopLevelRoots()
tree, err := merkle.NewTreeWithMaxLeaves[common.Root](
membersRoots,
body.GetTopLevelRoots(),
body.Length()-1,
)
if err != nil {
Expand Down

0 comments on commit f6f3f66

Please sign in to comment.