ビジネスロジックと経済的セキュリティのテスト (Testing Business Logic and Economic Security)
説明
例: 不適切なインセンティブ構造
// Push-based withdrawal process (vulnerable)
function withdraw(uint256 amount) public {
require(balance[msg.sender] >= amount, "Insufficient balance");
payable(msg.sender).transfer(amount); // Push-based transfer
balance[msg.sender] -= amount;
}影響
対策
テスト 1: 経済モデルの完全性を確認してロジックの欠陥を防御する
脆弱なコード:
なぜ脆弱なのか
修正されたコード:
チェック方法
Previousポリシー、手続き、コード管理のテスト (Testing Policies, Procedures, and Code Management)Nextアクセス制御と認証の脆弱性のテスト (Testing Access Control and Authentication Vulnerabilties)
Last updated