The Data Protection key ring is encrypted at rest with a certificate, or with DPAPI on Windows #275
No reviewers
Labels
No labels
agent
api-regen
agent
architect
agent
coder
agent
console-coder
agent
docs-writer
agent
mechanic
agent
protocol-coder
agent
storage-coder
area/api
area/ci
area/console
area/dhcp
area/dns
area/docs
area/packaging
area/process
area/storage
area/windows
kind
bug
kind
chore
kind
docs
kind
epic
kind
feature
kind
performance
kind
security
kind
test
priority
high
priority
low
priority
medium
resolution
duplicate
resolution
not-a-bug
resolution
wontfix
status
blocked
status
in-progress
status
needs-decision
status
needs-design
status
ready
theme
ad-samba-dns
theme
alternatives-benchmark
theme
console-toolchain
theme
later
theme
parity-devices
theme
parity-query
theme
post-release-fixes
theme
tracker-setup
theme
valkey
theme
windows-installer
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
lantea-one/ninlil!275
Loading…
Reference in a new issue
No description provided.
Delete branch "feature/42-keyring-at-rest"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The Data Protection key ring, which unlocks every stored secret, is now encrypted at rest (owner decisions Q-REL-12, R2-KEYRING).
DataProtectionoptions:CertificatePath,CertificatePassword,PreviousCertificatePath,PreviousCertificatePassword(ENVIRONMENT.md: 342 → 346 variables).Verified on Linux: Web.Tests 2065, Backup.Tests 60, Identity.Tests 77; build 0 warnings; red/green (6 tests fail with protection disabled). The verifier's low findings are fixed (unreadable PFX now exits 78; an untested README claim about expired certificates removed).
Windows acceptance passed on Lofnheim on 2026-11-05 (results in the PR comment): DPAPI under
NT SERVICE\Ninlil, a certificate added after DPAPI, certificate-protected new keys, the exit-78 refusal from a console, and a cross-machine restore to Linux. Under the Windows service, a refusal is not reported to the event log or the SCM; that applies to every startup refusal and is tracked in #336.Closes #42
🤖 Generated with Claude Code
https://claude.ai/code/session_01T33E3pmQvqkTriyQUMNUTK
Windows acceptance on Lofnheim (Windows 10.0.26200), 2026-11-05, with the exe built from this branch after taking in develop (
9c1d2b7b,bd3fd307):NT SERVICE\Ninlil: new key fileDpapiXmlDecryptor), no plaintext<masterKey>dig -yfrom Linux)NT SERVICE\NinlilBwith a certificateEncryptedXmlDecryptor), not DPAPIDataProtection:CertificatePathandCertificatePassword, no password printedProgram.cs, so it is filed as #336DataProtection:CertificatePath, nothing restoredKeyRing*/DataProtectiontests natively on WindowsKeyRing_OnWindowsWithDpapi_..., which treated DPAPI's own<value>element as plaintextNinlil.Dns.Server.Backup.Testson Windows: 23 of 64 fail at cleanup (test.sqlite3in use). Develop already fails 20 of 61 the same way, so this belongs to the Windows test epic #8, not here.Linux after the merge: build 0 warnings, Web.Tests 2303/2303, Backup.Tests 64/64, Identity.Tests 77/77, csharpier clean.
WIP: The Data Protection key ring is encrypted at rest with a certificate, or with DPAPI on Windowsto The Data Protection key ring is encrypted at rest with a certificate, or with DPAPI on Windows