background
logo

Security Audit Report for bitget's bgw-new-staking-evm

项目简介

The target of this audit is the private code repository of bgw-new-staking-evm of bitget. This project implements a secure staking protocol that allows users to stake BWB tokens in customizable pools. The contract Staking enables pool creation with flexible parameters, stake/unstake operations with signature verification, and proportional reward distribution. It incorporates security features like reentrancy guards and pause functionality while maintaining transparent reward calculations. The system provides a reliable DeFi infrastructure for decentralized staking services through careful state management and validation checks.

Please refer to the report for the detailed audit scope.

Our audit methodology employs automated vulnerability scans, manual verification, and business logic analysis to uncover potential security issues coupled with gas and code quality optimization recommendations.

In summary, we have found that the codebase contains 1 high-risk issue that require prompt attention. In addition, we have identified other non-critical issues as well as recommendations and notes that should be considered. The bgw-new-staking-evm team has addressed these issues promptly. It is important to note that our audit covers only the final reported versions of the codebase. Any subsequent updates would require a re-evaluation.

关键发现

我们在该智能合约中共发现 3 个潜在问题,另有 6 条建议与 2 条说明,明细如下:

高风险:1
中风险:0
低风险:2
建议:6
说明:2
ID Severity Description Status
1 High Rewards remain claimable for unstaked orders Fixed
2 Low Incorrect update logic of variable stakeVisible Fixed
3 Low Lack of updating rewardAmount in function unStakeAndClaim() Confirm
4 - Remove redundant code Fixed
5 - Add additional check for _orderId Fixed
6 - Add additional check for _pool.poolId Fixed
7 - Gas optimization inside low-level call Fixed
8 - Revise code typos Fixed
9 - Revise the timestamp comparison in the function _calcCurrentRewards() Fixed
10 - Potential centralization risks -
11 - Ensure sufficient BWB token balance for fair reward distribution -

更多细节见审计报告

迈出走向安全的第一步

立即联系我们,获取 BlockSec 的专业代码审计服务,在协议上线之前把安全性提上来!