@wwkit/sshproxy 1.0.3 → 1.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/index.js +2 -2
- package/package.json +2 -2
- package/src/ProxyManager.js +1 -1
- package/src/init.js +1 -1
- package/src/web/public/index.html +1 -1
package/bin/index.js
CHANGED
|
@@ -197,7 +197,7 @@ async function handleStart() {
|
|
|
197
197
|
const result = await manager.start()
|
|
198
198
|
if (result.ok) {
|
|
199
199
|
const [host, port] = clientAddr()
|
|
200
|
-
console.log(`代理地址:
|
|
200
|
+
console.log(`代理地址: socks5://${host}:${port}`)
|
|
201
201
|
}
|
|
202
202
|
printResult(result)
|
|
203
203
|
}
|
|
@@ -216,7 +216,7 @@ function handleStatus() {
|
|
|
216
216
|
} else {
|
|
217
217
|
console.log('隧道: 未运行')
|
|
218
218
|
}
|
|
219
|
-
console.log(`代理地址:
|
|
219
|
+
console.log(`代理地址: socks5://${status.host}:${status.port}`)
|
|
220
220
|
console.log(`系统代理: ${status.system_proxy.enabled ? '已开启' : '已关闭'}`)
|
|
221
221
|
const chrome = status.chrome
|
|
222
222
|
console.log(`代理 Chrome: ${chrome.running ? `运行中 (PID=${chrome.pid})` : '未运行'}`)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wwkit/sshproxy",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.5",
|
|
4
4
|
"author": "bluesliu <langcai163@163.com>",
|
|
5
5
|
"description": "SOCKS5 proxy manager (client SSH tunnel / server remote), CLI + web UI",
|
|
6
6
|
"type": "module",
|
|
@@ -46,6 +46,6 @@
|
|
|
46
46
|
"postinstall": "node scripts/postinstall.js",
|
|
47
47
|
"test": "node --experimental-vm-modules node_modules/jest/bin/jest.js --no-cache tests/unit",
|
|
48
48
|
"test:all": "node --experimental-vm-modules node_modules/jest/bin/jest.js --no-cache tests/unit",
|
|
49
|
-
"release": "
|
|
49
|
+
"release": "node ../../packages/shared/bin/release-pkg.js"
|
|
50
50
|
}
|
|
51
51
|
}
|
package/src/ProxyManager.js
CHANGED
|
@@ -106,7 +106,7 @@ export class ProxyManager {
|
|
|
106
106
|
const cfg = this.config()
|
|
107
107
|
const ok = await this._startTunnel(cfg.host, cfg.port)
|
|
108
108
|
if (!ok) return { ok: false, message: '隧道启动失败' }
|
|
109
|
-
return { ok: true, message: `隧道已启动 (
|
|
109
|
+
return { ok: true, message: `隧道已启动 (socks5://${cfg.host}:${cfg.port})` }
|
|
110
110
|
}
|
|
111
111
|
|
|
112
112
|
_doTunnelStop() {
|
package/src/init.js
CHANGED
|
@@ -112,6 +112,6 @@ export async function initClient() {
|
|
|
112
112
|
}
|
|
113
113
|
|
|
114
114
|
lines.push('')
|
|
115
|
-
lines.push(`初始化完成!执行 sshproxy tunnel on 启动隧道 (
|
|
115
|
+
lines.push(`初始化完成!执行 sshproxy tunnel on 启动隧道 (socks5://${localHost}:${localPort})`)
|
|
116
116
|
return lines
|
|
117
117
|
}
|
|
@@ -166,7 +166,7 @@
|
|
|
166
166
|
const s = status
|
|
167
167
|
if (!s) return
|
|
168
168
|
const rows = []
|
|
169
|
-
rows.push(['地址', `<span class="value mono"
|
|
169
|
+
rows.push(['地址', `<span class="value mono">socks5://${esc(s.host)}:${s.port}</span>`])
|
|
170
170
|
rows.push(['代理隧道', s.tunnel && s.tunnel.running
|
|
171
171
|
? `<span class="tag success">运行中${s.tunnel.pid ? ` (PID=${s.tunnel.pid})` : ''}</span>`
|
|
172
172
|
: '<span class="tag info">未运行</span>'])
|