You are browsing as a guest. Sign up (or log in) to start making projects!

2h 0m logged

Add comprehensive crypto integration test suite with 26 tests

Introduce crypto_integration.rs exercising the full security subsystem
across four categories. PSK tests (8) verify 256-bit key generation
across ten iterations, hex round-trip preservation including case
insensitivity, rejection of odd-length and wrong-length hex strings,
deterministic client proof computation, the complete mutual
authentication flow with distinct client and server proofs, and PSK
binding where different keys produce different proofs.

Age encryption tests (6) cover small, empty, and 1 MB large payload
round-trips, ephemeral key non-determinism (same plaintext produces
different ciphertext but both decrypt correctly), wrong identity
rejection, and corrupted ciphertext detection via single-byte
flipping mid-payload.

HKDF tests (4) verify 256-bit output length, deterministic derivation
for same PSK and UUID, cross-project key uniqueness for different UUIDs,
and a known-UUID stability test confirming the derived key is neither
all-zeros nor all-PSK-bytes.

Integrity tests (3) confirm streaming hasher equivalence with oneshot
hashing across 5 MB of 64 KB chunks, empty file hashing matching the
well-known empty SHA-256 digest, and proper I/O error propagation for
nonexistent files.

Archive round-trip tests (3) create a multi-file project with README,
two Rust sources, a design doc, and Cargo.toml, run through
create_archive → extract_archive, verify all file contents match
exactly and .project.toml is excluded. Hash verification rejection
confirms wrong hashes prevent extraction. A progress callback test
records all stage transitions during archive creation and verifies the
final progress fraction reaches 1.0.

0
1

Comments 0

No comments yet. Be the first!