Skip to content

Harden tamper detection for Frackture payloads with deterministic integrity token - #24

Draft
cto-new[bot] wants to merge 1 commit into
mainfrom
feat-frackture-integrity-token-tamper-detection
Draft

Harden tamper detection for Frackture payloads with deterministic integrity token#24
cto-new[bot] wants to merge 1 commit into
mainfrom
feat-frackture-integrity-token-tamper-detection

Conversation

@cto-new

@cto-new cto-new Bot commented Dec 15, 2025

Copy link
Copy Markdown
Contributor

Summary

This PR implements a deterministic integrity token for Frackture payloads and tightens tamper detection across serialization, encryption, and reconstruction. The token ensures any modification to the payload or envelope is detected during verification.

Details

  • Add deterministic integrity token derived from symbolic (32 bytes) and entropy (16 uint16) and propagate it in compact header and legacy dict payloads
  • Extend validation and unpacking to populate/verify the token; frontier checks reject tampered payloads
  • Include token in canonical JSON used for HMAC signing of encrypted envelopes
  • Update frackture_v3_3_safe, frackture_v3_3_reconstruct, and related serializers to enforce token checks
  • Refresh unit tests and benchmark fault-injection tests to cover mutated symbolic/entropy/token scenarios and empty payloads
  • Maintain round-trips for decrypted payloads

BREAKING CHANGE: Consumers must adopt the new token-bearing payloads; legacy payloads without an integrity_token will need migration or explicit conversion.

… token

Harden tamper detection by introducing a deterministic integrity token computed over the 32-byte symbolic block and 16 entropy values, and propagate it through both binary and legacy dict payloads. Extend validation, serialization, and reconstruction to populate/verify the token, and enforce token checks in the verifier path. Include the token in the canonical JSON used for envelope signing (HMAC) so tampering with either raw payload or envelope is detectable. Update tests and benchmark helpers to exercise mutation paths and ensure round-trips remain valid.

This change may require migrating payload handling to the new token-based format; consumers should adapt to payloads carrying an integrity_token and updated reconstruction behavior.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants