Skip to content

many: use persistent secret state for recovery keys, passphrases and PINs - #17421

Open
ZeyadYasser wants to merge 14 commits into
canonical:masterfrom
ZeyadYasser:use-memfd-secret-state
Open

many: use persistent secret state for recovery keys, passphrases and PINs#17421
ZeyadYasser wants to merge 14 commits into
canonical:masterfrom
ZeyadYasser:use-memfd-secret-state

Conversation

@ZeyadYasser

Copy link
Copy Markdown
Contributor

This PR builds on #17358 and should be rebased after it is merged. Relevant commits:

Drop in-memory recovery key cache and state cache for passphrase/PINs in favor of memfd-backed secret state that can survive snapd restarts.

JIRA: SNAPDENG-36926

Add a new type of state for secrets backed by memfd-secret
that can persists through snapd restarts by using the
fdstore.

This secret store fallbacks to an in-memory store if it
fails to initialize a memfd-secret backed state.

Signed-off-by: Zeyad Gouda <zeyad.gouda@canonical.com>
Signed-off-by: Zeyad Gouda <zeyad.gouda@canonical.com>
Signed-off-by: Zeyad Gouda <zeyad.gouda@canonical.com>
Signed-off-by: Zeyad Gouda <zeyad.gouda@canonical.com>
Signed-off-by: Zeyad Gouda <zeyad.gouda@canonical.com>
Signed-off-by: Zeyad Gouda <zeyad.gouda@canonical.com>
Signed-off-by: Zeyad Gouda <zeyad.gouda@canonical.com>
Signed-off-by: Zeyad Gouda <zeyad.gouda@canonical.com>
Signed-off-by: Zeyad Gouda <zeyad.gouda@canonical.com>
Signed-off-by: Zeyad Gouda <zeyad.gouda@canonical.com>
Signed-off-by: Zeyad Gouda <zeyad.gouda@canonical.com>
Signed-off-by: Zeyad Gouda <zeyad.gouda@canonical.com>
Drop in-memory recovery key cache in favor of memfd
backed secret state that can survive snapd restarts

Signed-off-by: Zeyad Gouda <zeyad.gouda@canonical.com>
Drop in-memory cache in favor of memfd backed secret state
that can survive snapd restarts

Signed-off-by: Zeyad Gouda <zeyad.gouda@canonical.com>
@ZeyadYasser ZeyadYasser added this to the 2.78 milestone Jul 31, 2026
@github-actions github-actions Bot added the Needs Documentation -auto- Label automatically added which indicates the change needs documentation label Jul 31, 2026
@github-actions

Copy link
Copy Markdown

Fri Jul 31 09:00:04 UTC 2026
The following results are from: https://github.com/canonical/snapd/actions/runs/30617786595

No spread failures reported

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

Labels

Needs Documentation -auto- Label automatically added which indicates the change needs documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant