2.7 KiB
2.7 KiB
Binary Diff with Deterministic Signatures
Module
Attestor
Status
IMPLEMENTED
Description
Binary diff analysis with DSSE-signed evidence output is implemented. The system compares binaries, produces deterministic diff signatures, serializes predicates, and integrates with VEX evidence linking. While the advisory specifically mentions B2R2 IR lifting, the implemented approach uses binary section-level diffing with DSSE attestation.
Implementation Details
- BinaryDiff Predicate System:
src/Attestor/__Libraries/StellaOps.Attestor.StandardPredicates/BinaryDiff/-- full predicate lifecycle:BinaryDiffPredicateBuilder.cs(with.Build) -- constructs predicates from diff findingsBinaryDiffPredicateSerializer.cs(with.Normalize) -- deterministic serialization via normalizationBinaryDiffDsseSigner.cs-- DSSE envelope signing for deterministic signaturesBinaryDiffDsseVerifier.cs(with.Helpers) -- signature verificationBinaryDiffSectionModels.cs-- section-level diff models for ELF/PE binaries
- Evidence Integration:
src/Attestor/__Libraries/StellaOps.Attestor.ProofChain/Generators/BinaryFingerprintEvidenceGenerator.cs(with.Helperspartial) -- generates fingerprint evidence from binary analysis. - Binary Identity:
__Libraries/StellaOps.Attestor.ProofChain/Predicates/BinaryIdentityInfo.cs-- binary identity model.BinaryVulnMatchInfo.cs-- vulnerability match details. - Binary Fingerprint Predicate:
BinaryFingerprintEvidencePredicate.cs-- predicate for fingerprint evidence. - VEX Integration:
VexProofIntegrator.cslinks binary diff evidence to VEX decisions. - Tests:
__Tests/StellaOps.Attestor.StandardPredicates.Tests/BinaryDiff/-- builder, serializer, signer, schema validation tests
E2E Test Plan
- Perform a binary diff between two versions of a binary and produce a
BinaryDiffPredicateBuilderoutput with section-level changes - Serialize the diff predicate via
BinaryDiffPredicateSerializer.Normalizeand verify byte-for-byte determinism across two invocations - Sign the normalized predicate via
BinaryDiffDsseSignerand verify the DSSE envelope signature is valid - Verify the signed diff evidence via
BinaryDiffDsseVerifierand confirm integrity - Generate binary fingerprint evidence via
BinaryFingerprintEvidenceGeneratorfrom a binary with known vulnerability matches and verifyBinaryVulnMatchInfois populated - Link binary diff evidence to a VEX decision via
VexProofIntegratorand verify the proof chain includes the diff artifact - Create diff findings for both ELF and PE section types and verify
BinaryDiffSectionModelshandles both formats