ehang-io / nps

一款轻量级、高性能、功能强大的内网穿透代理服务器。支持tcp、udp、socks5、http等几乎所有流量转发,可用来访问内网网站、本地支付接口调试、ssh访问、远程桌面,内网dns解析、内网socks5代理等等……,并带有功能强大的web管理端。a lightweight, high-performance, powerful intranet penetration proxy server, with a powerful web management terminal.
https://ehang.io/nps/documents
GNU General Public License v3.0
29.71k stars 5.36k forks source link

写了一个开启关闭隧道的工具 #1244

Closed mirror222 closed 6 months ago

mirror222 commented 9 months ago

主要想法是为了避免内网机器受到攻击,平时把隧道关闭,需要的时候再开启, 于是昨天花了一点点时间写了一个命令行工具用于开启关闭隧道。

https://github.com/mirror222/NPSHelper

以下是远程桌面的一个例子:


NpsHelper.exe -h <服务器IP>:8024 -k <Auth_Key> -t <隧道ID>
%windir%\system32\mstsc.exe /v:<服务器IP>:<隧道端口>
NpsHelper.exe -h <服务器IP>:8024 -k Auth_Key -t <隧道ID> -c

当远程桌面窗体关闭后会自动关闭隧道。

当然也可以用在TortoiseSVN 或者其他工具:

image

mybove commented 6 months ago

直接修改唯一验证密钥,在需要的时候修改为正确的即可