security(certification): stop the witness comparer coercing types (#462, #459) - #473
Merged
Merged
Conversation
Lab finding #462 (white-box), adversarially reviewed clean. The correctness gate proves EXACT witnessed behavior, but its value comparer coerced across kinds: Convert.ToInt64 rounded a double into an int (2.4 == 2, 1.5 == 2 by banker's rounding) and the string fallback equated an int with its decimal string or a bool. A brick whose real output was wrong-by-<0.5 or wrong-typed passed the proof the gate exists to make. Both comparers (WitnessValueComparer and the duplicated WitnessRunner.ValuesEqual) now match type-first: if either side is integral (resp. boolean), BOTH must be, else unequal; strings and floats keep the invariant-string compare. Same-type values still match (int 42 == long 42, "hi" == "hi", 3.14 == 3.14). New unit tests pin every closed hole and every preserved case. Also from #459: - Mutant ids are disambiguated (#2/#3 on a repeated {kind}-{line}) so the SIGNED survivor/killed ledger is unambiguous — two mutations on one line no longer share an id. - Certification record Status XML docs corrected from "ADMIT/REJECT" to the PASS/FAIL the gate actually writes (3 model files), so a consumer matching the documented labels stops misclassifying every record. Gates: cert-gate 402/402 (the comparer change broke no existing witness); certification suites 35/35. Adversarial review (Opus): clean. [coordinated-integration] Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Uh oh!
There was an error while loading. Please reload this page.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
#462 (white-box lab, reviewed clean): the correctness gate's value comparer coerced across kinds — a double rounded into an int (2.4==2), and an int equated with its decimal string or a bool — so a wrong-by-<0.5 or wrong-typed brick output passed the exact-behavior proof. Both comparers now match type-first (integral↔integral, bool↔bool, else unequal); same-type values still match. Tests pin every hole and every preserved case.
#459: mutant ids disambiguated (#2/#3) so the signed ledger is unambiguous; Status XML docs corrected to the PASS/FAIL the gate writes.
Gates: cert-gate 402/402 (no witness regressed); certification suites 35/35. Opus review: clean.
[coordinated-integration]
🤖 Generated with Claude Code