Feat: add vault module

This commit is contained in:
2025-05-15 15:28:00 +03:00
parent 09635f3a32
commit 7d7f94f114
15 changed files with 1178 additions and 17 deletions

22
vault/src/session.rs Normal file
View File

@@ -0,0 +1,22 @@
//! Session manager for the vault crate (optional)
use crate::data::KeyspaceData;
use std::collections::HashMap;
pub struct SessionManager {
unlocked_keyspaces: HashMap<String, KeyspaceData>,
current_keyspace: Option<String>,
current_keypair: Option<String>,
// ...
}
impl SessionManager {
pub fn new() -> Self {
Self {
unlocked_keyspaces: HashMap::new(),
current_keyspace: None,
current_keypair: None,
}
}
// ... methods for unlock, lock, select, timeout, etc.
}