AI SECURITY GUIDE

Review the intent.
Then review the implementation.

Review AI-generated code by stating the required behavior, inspecting generated checks, investigating failures and rerunning checks after fixes. Formal verification applies to specified properties of supported code.

ILLUSTRATIVE REVIEW EXAMPLE

Check a generated fee calculation.

A bounded example for supported smart contract code
StepWhat to inspect
State the requirementA withdrawal fee must not exceed 1% of the withdrawn amount, rounded down to the smallest unit.
Inspect the checksCheck whether generated tests and properties cover small amounts, rounding, fee-setting changes and alternate withdrawal paths.
Interpret the resultInvestigate a failing trace. For a passing property, inspect the model and assumptions; it does not prove unrelated behavior.
Recheck the changeRerun relevant checks after a fix and update requirements when intended behavior changes.
WHAT TO CHECK

Connect the code to its consequences.

INTENT

Make the requirements explicit

Describe permitted behavior, trust assumptions, and failure conditions.

EVIDENCE

Inspect generated checks

Review candidate findings, tests, and formal properties before relying on them.

ITERATION

Recheck the changed code

Update the requirements and rerun the relevant checks as the implementation evolves.

TWO DISTINCT QUESTIONS

Code correctness and agent authority.

Choose the right approach
QuestionRelevant approach
Does the code preserve the intended behavior?AutoProver and Certora Prover for supported code and properties.
Are agent permissions and execution paths appropriately controlled?Discuss agent permissions and execution controls with your security team.
WORK WITH CERTORA

Plan checks for generated code.

Bring your repository, intended behavior and current review workflow.

Get Started