private boolean blockBodyMatchesBlockHeader(
      final BlockBody blockBody, final BlockHeader blockHeader) {
    // this method validates that the block body matches the block header by calculating the roots
    // of the block body and comparing them to the roots in the block header
    if (!BodyValidation.transactionsRoot(blockBody.getTransactions())
        .equals(blockHeader.getTransactionsRoot())) {
      return false;
    }
    if (!BodyValidation.ommersHash(blockBody.getOmmers()).equals(blockHeader.getOmmersHash())) {
      return false;
    }
    if (!blockBody
        .getWithdrawals()
        .map(BodyValidation::withdrawalsRoot)
        .equals(blockHeader.getWithdrawalsRoot())) {
      return false;
    }

    return true;
  }
Implements PeerTask for getting block bodies from peers, and matches headers to bodies to supply
full blocks
ethereum/eth/src/main/java/org/hyperledger/besu/ethereum/eth/manager/peertask/task/GetBodiesFromPeerTask.java