mirror of
https://github.com/TermoraDev/termora.git
synced 2026-01-16 02:12:58 +08:00
fix: 修复使用 HTTP 代理无效的问题
This commit is contained in:
@@ -92,14 +92,14 @@ object SshClients {
|
|||||||
sshClient.setProxyDatabase {
|
sshClient.setProxyDatabase {
|
||||||
if (host.proxy.authenticationType == AuthenticationType.No) ProxyData(
|
if (host.proxy.authenticationType == AuthenticationType.No) ProxyData(
|
||||||
Proxy(
|
Proxy(
|
||||||
Proxy.Type.SOCKS,
|
if (host.proxy.type == ProxyType.SOCKS5) Proxy.Type.SOCKS else Proxy.Type.HTTP,
|
||||||
InetSocketAddress(host.proxy.host, host.proxy.port)
|
InetSocketAddress(host.proxy.host, host.proxy.port)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
else
|
else
|
||||||
ProxyData(
|
ProxyData(
|
||||||
Proxy(
|
Proxy(
|
||||||
Proxy.Type.SOCKS,
|
if (host.proxy.type == ProxyType.SOCKS5) Proxy.Type.SOCKS else Proxy.Type.HTTP,
|
||||||
InetSocketAddress(host.proxy.host, host.proxy.port)
|
InetSocketAddress(host.proxy.host, host.proxy.port)
|
||||||
),
|
),
|
||||||
host.proxy.username,
|
host.proxy.username,
|
||||||
|
|||||||
Reference in New Issue
Block a user