mirror of
https://github.com/neon443/ShhShell.git
synced 2026-03-11 13:26:16 +00:00
add suthfailed for when auth fails
This commit is contained in:
@@ -85,6 +85,7 @@ class SSHHandler: @unchecked Sendable, ObservableObject {
|
|||||||
|
|
||||||
if !host.password.isEmpty {
|
if !host.password.isEmpty {
|
||||||
do { try authWithPw() } catch {
|
do { try authWithPw() } catch {
|
||||||
|
state = .authFailed
|
||||||
print("pw auth error")
|
print("pw auth error")
|
||||||
print(error.localizedDescription)
|
print(error.localizedDescription)
|
||||||
}
|
}
|
||||||
@@ -94,6 +95,7 @@ class SSHHandler: @unchecked Sendable, ObservableObject {
|
|||||||
try authWithPubkey()
|
try authWithPubkey()
|
||||||
}
|
}
|
||||||
} catch {
|
} catch {
|
||||||
|
state = .authFailed
|
||||||
print("error with pubkey auth")
|
print("error with pubkey auth")
|
||||||
print(error.localizedDescription)
|
print(error.localizedDescription)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user