feat(opsec): implement inactivity auto-lock, session lock detection, and anti-leak shield
This commit is contained in:
+29
-1
@@ -60,6 +60,18 @@ enum Commands {
|
||||
/// Deaktiviert das Windows System-Tray Icon während des Mounts
|
||||
#[arg(long, default_value_t = false)]
|
||||
no_tray: bool,
|
||||
|
||||
/// Automatisches Aushängen und Sperren nach N Sekunden Inaktivität (z. B. 300 für 5 Minuten)
|
||||
#[arg(long, value_name = "SECS")]
|
||||
idle_timeout: Option<u64>,
|
||||
|
||||
/// Verhindert das automatische Sperren beim Sperren des Windows-Bildschirms (Win + L)
|
||||
#[arg(long, default_value_t = false)]
|
||||
no_screen_lock: bool,
|
||||
|
||||
/// Deaktiviert das Blockieren und Verbergen von Windows Explorer Metadaten (Thumbs.db, desktop.ini)
|
||||
#[arg(long, default_value_t = false)]
|
||||
no_anti_leak: bool,
|
||||
},
|
||||
|
||||
/// Trennt ein eingebundenes Netzlaufwerk manuell
|
||||
@@ -481,6 +493,9 @@ async fn run() -> Result<()> {
|
||||
recovery_key,
|
||||
no_open,
|
||||
no_tray,
|
||||
idle_timeout,
|
||||
no_screen_lock,
|
||||
no_anti_leak,
|
||||
} => {
|
||||
let drive_char = match drive {
|
||||
Some(ref d) => parse_drive_letter(d)?,
|
||||
@@ -508,7 +523,20 @@ async fn run() -> Result<()> {
|
||||
|
||||
let open_explorer = !no_open;
|
||||
let enable_tray = !no_tray;
|
||||
mount_container(&path, drive_char, port, auth, open_explorer, enable_tray).await?;
|
||||
let lock_on_screen_lock = !no_screen_lock;
|
||||
let anti_leak = !no_anti_leak;
|
||||
mount_container(
|
||||
&path,
|
||||
drive_char,
|
||||
port,
|
||||
auth,
|
||||
open_explorer,
|
||||
enable_tray,
|
||||
idle_timeout,
|
||||
lock_on_screen_lock,
|
||||
anti_leak,
|
||||
)
|
||||
.await?;
|
||||
}
|
||||
Commands::Unmount { drive } => {
|
||||
let drive_char = parse_drive_letter(&drive)?;
|
||||
|
||||
Reference in New Issue
Block a user