pub struct PassStorageAdapter { /* private fields */ }Expand description
Pass (password-store) storage adapter
Stores credentials as GPG-encrypted files in a password store directory. Uses prs-lib for password store operations.
Implementations§
Source§impl PassStorageAdapter
impl PassStorageAdapter
pub fn new_with_options( store_path: PathBuf, path: PathBuf, gpg_backend: GpgBackend, allow_create_without_prompt: bool, ) -> Result<Self>
Sourcepub fn audit_passkey_recipients(&self) -> Result<Vec<AuditEntry>>
pub fn audit_passkey_recipients(&self) -> Result<Vec<AuditEntry>>
Scan all passkey files and report those whose OpenPGP packet recipients
differ from the effective .gpg-id policy.
Requires the gpg binary for packet inspection.
Sourcepub fn reencrypt_passkey_file(&mut self, path: &Path) -> Result<()>
pub fn reencrypt_passkey_file(&mut self, path: &Path) -> Result<()>
Re-encrypt a passkey file so its OpenPGP recipients match the current
.gpg-id policy.
- Decrypts the file using an available secret key.
- Resolves the effective recipients via
resolve_recipients_for_target. - Re-encrypts to a temporary file.
- Atomically renames the temporary over the original.
- Commits the change via the password-store Git integration.
Trait Implementations§
Source§impl CredentialStorage for PassStorageAdapter
impl CredentialStorage for PassStorageAdapter
Source§fn read_first(&mut self, filter: CredentialFilter) -> Result<Credential>
fn read_first(&mut self, filter: CredentialFilter) -> Result<Credential>
Start a new iteration and return the first matching credential
Source§fn read_next(&mut self) -> Result<Credential>
fn read_next(&mut self) -> Result<Credential>
Continue the current iteration and return the next credential
Source§fn count_credentials(&self) -> usize
fn count_credentials(&self) -> usize
Count total number of stored credentials
Source§fn disable_user_verification(&self) -> bool
fn disable_user_verification(&self) -> bool
Check if user verification should be disabled for this backend Read more
Source§fn cleanup_expired_cache(&mut self)
fn cleanup_expired_cache(&mut self)
Cleanup expired cache entries (if caching is supported) Read more
Auto Trait Implementations§
impl Freeze for PassStorageAdapter
impl RefUnwindSafe for PassStorageAdapter
impl Send for PassStorageAdapter
impl Sync for PassStorageAdapter
impl Unpin for PassStorageAdapter
impl UnsafeUnpin for PassStorageAdapter
impl UnwindSafe for PassStorageAdapter
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more