Skip to content

Add a file-system backend for the certificate chain cache #3522

Description

@jpraynaud

Why

The in-memory cache does not survive a restart, and the CLI starts a fresh process on every command, so nothing is saved across invocations.

What

Add a FileCertificateVerifierCache implementation of CertificateVerifierCache in mithril-client for non-WASM targets.

How

  • Store each certificate in a separate file
  • Use a folder for the committed cache
  • Use a folder by certificate chain validation id for staging (support pruning?)
  • Invalidate the cache entry upon parsing error of a certificate file
  • Upon committing, the staged certificates are moved the to the committed cache (atomic files move, do we need some Mutex to commit staging area sequentially?)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions