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