feat(web): re-key a subordinate CA live through the manager#59
Merged
Conversation
A root has no parent to sign a rotation CSR; the manager refuses it. Show an explanation instead of the re-key action for root nodes.
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 and why
Wires the node re-key wizard to the manager's single orchestrated
FleetService.RekeyNodeRPC. In live mode one action re-keys a subordinate CA end to end: the newrekeyNode(nodeName, profileName)helper makes a singleRekeyNodecall (the manager runs the ferry server-side, the web does not orchestrate steps), then refetches the fleet and certificate sets unfiltered so the node's new identity and chain appear without a reload. The wizard shows a pending state, renders the re-keyed subject/issuer CN and chain length on success, and surfaces an RPC error inline (no native popup) without advancing.Mock mode keeps its existing stepped walkthrough and drives no RPC; calling the live helper in mock mode is a clear error rather than a silent fallback. Follows the merged S1/S2 live-write pattern (RevokeCertificate/IssueLeaf). Includes the regenerated
fleet_pb.tscarrying theRekeyNodeclient method.Closes #58
Part of #24
Verification
How this was verified
npm run lint(eslint + prettier) clean,npm test(151 tests pass),npm run buildsucceeds,task license(0/114 changed).src/lib/rekey.test.tscovers the live call/refetch, error propagation, and mock-mode refusal; the wizard test covers the mock demo (no RPC), live success rendering the new identity, and inline error without advancing.Merge order
Consumes the manager's
RekeyNodeRPC; the generatedfleet_pb.tsmatches CryptOS-PKI/api#56. Merge after api#56 and the manager PR.