This website seems to be responding to a strawman pitch for formal verification: that it eliminates all bugs. This would be a preposterous thing to say, and I've never heard it.
Of course it's only as good as the specification you give it (and it's hard to write a good one!). And of course proof assistant kernels occasionally have bugs (so does the borrow checker, and yet it is enormously safer than writing C).
By the author's own admission, they were unable to find any issues in the specified parts of CompCert. Is the claim that massively reducing your attack surface isn't worthwhile?
teiferer 9 hours ago [-]
> a strawman pitch for formal verification: that it eliminates all bugs. This would be a preposterous thing to say, and I've never heard it.
My undergrad course on formal methods pitched literally that. "Testing can only prove that there are bugs. Verification can prove there are no bugs." It is easy to mistake the "there are no bugs" to mean "eliminates all bugs" since they are equivalent statements. Of course, if you know a little more, it's clear that this only applies with a bunch of caveats. But if you knew that then you would not be taking the course in the fjrst place. This has left generations of students insufficiently informed.
dionnam 10 hours ago [-]
hashicorp was never verified tho. only the protocol has a TLA+ spec. antithesis even says the spec "doesn't speak to details like installSnapshot, or replica replacement", and the bug was go handling heartbeats concurrently when the model assumes every op is atomic https://antithesis.com/blog/2026/finding-bugs-in-raft-implem...
gr_norm 10 hours ago [-]
Yes, the author seems to want to use 'formally verified' to mean 'has zero bugs', which the formal verification community has been very careful to avoid. See the sel4 FAQ [1]. It's important to know exactly what properties you've shown and what you haven't.
How people talk about the formal verification on Twitter, which is what this website largely appears to be about, is irrelevant. It's not a place where people go to speak truths.
> Yes, the author seems to want to use 'formally verified' to mean 'has zero bugs', which the formal verification community has been very careful to avoid.
Thus Knuth's famous "Beware of bugs in the above code; I have only proved it correct, not tried it,"
utopiah 11 hours ago [-]
Not my domain but I'm speculating that a lot of "solutions" to complex problems at the moment exist because nobody cared enough to verify. I'm speculating even further than now that they are finally being verified it's mostly due to the landscape of problems, namely are genuinely complex and thus were ignored as too hard for a too low pay off, but when you have a LOT of resources that is perishable and constantly looking for more trust, this set of problems suddenly appear very interesting.
monitorronco 9 hours ago [-]
I dont have background so my question may sound stupid to many, but arent unit tests enough (for professional/enterprise)? Why bother with formal verification?
gr_norm 9 hours ago [-]
It's a quite reasonable question! Whereas unit tests are stated for just one or a few inputs at a time, formal verification validates properties of programs for all possible inputs. So, for instance, you can show that a web application can never be crashed with a crafted input. Or that there is no sequence of actions one user can take to modify or view certain fields on another's account.
Only formal verification can feasibly talk about certain classes of properties. Many important concerns in security (like confidentiality and integrity) and distributed systems (certain consistency properties) fall into this camp.
teiferer 9 hours ago [-]
Well crafted unit tests cover all "interesting" inputs and behaviors and what they don't cover is expected to be fine too by informal interpolation arguments.
Granted, most testing out there isn't really that well constructed. And trying to make your arguments formal often leads to discovering the relevant corner cases, even without running a checker, e.g. trying to think through some loop invariants. For that purpose, formal methods have a place in education even if they are not used on every little piece of software out there. In the end it's about deeply caring about quality and correctness of your software. Whether you actually employ formal verification or not is not really substantial in the end, at least considering the current state of software quality.
charles_f 11 hours ago [-]
> errors in the proofs themselves
That's the problem in a nutshell. Formal verification stems more or less from a formal language for requirements, and if I learned something across 20y of being paid for code is that no-one knows how to write requirements, can predict these requirements in an exhaustive way (myself included).
cmrdporcupine 10 hours ago [-]
Software has two forms of complexity (which can then yield bugs); intrinsic complexity arising from the complexity of the business domain... and "accidental" complexity arising from the faults or complexity of the tools and implementation.
Formal verification can help flush out some of the mess from the latter.
Unfortunately the the former -- the complexity of the actual business case / problem / real world domain -- has always been much harder than people ever seem to think. Also the reason why "rewrite from scratch" is often a total failure.
Thinking clearly is hard. I'm gonna go watch TV.
mejutoco 10 hours ago [-]
It can help you detect inconsistencies (for example, contradictions) in the former part as well.
erelong 11 hours ago [-]
formal verification sounds like a nice idea, but in practice there's a lot of problems with it (I assume this site intends to highlight that reality?)
9rx 10 hours ago [-]
It seems most everyone these days have converged on using statically-type (which is formal verification) languages without much fuss, so it is not clear what practical problems you are thinking of?
Formal verification's only real problem isn't formal verification, but that it sounds like "miracle" to those without a trained ear.
erelong 9 hours ago [-]
it's pretty easy to ask ai what the problems are but I think the main one was that specs can be unclear, hence in the site's tagline it says "and the conversations about what 'verified' actually means"; i.e. you can "verify" something that goes by an incorrect spec?
9rx 9 hours ago [-]
> that specs can be unclear
That sounds like an implementation problem, not a problem with formal verification. I don't want to start apologizing for any problems formal verification does have, but this truly doesn't seem like one. Formal verification does not define what a spec looks like.
> you can "verify" something that goes by an incorrect spec?
I'm not sure how that is a problem, unless maybe you're hearing "miracle"? There is no expectation on formal proofs to prove alignment with human expectations. That is not its function. Would you say the problem with hammers is that they don't blow-dry your hair?
TZubiri 11 hours ago [-]
Built lean yesterday. Repo is 7GB, contains compiled compilers for bootstrapping, build itself took multiple hours, left overnight. It’s literally C++ which compiled to C! I’m having a hard time believing that we are as certain that this thing has no bugs as we are of the bhaskara binomial root, let alone whether there actually is a bug or not
gaogao 11 hours ago [-]
Typical practice is to double check with the C++ / Lean / or Rust kernels now these days to guard against an implementation specific bug. And yet, yeah there's still some chance of a bug, but there's also a chance of any computation model running in the physical world having issues.
TZubiri 4 hours ago [-]
there’s also spec bugs, as opposed to implementation bugs, those will show up in multiple implementations and never be caught by formal type or correctness checkers
Rendered at 01:36:25 GMT+0000 (Coordinated Universal Time) with Vercel.
Of course it's only as good as the specification you give it (and it's hard to write a good one!). And of course proof assistant kernels occasionally have bugs (so does the borrow checker, and yet it is enormously safer than writing C).
By the author's own admission, they were unable to find any issues in the specified parts of CompCert. Is the claim that massively reducing your attack surface isn't worthwhile?
My undergrad course on formal methods pitched literally that. "Testing can only prove that there are bugs. Verification can prove there are no bugs." It is easy to mistake the "there are no bugs" to mean "eliminates all bugs" since they are equivalent statements. Of course, if you know a little more, it's clear that this only applies with a bunch of caveats. But if you knew that then you would not be taking the course in the fjrst place. This has left generations of students insufficiently informed.
How people talk about the formal verification on Twitter, which is what this website largely appears to be about, is irrelevant. It's not a place where people go to speak truths.
[1] https://sel4.systems/About/FAQ.html
Thus Knuth's famous "Beware of bugs in the above code; I have only proved it correct, not tried it,"
Only formal verification can feasibly talk about certain classes of properties. Many important concerns in security (like confidentiality and integrity) and distributed systems (certain consistency properties) fall into this camp.
Granted, most testing out there isn't really that well constructed. And trying to make your arguments formal often leads to discovering the relevant corner cases, even without running a checker, e.g. trying to think through some loop invariants. For that purpose, formal methods have a place in education even if they are not used on every little piece of software out there. In the end it's about deeply caring about quality and correctness of your software. Whether you actually employ formal verification or not is not really substantial in the end, at least considering the current state of software quality.
That's the problem in a nutshell. Formal verification stems more or less from a formal language for requirements, and if I learned something across 20y of being paid for code is that no-one knows how to write requirements, can predict these requirements in an exhaustive way (myself included).
Formal verification can help flush out some of the mess from the latter.
Unfortunately the the former -- the complexity of the actual business case / problem / real world domain -- has always been much harder than people ever seem to think. Also the reason why "rewrite from scratch" is often a total failure.
Thinking clearly is hard. I'm gonna go watch TV.
Formal verification's only real problem isn't formal verification, but that it sounds like "miracle" to those without a trained ear.
That sounds like an implementation problem, not a problem with formal verification. I don't want to start apologizing for any problems formal verification does have, but this truly doesn't seem like one. Formal verification does not define what a spec looks like.
> you can "verify" something that goes by an incorrect spec?
I'm not sure how that is a problem, unless maybe you're hearing "miracle"? There is no expectation on formal proofs to prove alignment with human expectations. That is not its function. Would you say the problem with hammers is that they don't blow-dry your hair?