DeFi Security AllianceRequest an audit
Menu

DeFi Security Alliance Blog

Find an article for your task

1-20 of 104 articles.

Blog Articles

  • OpenZeppelin AccessControl: Verify Role Removal and Remaining Authority

    EVM patterns

    OpenZeppelin AccessControl: Verify Role Removal and Remaining Authority

    A role-removal receipt does not prove that an account has lost every privileged route. In 96 local cases using OpenZeppelin AccessControl v5.5.0, 17 successful removal calls were no-ops and subjects restored 5 of 9 actually removed minter memberships. Verify the membership change and the remaining administrator path separately.

    12 min read

  • CREATE2: Verify Initialized Ownership Before Funding

    EVM patterns

    CREATE2: Verify Initialized Ownership Before Funding

    A deterministic address does not establish the initialized owner. In 72 local CREATE2 tests, an unchecked registry produced unexpected owners in 16 of its 24 cases despite matching address predictions and runtime hashes. Accept the deployed authority separately before funding.

    12 min read

  • SafeERC20: Verify Token Receipts Before Crediting Deposits

    EVM patterns

    SafeERC20: Verify Token Receipts Before Crediting Deposits

    Use SafeERC20 to normalize ERC20 call failures, then decide how actual receipts become application credit. Our local tests show why a successful wrapper call can still leave nominal deposit credit larger than the tokens received.

    12 min read

  • Solidity Multicall: When Reserves Hide Repeated Native Credit

    EVM patterns

    Solidity Multicall: When Reserves Hide Repeated Native Credit

    A payable batch can credit one native payment repeatedly when delegated operations read the same message value. Solidity multicall security needs a payment allocation invariant because an existing reserve can conceal excess credit.

    12 min read

  • ERC20 Permit: ERC2612 Allowances and Application Authority

    EVM patterns

    ERC20 Permit: ERC2612 Allowances and Application Authority

    A permit grants a token allowance. The application must separately authorize the action using it. ERC20 permit security therefore requires both tolerant handling of already submitted signatures and a verified relationship between the funding owner and the beneficiary.

    12 min read

  • ERC20 Approval Race: Old Allowances and New Limits

    EVM patterns

    ERC20 Approval Race: Old Allowances and New Limits

    An ERC20 approval race lets a spender use an old allowance before its replacement executes, then use the new grant. Changing a limit needs evidence about prior transfers and the permission that remains. Zero-reset compatibility helpers do not establish that earlier spending never happened.

    12 min read

  • ERC6492 Signature Verification and the Prepare Retry

    EVM patterns

    ERC6492 Signature Verification and the Prepare Retry

    A wrapped smart account proof can run a deployment or preparation call before the wallet answers. ERC6492 signature verification needs a state check as well as a verdict when the caller can commit writes.

    11 min read

  • ERC165 Interface Detection: What a Positive Result Proves

    EVM patterns

    ERC165 Interface Detection: What a Positive Result Proves

    A support response advertises a callable interface. Behavior and authorization need separate evidence. ERC165 interface detection should use a named detector policy, retain unresolved outcomes and inform only the integration decision that its evidence supports.

    11 min read

  • ERC1363 Callback Security: Receipt, Approval and Reentry

    EVM patterns

    ERC1363 Callback Security: Receipt, Approval and Reentry

    A token callback does not by itself prove that an application received an authorized payment. ERC1363 callback security requires authenticating the token, separating approval from receipt and checking the exact callback delivery path.

    12 min read

  • ERC2771 Forwarder Security: Trusted Context and Request Evidence

    EVM patterns

    ERC2771 Forwarder Security: Trusted Context and Request Evidence

    A recipient reads an appended sender only through a trusted forwarder with sufficient calldata. ERC2771 forwarder security requires authentic request verification, correct context consumption and application authorization on every relevant route.

    12 min read

  • Solidity Transient Storage Security: Lifetime, Ownership and Cleanup

    EVM patterns

    Solidity Transient Storage Security: Lifetime, Ownership and Cleanup

    Temporary state resets at transaction end and can still be shared by calls within that transaction. Transient storage security requires explicit owner mapping, successful-call cleanup and rollback tests for the actual execution graph.

    12 min read

  • ERC3156 Flash Loan Security: Callback Authority and Repayment

    EVM patterns

    ERC3156 Flash Loan Security: Callback Authority and Repayment

    Repayment protects the lender's financing boundary, while the receiver must authorize the work performed during the loan. ERC3156 flash loan security requires lender and initiator checks plus the application's own request and allowance policy.

    12 min read

  • Governance Timelock Security: Readiness, Roles and Execution

    EVM patterns

    Governance Timelock Security: Readiness, Roles and Execution

    An elapsed delay makes an operation eligible for further checks, while authority and dependencies still govern execution. Governance timelock security requires closing target bypasses and testing roles, predecessors and recovery paths.

    11 min read

  • ERC4337 Paymaster Security: Sponsorship, Prefund and Settlement

    EVM patterns

    ERC4337 Paymaster Security: Sponsorship, Prefund and Settlement

    A paymaster sponsors gas under its own acceptance policy and can still pay when the user action fails. ERC4337 paymaster security requires operation binding, complete prefund accounting and tested settlement behavior for the deployed EntryPoint version.

    12 min read

  • L2 Sequencer Security: Recovery Gates and Oracle Boundary Tests

    Chains

    L2 Sequencer Security: Recovery Gates and Oracle Boundary Tests

    A sequencer returning to service does not establish that every oracle-dependent operation is ready. L2 sequencer security requires separate checks for reported uptime, elapsed recovery time and the price observation used by the application.

    11 min read