diff --git a/advanced_expert/vulnerabilities/reentrancy_attacks/README.md b/advanced_expert/vulnerabilities/reentrancy_attacks/README.md index 625b03c..d9c0763 100644 --- a/advanced_expert/vulnerabilities/reentrancy_attacks/README.md +++ b/advanced_expert/vulnerabilities/reentrancy_attacks/README.md @@ -1,6 +1,7 @@ ## reentrancy attacks
+

@@ -73,6 +74,14 @@ function withdrawBalance() public noReentrant { #### Option 2: CEI (checks effects interaction) pattern +
+ +

+ +

+ +
+ ``` function withdrawBalance() public { uint amountToWithdraw = userBalances[msg.sender]; @@ -90,6 +99,8 @@ function withdrawBalance() public { ### resources +
+ * [reentrancy on solidity docs](https://docs.soliditylang.org/en/latest/security-considerations.html#re-entrancy) * [reentrancy on DASP](https://www.dasp.co/#item-1) * [reentrancy on SWC](https://swcregistry.io/docs/SWC-107)