Skip to content

Port gHashTag/trios:crates/trios-mesh-node/src/crypto.rs (Rust, 7 functions) to specs/port/trios/crates/trios-mesh-node/ - #8922

Open
gHashTag wants to merge 2 commits into
masterfrom
queen-8896
Open

gHashTag wants to merge 2 commits into
masterfrom
queen-8896

Conversation

@gHashTag

Copy link
Copy Markdown
Owner

Closes #8896

Written by a bee on queen-8896 and published by tools/queen/publish.py. The branch itself is the bee's; the second commit is the coordination entry every pull request must add, which a bee has no way to know about.

1 file changed, 797 insertions(+)

🤖 Generated with Claude Code

Trinity Bee and others added 2 commits October 11, 2026 04:19
Re-authors gHashTag/trios crates/trios-mesh-node/src/crypto.rs
(8b229e9489ee, 149 lines, 7 functions) as
specs/port/trios/crates/trios-mesh-node/src/crypto.t27.

The decisions the original made around its primitive cryptography are
now pure, tested .t27 code: the from_seed stretching layout (byte 0 =
seed, byte 1 = 0xA3), dest_hash = SHA256(pubkey)[..16], the commutative
KDF that sorts the two pubkeys and hashes dh || pk_lo || pk_hi (96
bytes), lowercase hex pubkeys, the base64 STANDARD alphabet and padding
with the base64(nonce || ciphertext) wire format, the 12-byte minimum
payload check, and random()'s raw-entropy secret (no stretching). 23
tests, all passing under t27c test-report, 0 BLOCKED.

The primitive calls -- SHA-256, X25519 key derivation and
Diffie-Hellman, OS randomness, ChaCha20-Poly1305 seal/open -- are
declared with undefined bodies that no test calls; their results are
parameters the generated host passes in around the pure logic. The
port report names each with its line in the original.

Closes #8896
A pull request must add exactly one docs/now entry and a bee has no way
to know that: its brief names a boundary file and acceptance criteria,
and docs/now/ is neither. The publisher adds it rather than failing the
gate.

Closes #8896

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-10-11 04:36:56 UTC

Summary

Status Count
Total Open PRs 50
PRs with Failing Checks 45
PRs with All Checks Green 5
READY 2
FAILING 45
PENDING 0
NO CHECKS YET 0

These columns do not partition: 2 + 45 + 0 + 0 = 47, and there are 50 open PRs. A PR is being counted twice or not at all.

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=465abf513dc2 != manifest seal=87e5cbd3ad94.
    The committed NMSE numbers were certified against an older compiler.rs.
    Run scripts/reseal-check.sh locally for the two-step reseal command (advisory; not a merge gate).

@t27-bees t27-bees Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewer bee verdict for head fa607e34fbb8b5b1d072102286ae463bf7b8c221 (tools/bees/reviewer.py, zai glm-4.5-flash, 4 turns, 79 s).

BEE-VERDICT: REQUEST_CHANGES
summary: Port meets all acceptance criteria but is blocked by undiscounted emit-bitexact check
criterion: "File exists and has 7 functions" -- met -- brief.md:697-698
criterion: "Code generates successfully and parses" -- met -- brief.md:699-701
criterion: "Has sufficient tests and compiles" -- met -- brief.md:702-703
blocking-check: "emit-bitexact" -- failure appears unrelated to this change, but cannot be discounted as master state at merge base is unknown

Evidence

Based on my analysis of the pull request and the provided files, here's my evaluation:

Evidence Summary

Acceptance Criteria Verification

All acceptance criteria from issue #8896 were met as verified by the runner:

  1. ✅ File existence: test -f specs/port/trios/crates/trios-mesh-node/src/crypto.t27 && echo present printed "present"
  2. ✅ All 7 functions present: The grep command counted exactly 7 functions with the required names
  3. ✅ Code generation successful: Generated code has 0 "not yet implemented" and 681 lines (>12)
  4. ✅ File parses correctly: t27c spec-status returned "IMPLEMENTED" (not "NOPARSE")
  5. ✅ Sufficient tests: Found 23 test blocks (exceeds minimum of 7)
  6. ✅ Code compiles and tests pass: t27c test-report shows 0 BLOCKED tests

Boundary Compliance

The changes strictly follow the boundary specified in issue #8896:

  • Only modified specs/port/trios/crates/trios-mesh-node/src/crypto.t27 (797 lines)
  • Created the file that didn't exist before
  • Did not modify any other files except the documentation file added by the publisher

Implementation Quality

The code demonstrates:

  • Proper porting of decision logic rather than plumbing
  • Clear documentation of what was ported vs. what remains undefined
  • Comprehensive test coverage including edge cases
  • Correct handling of crypto operations as pure functions with external dependencies declared as undefined

Red Check Analysis

4 red checks were found:

  1. Corpus ratchet (expected-failure ledger) - RED

    • Discounted: This check is red on master (f252e53), same failure
  2. duplicate-bodies - RED

    • Discounted: This check is red on master (f252e53), same failure
  3. emit-bitexact - RED

    • NOT discounted: The master state at merge base (39d5af3) is unknown - the newest completed run (green at d1ebc26) is not at or after merge base
  4. t27b-native-ratchet - RED

    • Discounted: This check is red on master (5a34f1e), same failure

The emit-bitexact failure indicates that specs/memory/graph/ingest.t27 newly fails to generate, but this appears to be an unrelated defect not caused by this change.

This was referenced Oct 11, 2026

This branch has not been deployed

No deployments
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.

Port gHashTag/trios:crates/trios-mesh-node/src/crypto.rs (Rust, 7 functions) to specs/port/trios/crates/trios-mesh-node/src/crypto.t27

2 participants