mirror of
https://github.com/rustdesk/rustdesk.git
synced 2026-04-18 16:21:29 +03:00
This commit is contained in:
@@ -619,8 +619,11 @@ pub fn is_prelogin() -> bool {
|
|||||||
if is_flatpak() {
|
if is_flatpak() {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
let n = get_active_userid().len();
|
let name = get_active_username();
|
||||||
n < 4 && n > 1
|
if let Ok(res) = run_cmds(&format!("getent passwd {}", name)) {
|
||||||
|
return res.contains("/bin/false") || res.contains("/usr/sbin/nologin");
|
||||||
|
}
|
||||||
|
false
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check "Lock".
|
// Check "Lock".
|
||||||
|
|||||||
Reference in New Issue
Block a user