rdmpw3275m-changelog-20260905-0610-xentropy-rotation-adapters-sequencer-and-exposure-scanner
rdmpw3275m-changelog-20260905-0610-xentropy-rotation-adapters-sequencer-and-exposure-scanner
Resolved XEntropy tickets FEAT-20260901-18, FEAT-20260901-19, FEAT-20260901-20, FEAT-20260901-21, and FEAT-20260901-22 with Swift 6 strict concurrency, zero compiler warnings, values-free design, atomic rollback safety, and comprehensive unit tests.
Scope
- Canonical root:
rdmsm4x:~/dev/apps/Xentropy - Local host:
rdmpw3275m - Projects touched:
Xentropy(Core, CLI, Gateway, Tests), ticketing system (ticket resolve)
Exact Files Touched
app/Sources/XEntropyCore/ProviderAdapter.swift:- Added
HTTPTransportprotocol andURLSessionHTTPTransportimplementation. - Added
discardReplacement(plan:)andverifyOldRejected(plan:)toProviderAdapter.
- Added
app/Sources/XEntropyCore/ProviderAdapters/CloudflareProviderAdapter.swift:- Created Cloudflare provider adapter conforming to
ProviderAdapter. - Implemented scoped API token creation
(
POST /user/tokens), read-only canary verification (GET /user/tokens/verify), candidate discard (DELETE /user/tokens/:id), and owner-gated revocation. - Documented vendor nuance regarding legacy Global API Key un-scopability vs. modern Scoped API Tokens.
- Created Cloudflare provider adapter conforming to
app/Sources/XEntropyCore/ProviderAdapters/GoDaddyProviderAdapter.swift:- Created GoDaddy provider adapter conforming to
ProviderAdapter. - Documented vendor nuance: GoDaddy developer portal requires
interactive owner MFA generation; surfaces
.manualConsoleGenerationRequiredwhen unstaged; read-only minimal canary viaGET /v1/domainswithsso-keyauth; mandatory owner confirmation before revocation.
- Created GoDaddy provider adapter conforming to
app/Sources/XEntropyCore/CredentialEnvironmentWriter.swift:- Created atomic single-key environment file writer with POSIX
rename(2). - Enforces regular file, owner UID match, and mode 0600 verification
(
mode & 0o077 == 0). Refuses symlinks. - Creates pre-write timestamped backup copy with mode 0600 in same directory.
- Preserves comments, ordering, blank lines, and original quote/export formatting.
- Provides dry-run preview mode with redacted diffs and local fleet scoping notice.
- Created atomic single-key environment file writer with POSIX
app/Sources/XEntropyCore/RotationPlanning.swift:- Added
.canaryValidationFailedand.revocationVerificationFailedcases toRotationPlanBlockerKind.
- Added
app/Sources/XEntropyCore/RotationExecutionSequencer.swift:- Created rotation execution sequencer enforcing strict step ordering:
prepareReplacement->storeSecurely->canaryExactScopebeforeupdateMappedConsumersorrevokeOld. - On canary failure: automatically discards candidate at provider,
leaves old credential untouched, and surfaces
.canaryValidationFailedblocker. - On canary success: establishes bounded rollback retention window before revocation.
- Enforces owner confirmation before
revokeOldfor elevated risk tiers. - Verifies old rejected post-revocation, surfacing high-severity
.revocationVerificationFailedblocker if prior key remains active.
- Created rotation execution sequencer enforcing strict step ordering:
app/Sources/XEntropyCore/CredentialLifecycleCoordinator.swift:- Extended
executeMutationto integrate withRotationExecutionSequencerand addedexecuteSequencedRotation.
- Extended
app/Sources/XEntropyCore/GitExposureScanner.swift:- Created values-free git-history exposure enumeration scanner.
- Operates strictly on pre-computed SHA-256 digests; never receives or logs plaintext secrets.
- Enumerates ALL remotes
(
git config --get-regexp ^remote\..*\.url) and ALL refs (git for-each-ref). - Classifies branches into
.trackedLive,.historicalOnly, and.unexposed.
- Unit Tests Added:
app/Tests/XEntropyCoreTests/CloudflareProviderAdapterTests.swift(8 tests)app/Tests/XEntropyCoreTests/GoDaddyProviderAdapterTests.swift(9 tests)app/Tests/XEntropyCoreTests/CredentialEnvironmentWriterTests.swift(10 tests)app/Tests/XEntropyCoreTests/RotationExecutionSequencerTests.swift(6 tests)app/Tests/XEntropyCoreTests/GitExposureScannerTests.swift(5 tests)
Verification Evidence
- Unit Test Pass Rates on
rdmsm4x:CloudflareProviderAdapterTests: 8/8 passed (100%)GoDaddyProviderAdapterTests: 9/9 passed (100%)CredentialEnvironmentWriterTests: 10/10 passed (100%)RotationExecutionSequencerTests: 6/6 passed (100%)GitExposureScannerTests: 5/5 passed (100%)- Full suite across all targets (
XEntropyCoreTests,XEntropyTests,XEntropyGatewayTests,XEntropyCLITests): 100% green pass with 0 failures and 0 compiler warnings.
- Git Commits on
rdmsm4x:~/dev/apps/Xentropy:ebd80e6:feat(rotation): implement Cloudflare provider adapter with scoped API token lifecycle (FEAT-20260901-18)a24769a:feat(rotation): implement GoDaddy provider adapter with registrar canary and owner gating (FEAT-20260901-19)a1d9895:feat(rotation): implement atomic environment writer with backup and preview (FEAT-20260901-20)966e83d:feat(rotation): implement rotation execution sequencer with canary-before-commit and rollback (FEAT-20260901-21)d5366d3:feat(exposure): implement git-history exposure enumeration scanner (FEAT-20260901-22)
- Formally Resolved Tickets:
FEAT-20260901-18: Resolved viaticket resolvewith evidenceFEAT-20260901-19: Resolved viaticket resolvewith evidenceFEAT-20260901-20: Resolved viaticket resolvewith evidenceFEAT-20260901-21: Resolved viaticket resolvewith evidenceFEAT-20260901-22: Resolved viaticket resolvewith evidence
Backup Locations & Undo
- Git history on
mainatrdmsm4x:~/dev/apps/Xentropycleanly captures all 5 commits (ebd80e6,a24769a,a1d9895,966e83d,d5366d3). - Any commit can be reverted cleanly via
git revert <hash>. - Ticket resolutions archived in
/Users/richh/dev/issues/resolved/.
Outstanding Owner Actions
- Apple Notes persistence is pending GUI desktop session invocation on
rdmpw3275m:zsh ~/scripts/notes_changelog.zsh ~/dev/LLM/Claude/changelogs/rdmpw3275m-changelog-20260905-0610-xentropy-rotation-adapters-sequencer-and-exposure-scanner.md(Refused in headless session becauselaunchctl managernameisBackground). - When ready, owner can run live supervised rotation for SEC-20260831-01 (Cloudflare) and SEC-20260831-02 (GoDaddy) using the newly built adapters.