Share Vault, persistence, SSH/SFTP, forwarding, and SwiftUI components across platforms. Add mobile editors, terminal input, standalone Assistant, Metrics navigation, transfers, and a unified Live Activity with host system icons. Validation: 35 iOS tests and 100 focused macOS tests pass; formatting and zh-Hans checks pass. The full macOS run reports 14 issues in the documented timing, Keychain, and popover suites. Remaining Assistant tool and CloudKit work is tracked in Memory/MOBILE_ROLLOUT.md.
34 lines
980 B
Swift
34 lines
980 B
Swift
import Foundation
|
|
import TermindDomain
|
|
|
|
import struct TermindDomain.Host
|
|
|
|
public nonisolated enum SSHRouteEvent: Hashable, Sendable {
|
|
case connecting(Host.ID)
|
|
case authenticating(Host.ID)
|
|
case authenticated(Host.ID)
|
|
case connected(Host.ID)
|
|
case initializing(Host.ID, String)
|
|
}
|
|
|
|
public typealias SSHRouteProgressHandler = @Sendable (SSHRouteEvent) -> Void
|
|
|
|
public nonisolated struct SSHAuthenticationSubmission: Hashable, Sendable {
|
|
public var username: String
|
|
public var password: String?
|
|
public var passphrase: String?
|
|
public var keyID: SSHKeyRef.ID?
|
|
public var identityID: Identity.ID? = nil
|
|
public init(
|
|
username: String, password: String? = nil, passphrase: String? = nil, keyID: SSHKeyRef.ID? = nil,
|
|
identityID: Identity.ID? = nil
|
|
) {
|
|
self.username = username
|
|
self.password = password
|
|
self.passphrase = passphrase
|
|
self.keyID = keyID
|
|
self.identityID = identityID
|
|
}
|
|
|
|
}
|