pub struct FileKeyringStore { /* private fields */ }Expand description
JSON-on-disk secret store for headless environments.
This is the default backend. Secrets are serialised as a JSON object
at <home>/.codewhale/secrets/secrets.json with Unix file mode 0600
(owner read/write only). The parent directory is created with mode 0700
if it does not exist.
On Unix, the store rejects files whose permissions are more permissive
than 0600 (i.e. group or world bits are set). This prevents other
users on the system from reading stored credentials. On Windows, the
ACL model is too different to enforce programmatically; callers are
responsible for placing the file in a per-user directory.
Implementations§
Source§impl FileKeyringStore
impl FileKeyringStore
Sourcepub fn default_path() -> Result<PathBuf, SecretsError>
pub fn default_path() -> Result<PathBuf, SecretsError>
Default path: <home>/.codewhale/secrets/secrets.json. Honours
CODEWHALE_HOME, then HOME, USERPROFILE, and finally the platform
home directory from the dirs crate. On first use, non-conflicting
entries from the legacy <home>/.deepseek/secrets/secrets.json file are
copied into the CodeWhale store.
Trait Implementations§
Source§impl Clone for FileKeyringStore
impl Clone for FileKeyringStore
Source§fn clone(&self) -> FileKeyringStore
fn clone(&self) -> FileKeyringStore
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more