Bracket engaged Guardian to review the security of their kyc functionality. From the 17th of April to the 18th of April, a team of 3 auditors reviewed the source code in scope.
- Published
- Review window
- April 17 to 18, 2025
- Language
- Solidity
- Chains
- Ethereum
- Sector
- Governance
- 0 Critical
- 1 High
- 2 Medium
- 1 Low
- 6 Informational
Scope
Overview
Bracket engaged Guardian to review the security of their kyc functionality. From the 17th of April to the 18th of April, a team of 3 auditors reviewed the source code in scope.
Findings 10
-
H-01 High Incorrect stethAmount Used Logical Error Resolved
Description
In the
_lidoEthToBrktETHfunction the return value from the submit function is used as thestEthamount gained from the submit call.However the return value represents the amount of
stEthshares, not the amount ofstEthwhich were gained from the submit call.As a result a significant portion of
stEthwill be left in the router contract and the user will not receivebracketEthfor this amount.Recommendation
Use the difference between the
stEthbalance before and after calling the submit function to wrap in thewstEthcontract.Resolution
Bracket Team: The issue was resolved in commit c23fed5.
-
M-01 Medium KycWhitelist Cannot Be Deployed Logical Error Resolved
Description
The
KYCWhitelistcontract cannot be successfully deployed because the initializing functions used in the constructor use anonlyInitializingmodifier.Recommendation
Refactor the
KYCWhitelistcontract so that the constructor is the initializer or make a separate initializer function.Resolution
Bracket Team: The issue was resolved in commit 7b70cb2.
-
M-02 Medium Incorrect STETH Address Logical Error Resolved
Description
The
STETHaddress in theConfigcontract is incorrect as it points to theSTETHimplementation contract (0x17144556fd3424EDC8Fc8A4C940B2D04936d17eb) rather than the correct proxy contract (0xae7ab96520de3a18e5e111b5eaab095312d7fe84).Recommendation
Update the STETH address to be the correct proxy address.
Resolution
Bracket Team: The issue was resolved in commit ca93c8a.
-
L-01 Low Missing Whitelisted From Check Validation Resolved
Description
In the
_updatefunction there is no validation that the from address is whitelisted on transfer. This allows unwhitelisted addresses to transfer to whitelisted addresses which may be unexpected.Recommendation
Consider adding validation that the from address is also whitelisted in the
_updatefunction.Resolution
Bracket Team: The issue was resolved in commit 70793e1.
-
I-01 Informational Transfer Optimization Documentation Resolved
Description
The
_updatefunction performs_clearDepositin all cases, even when the_updateinvocation is for a mint or burn call.There are no significant issues from this as the
_clearDepositcall will always early return for minting and burning updates.However to avoid any hidden introduction of issues in the future and to optimize gas expenditure, this unexpected execution should be avoided.
Recommendation
Consider only invoking the
_clearDepositfunction when the from address and to address are both nonzero, indicating that the update action is a legitimate transfer.Resolution
Bracket Team: The issue was resolved in commit 6717a3d.
-
I-02 Informational Unnecessary Payable Modifier Best Practices Resolved
Description
The
wethToBrktETHfunction includes apayablemodifier yet does not handlemsg.value.Recommendation
Remove the
payablemodifier from thewethToBrktETHfunction.Resolution
Bracket Team: The issue was resolved in commit 566e943.
-
I-03 Informational Misleading ETHToBrktETH Event Data Events Resolved
Description
The
ETHToBrktETHevent emission in theethToBrktETHandwethToBrktETHfunctions emits the minimum acceptablebrktEthamount rather than the actual mintedbrktEthamount from the action. This may be misleading for consumers of theETHToBrktETHevent.Recommendation
Consider if the actual minted
brktEthamount should be emitted in theETHToBrktETHevent.Resolution
Bracket Team: The issue was resolved in commit b0f4119.
-
I-04 Informational Missing VanityNavUpdated Event Events Acknowledged
Description
The
updateNavfunction updates thevanityNavbut does not emit aVanityNavUpdatedevent. This may mislead indexers and consumers of theVanityNavUpdatedevent if they are not aware of this behavior.Recommendation
Consider if this behavior is intended, if not, consider emitting the
VanityNavUpdatedevent in theupdateNavfunction.Resolution
Bracket Team: Acknowledged.
-
I-05 Informational Unnecessary Paused Check Gas Optimization Resolved
Description
In the
lidoLimitfunction theisStakingPausedfunction is queried on the steth contract. If staking is paused the result of the limit is 0.However this logic is already included in the lido underlying
getCurrentStakeLimitfunction and therefore is unnecessary in thelidoLimitfunction.Recommendation
Consider removing the unnecessary
isStakingPausedlogic in thelidoLimitfunction.Resolution
Bracket Team: The issue was resolved in commit b677547.
-
I-06 Informational Hardcoded RocketDepositPool Best Practices Acknowledged
Description
The
RocketDepositPoolcontract is hardcoded as a constant in theBrktEthRoutercontract. However the latestRocketDepositPoolis allowed to change in theRocketStoragecontract.Recommendation
Be aware of this possibility and consider adding a setter function for the
RocketDepositPoolcontract in case it were to be updated by Rocket Pool.Resolution
Bracket Team: Acknowledged.
No findings match.
More from Bracket
Put your code through the same review.
This review started with a conversation about scope. Tell us what you are building and we will plan yours with you.
