Property Specification Language Template Generator
Free to download on every platform. Comes pre-installed on BotFone, BotPad and BotFlip — with extra free apps included.
About this app
WHAT IT DOES
Property Specification Language Template Generator is a security-focused tool that creates property specification language (PSL) templates from Solidity contract source code. It parses the contract to extract state variables, function signatures, and control flow patterns, then generates a structured specification template suitable for formal verification tools. The template includes property definitions for detected features (transfer, mint, burn, approve, ownership), invariant definitions in PSL format, verification targets, and a usage guide. Users can provide custom properties to include in the template. The output follows a standardized format that can be adapted to various verification tools, including Certora, SMTChecker, and other formal verification pipelines. This enables developers to quickly create property specifications without manually writing the boilerplate for each contract.
HOW TO USE
Paste your Solidity source code into the input area. Enter a contract name (optional). Add any custom properties you want to include (one per line). Click "Generate template" to process the code. The tool will display a summary including the number of state variables, functions, and custom properties, along with detected features (Transfer, Mint, Burn, Approve, Ownership). The complete specification template is displayed in a scrollable output area. Use the copy button or download button to save the template for use with your formal verification tool.
TECHNICAL NOTE: FEATURE DETECTION AND TEMPLATE GENERATION
The tool performs static analysis on the Solidity source code using regex-based parsing to extract contract structure. It identifies state variable declarations, function signatures, and detects common ERC patterns based on function names. The template generation includes: contract overview with state variables and functions, property definitions for detected features (transfer, mint, burn, approve, ownership), invariant definitions in PSL format (e.g., balance sums, total supply constraints), verification targets (overflow safety, reentrancy, access control, state consistency), and user-provided custom properties. The output is formatted as a human-readable specification template with clear sections and comments, ready for adaptation to specific verification tools.
WHAT IT CANNOT SEE
The tool cannot guarantee that generated templates are complete or correct for the specific contract logic. It cannot automatically verify contract security; the templates require manual review and adaptation. It cannot detect all edge cases or vulnerabilities in the contract. The tool is limited to the accuracy of source code analysis; complex patterns may be misidentified. It cannot generate executable property tests, only specification templates. It cannot handle complex contract interactions with external contracts or cross-contract properties. It cannot verify contracts with non-standard patterns that deviate from common ERC patterns. The tool is limited by the expressiveness of the specification language; some properties may not be expressible in the generated format.
PLEASE NOTE
This tool is designed exclusively for Solidity source code used on EVM-compatible chains. It does not support other smart contract languages. The generated templates are starting points and should be reviewed and validated by security experts before use. The tool does not execute formal verification; it only generates template files. Always verify that the generated template matches the intended contract behavior and adapt it to your specific verification tool's syntax. The tool provides no warranty that the generated template will result in successful verification; users are responsible for validating all properties and assumptions.