🚀 Feature: ephemeral private key (do not store private key on disk) #196

Closed
opened 2025-10-07 00:05:37 +03:00 by OVERLORD · 3 comments
Owner

Originally created by @ItalyPaleAle on GitHub.

Feature description

Instead of saving the private key to disk, Pocket ID could optionally generate a key when it starts up and keep it in-memory only. This would be optional.

Pros:

  • Private keys are never stored un-encrypted on disk (see also #580)
  • The key is rotated frequently, every time Pocket ID starts up

Cons:

  • The key changes every time Pocket ID is started, which means that tokens issued by Pocket ID would be invalidated on every restart. This may or may not be acceptable depending on what the downstream clients expect. This is why this feature is optional.

Pitch

This is another relatively simple feature to implement that helps protecting the "keys to the kingdom". It may not be suitable for all scenarios, but many users who run Pocket ID in their homelab would likely have minimal to no impact when using this.

Originally created by @ItalyPaleAle on GitHub. ### Feature description Instead of saving the private key to disk, Pocket ID could optionally generate a key when it starts up and keep it in-memory only. This would be **optional**. Pros: - Private keys are never stored un-encrypted on disk (see also #580) - The key is rotated frequently, every time Pocket ID starts up Cons: - The key changes every time Pocket ID is started, which means that tokens issued by Pocket ID would be invalidated on every restart. This _may or may not_ be acceptable depending on what the downstream clients expect. This is why this feature is optional. ### Pitch This is another relatively simple feature to implement that helps protecting the "keys to the kingdom". It may not be suitable for _all_ scenarios, but many users who run Pocket ID in their homelab would likely have minimal to no impact when using this.
OVERLORD added the feature label 2025-10-07 00:05:37 +03:00
Author
Owner

@kmendell commented on GitHub:

Im closing this as we can just track it in https://github.com/pocket-id/pocket-id/issues/580, since its seems like it can be part of that.

@kmendell commented on GitHub: Im closing this as we can just track it in https://github.com/pocket-id/pocket-id/issues/580, since its seems like it can be part of that.
Author
Owner

@ItalyPaleAle commented on GitHub:

Why would it be a point of failure?

Agree it can be confusing. I am thinking this should be optional for this reason.

@ItalyPaleAle commented on GitHub: Why would it be a point of failure? Agree it can be confusing. I am thinking this should be optional for this reason.
Author
Owner

@kmendell commented on GitHub:

I think the encryption idea makes sense, but this would introduce a point of failure and may just cause confusion for people if they are not the best at troubelshooting as well.

@kmendell commented on GitHub: I think the encryption idea makes sense, but this would introduce a point of failure and may just cause confusion for people if they are not the best at troubelshooting as well.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/pocket-id#196