secrets

package
v0.0.0-...-b2745ab Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 4, 2026 License: AGPL-3.0 Imports: 9 Imported by: 0

Documentation

Rendered for windows/amd64

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SetIPCAPI

func SetIPCAPI(client IPCAPI)

SetIPCAPI registers the manager IPC implementation (call after InitializeIPCClient).

Types

type IPCAPI

type IPCAPI interface {
	Ready() bool
	GetUserSecrets(userID string) (secretstore.UserSecrets, error)
	SaveUserSecrets(userID string, update secretstore.SecretsUpdate) error
	DeleteUserSecrets(userID string, flags secretstore.DeleteSecretsFlags) error
}

IPCAPI is implemented by the manager IPC client and registered at UI startup.

type SecretManager

type SecretManager struct{}

SecretManager stores and retrieves secrets via the manager service (DPAPI files as SYSTEM).

func NewSecretManager

func NewSecretManager() *SecretManager

NewSecretManager creates a new SecretManager instance.

func (*SecretManager) DeleteOlmCredentials

func (sm *SecretManager) DeleteOlmCredentials(userId string) bool

DeleteOlmCredentials deletes both OLM ID and secret for the given user ID.

func (*SecretManager) DeleteSessionToken

func (sm *SecretManager) DeleteSessionToken(userId string) bool

DeleteSessionToken removes a session token for a given user.

func (*SecretManager) GetOlmId

func (sm *SecretManager) GetOlmId(userId string) (string, bool)

GetOlmId retrieves the OLM ID for the given user ID.

func (*SecretManager) GetOlmSecret

func (sm *SecretManager) GetOlmSecret(userId string) (string, bool)

GetOlmSecret retrieves the OLM secret for the given user ID.

func (*SecretManager) GetSessionToken

func (sm *SecretManager) GetSessionToken(userId string) (string, bool)

GetSessionToken retrieves the session token for the given user ID.

func (*SecretManager) HasOlmCredentials

func (sm *SecretManager) HasOlmCredentials(userId string) bool

HasOlmCredentials checks if OLM credentials exist for the given user ID.

func (*SecretManager) SaveOlmCredentials

func (sm *SecretManager) SaveOlmCredentials(userId, olmId, secret string) bool

SaveOlmCredentials saves both OLM ID and secret for the given user ID.

func (*SecretManager) SaveSessionToken

func (sm *SecretManager) SaveSessionToken(userId string, token string) bool

SaveSessionToken saves a session token for the given user ID.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL