Тестировать!
● долго и трудозатратно
Верифицировать (?)
Fisher, K., Launchbury, J., & Richards, R. (2017). The HACMS program: using formal methods to eliminate exploitable bugs.
Philosophical Transactions of the Royal Society A: Mathematical, Physical and Engineering Sciences.
Методы формальной верификации
https://en.wikipedia.org/wiki/Abstract_interpretation#/media/File:Combination_of_abstract_domains.svg
Static Analysis
● Выразительная сила ⬊
● Трудоемкость ⬊
● Масштабируемость ⬈
Type Systems
Kotlin: null-safety
Type Systems
https://theburningmonk.com/2015/05/rust-memory-safety-without-gc/
Type Systems
● Выразительная сила ⬊
● Трудоемкость ⬂
● Масштабируемость ⬈
Model Checking
CBMC
Model Checking: TLA+ Example
https://learntla.com/introduction/example/
Model Checking
● Выразительная сила ⬂
● Трудоемкость ⬊
● Масштабируемость ⬊
Deductive Verification
Program ✓
Translator
Proof
Obligations Correct?
Why3
Spec
∃∀
✘
Coq
Deductive Verification
Why3
Deductive Verification
http://viper.ethz.ch/tutorial/?page=1§ion=#introduction
Deductive Verification
● Выразительная сила ⬀
● Трудоемкость ⬀
● Масштабируемость ⬀
Certified Programming
○ Спецификация — тип
Coq
Certified Programming
Certified Programming: Examples
● Выразительная сила ⬈
● Трудоемкость ⬈
● Масштабируемость ⬊