refactor(node): W1b-6 — seam key_mgmt, KeyManager trait/handle carve (#1285, LAST seam carve)#71
Merged
Merged
Conversation
Co-Authored-By: Claude <noreply@anthropic.com>
…(#1285, #1298, #1303) LAST W1b seam carve (before W1c). Carves the node's MACHINE identity_seed/ NodeCert lifecycle Node methods (peer_id_hex, identity_seed_for_peer, peer_cert_dir, node_cert_dir) into the KeyManager trait (seam 7's public surface), implemented by Node with the EXISTING method bodies moved unchanged from lib.rs. Structural carve only — the dig-keystore crate adoption (#1024) is a later wave, coordinated with the key-management family, out of scope here. #908 boundary preserved exactly: KeyManager holds ONLY the node's own machine identity_seed/NodeCert lifecycle — no user DID/wallet key path added or touched. The module doc states this invariant explicitly so it stays visible at the seam's public surface, not just in this commit message. The only caller (peer.rs's peer-network bring-up, which reads identity_seed_for_peer/peer_cert_dir/node_cert_dir to mint/load the node's mTLS NodeCert) now brings KeyManager into scope via `use crate::KeyManager` — the only change it needed. No external crate calls these methods directly. No signature or behaviour changed anywhere. Depends on W1b-5 (merged, #1285). Next: W1c (the composition-root split). Co-Authored-By: Claude <noreply@anthropic.com>
MichaelTaylor3d
marked this pull request as ready for review
July 20, 2026 23:21
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 free
to 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.
What
W1b-6 (7th and LAST of the W1b sub-PRs, #1285/#1303): carve the node's MACHINE
identity_seed/NodeCert lifecycle `impl Node` methods into a `KeyManager` trait
crate ADOPTION is a later wave, out of scope here.
#908 boundary preserved exactly: KeyManager holds ONLY the node's machine
identity_seed/NodeCert lifecycle — no user DID/wallet key path added.
Depends on W1b-5 (merged, origin/main @ 4624d5d).
Closes nothing yet (tracking #1285). After this merges, W1c (the composition-
root split) is next.