Let the reference host read its key ring with a previous certificate

Offen
#3,435 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Maintainer antworten meist innerhalb von 1 Tag

Dieses Issue hat noch niemand übernommen.

Bewertung

Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Anfängerfreundlichkeit
52/100
Issue-Typ
Feature
Klarheit
Klar beschrieben
Aktivitätsstatus
Aktiv
Tech-Stack
csharp
Bereich
backend, security

Rechercherichtung

Start in src/FluentCMS.Host/ReferenceHost.cs and trace how the reference host configures Data Protection with ProtectKeysWithCertificate. Find the matching tests for certificate-protected key ring reads and add coverage showing that keys protected by either certificate can be read while new keys use the new certificate. Update docs/docker.md and docs/host-configuration.md with the replacement steps, including fluentcms settings reprotect; done when the acceptance checks pass.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Beschreibung

area:host security type:feature

Problem

The reference host and its image protect the Data Protection key ring with one certificate (ProtectKeysWithCertificate in src/FluentCMS.Host/ReferenceHost.cs). Nothing loads a previous certificate for reading (UnprotectKeysWithAnyCertificate). When the certificate is replaced, every ring key the old one protected becomes unreadable at once, and with it every secret setting, token and cookie those keys protect. fluentcms settings reprotect (#3364) cannot help: with the old certificate no key is protected by the new one, and with the new certificate the old keys cannot be read, so it ends with FCMS3308.

A host of one's own can configure both certificates; the image cannot.

Proposal

Let the reference host take one or more previous certificates that are used only to read the ring, and document the replacement as: add the new certificate with the old one as previous, wait for or make a new default key, run fluentcms settings reprotect, then drop the old certificate.

Acceptance

  • A host configured with a new certificate and the previous one reads ring keys protected by either and protects new keys with the new one
  • docs/docker.md and docs/host-configuration.md give the steps of a certificate replacement, with settings reprotect in its place
  • A test for the read with a previous certificate

Found in the review of #3433. Bundle 25.

Vorherrschende Sprache
C#
Sterne
567
Forks
107
Ø Merge
1 Std. 19 Min.
Gemergte PRs (30 T.)
353

Entwicklungsumgebung

Erste Schritte

  1. Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
  3. Forken Sie das Repository und arbeiten Sie in einem Branch.
  4. Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.

Mehr aus fluentcms/FluentCMS

Alle Issues in fluentcms/FluentCMS

Ähnliche Issues

Weitere Issues zu C#

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.