Continuous Verifier (CV) is a framework for verifying software systems against specified properties.
It automates the decomposition of a system, creates verification tasks, and runs verification tools.
- Overview
- Plugin Definition
- Installation
- Configuration for a Single Verification Launch
- Continuous Verification
- Results Visualization
- Simple Example
CV requires the following inputs:
- System under analysis (
system_id) – a C-language system consisting of:- a set of subsystems (
subsystem_1, …,subsystem_k)
- a set of subsystems (
- Properties to be verified (
prop_1, …,prop_n) - Configurations for the verification process
- Decomposes the system into subsystems.
- Creates verification tasks, each consisting of:
- Relevant source files for a subsystem
- A generated entry point (
mainfunction) - The property to check (via specification automata or configuration)
- Executes verification tasks using software verification tools (SV-COMP tools).
To verify a specific system (system_id), a plugin is required.
A plugin provides configuration and resources for CV to analyze the system.
plugin/
└── system_id/
├── entrypoints/ # Subsystem entrypoint descriptions
├── patches/
│ ├── sources/ # Source code patches (if needed)
│ └── preparation/ # Additional build configuration
├── configs/ # Launch configurations
├── properties/
│ ├── properties.json # Property descriptions
│ ├── models/ # Additional C models for properties
│ └── automata/ # Specification automata
└── docs/ # Optional documentation
- entrypoints/ – JSON files describing subsystems and entrypoints
- properties/:
properties.json– list of properties to checkautomata/– specification automata for propertiesmodels/– additional model files (C source)
- patches/:
sources/– patches applied to system sourcespreparation/conf.json– extra build optionstools/cpachecker– patches for verification tools
- configs/ – CV run configurations
- docs/ – documentation
By default, CV can check the memory safety property (smg).
Install a plugin:
make install-plugin PLUGIN_DIR=<plugin_dir> PLUGIN_ID=<system_id>Remove all installed plugins:
make delete-pluginsCV uses BenchExec to limit resources (CPU, memory, cores). Enable cgroups on Ubuntu 16.04–20.04 or Fedora 22:
./install_cgroups.shUbuntu 22 uses cgroups v2 by default, but BenchExec requires cgroups v1. To enable partial cgroups support (no memory accounting):
- Add to
/etc/default/grub:cgroup_enable=memory cgroup_memory=1 systemd.unified_cgroup_hierarchy=0 - Update GRUB:
sudo update-grub
- Reboot.
Check if swap accounting is enabled:
if ls /sys/fs/cgroup/memory/memory.memsw.limit_in_bytes || ls /sys/fs/cgroup/memory.memsw.limit_in_bytes; then
echo "Swap accounting is installed";
else
echo "Swap accounting is not installed";
fiEnable swap accounting:
- Add
swapaccount=1toGRUB_CMDLINE_LINUX_DEFAULTin/etc/default/grub - Run:
sudo update-grub sudo reboot
Alternatively, disable swap:
sudo swapoff -aExample configuration: configs/example.json.
Key parameters:
- Launcher: resource limits
CPU time– in secondsMemory size– in GBNumber of cores– CPU cores per verifier
- entrypoints desc – list of subsystems
- properties – list of properties
- system – system identifier
Parallel jobs calculation:
N = min(available_RAM / RAM_limit, available_cores / core_limit)
Each source directory requires:
{
"id": "name",
"source dir": "absolute path",
"branch": "optional branch",
"build patch": "optional patch",
"patches": [
"list of patches"
],
"repository": "git | svn | null",
"build config": {
"make command": "make"
}
}scripts/launcher.py --config <config files>Results: results/results_<config_name>_<timestamp>.zip
Large systems may take days to verify. Continuous verification optimizes by verifying only changed parts.
Steps:
- Build call graph
- Identify changed functions between commits
- Determine affected subsystems
- Verify only relevant subsystems
Create a common config (template: configs/auto.json) referencing previous configs:
./scripts/auto_check.py -c <common config>Requires CVV web interface.
Add to config:
"uploader": {
"upload results": true,
"identifier": "<parent report ID>",
"parent id": "true",
"server": "<host>:<port>",
"user": "<username>",
"password": "<password>",
"name": "<report name>"
}CV will automatically upload results during continuous verification.
Example files:
- Sources:
docs/examples/sources/(build withmake) - Subsystem description:
entrypoints/it.json - Properties:
properties/properties.json(includessmg) - Config:
configs/it.json
Run:
./scripts/launch.py -c configs/it.json