Skip to main content

What Is the Main Challenge in Formally Verifying a Contract with External Calls?

The main challenge is handling the uncertainty and potential reentrancy introduced by external calls to other, unverified contracts. The formal model must account for every possible behavior of the external contract, which is often impossible to know.

This means the verifier cannot guarantee the safety of the entire system, only the local contract under the assumption that the external calls behave as expected. To mitigate this, auditors often use "stubs" or "axioms" to model the external contract's behavior, but this introduces assumptions.

What Is the Role of a Trusted Third Party in Verifying Derivative Contract Hashes?
What Is the Primary Difference between a ‘Known’ Event and an ‘Unknown’ Event in Terms of IV Impact?
What Is the Relationship between an ‘Invariant’ and a ‘Safety Property’?
What Are the Differences between a “Liveness” Attack and a “Safety” Attack in the Context of PoS?