Skip to content

Commit 8ef3919

Browse files
authored
chore: make the DAVerifier methods internal (#239)
<!-- 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 Closes #237 ## 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
1 parent 3a552d8 commit 8ef3919

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/lib/verifier/DAVerifier.sol

+5-5
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ library DAVerifier {
7878
/// @return `true` if the proof is valid, `false` otherwise.
7979
/// @return an error code if the proof is invalid, ErrorCodes.NoError otherwise.
8080
function verifySharesToDataRootTupleRoot(IDAOracle _bridge, SharesProof memory _sharesProof, bytes32 _root)
81-
external
81+
internal
8282
view
8383
returns (bool, ErrorCodes)
8484
{
@@ -136,7 +136,7 @@ library DAVerifier {
136136
BinaryMerkleProof memory _rowProof,
137137
AttestationProof memory _attestationProof,
138138
bytes32 _root
139-
) public view returns (bool, ErrorCodes) {
139+
) internal view returns (bool, ErrorCodes) {
140140
// checking that the data root was committed to by the Blobstream smart contract
141141
if (
142142
!_bridge.verifyAttestation(
@@ -167,7 +167,7 @@ library DAVerifier {
167167
BinaryMerkleProof[] memory _rowProofs,
168168
AttestationProof memory _attestationProof,
169169
bytes32 _root
170-
) public view returns (bool, ErrorCodes) {
170+
) internal view returns (bool, ErrorCodes) {
171171
// checking that the data root was committed to by the Blobstream smart contract
172172
if (
173173
!_bridge.verifyAttestation(
@@ -202,7 +202,7 @@ library DAVerifier {
202202
/// @return The square size of the corresponding block.
203203
/// @return an error code if the _proof is invalid, Errors.NoError otherwise.
204204
function computeSquareSizeFromRowProof(BinaryMerkleProof memory _proof)
205-
external
205+
internal
206206
pure
207207
returns (uint256, ErrorCodes)
208208
{
@@ -221,7 +221,7 @@ library DAVerifier {
221221
/// Note: the minimum square size is 1. Thus, we don't expect the proof not to contain any side node.
222222
/// @param _proof The proof of the shares to the row/column root.
223223
/// @return The square size of the corresponding block.
224-
function computeSquareSizeFromShareProof(NamespaceMerkleMultiproof memory _proof) external pure returns (uint256) {
224+
function computeSquareSizeFromShareProof(NamespaceMerkleMultiproof memory _proof) internal pure returns (uint256) {
225225
uint256 extendedSquareRowSize = 2 ** _proof.sideNodes.length;
226226
// we divide the extended square row size by 2 because the square size is the
227227
// the size of the row of the original square size.

0 commit comments

Comments
 (0)