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
30.47k stars 5.5k forks source link

8024端口连接不上 #1088

Closed chenkehao1998 closed 1 year ago

chenkehao1998 commented 2 years ago

用netstat看过了 没问题 可以telnet 通 但是npc连不上

不可能是服务器没开端口,之前一直没问题,今天突然就npc报错连不上8024端口

chenkehao1998 commented 2 years ago

2022/07/20 15:15:42.409 [I] [npc.go:231] the version of client is 0.26.10, the core version of client is 0.26.0 2022/07/20 15:15:52.435 [E] [control.go:231] read tcp 192.168.31.148:64770->124.223.35.110:8024: i/o timeout 2022/07/20 15:15:52.435 [E] [client.go:63] The connection server failed and will be reconnected in five seconds, error read tcp 192.168.31.148:64770->124.223.35.110:8024: i/o timeout

chenkehao1998 commented 2 years ago

重装了 不管是docker方式启动还是直接安装的方式 都试过了

chenkehao1998 commented 2 years ago

image

chenkehao1998 commented 2 years ago

在服务端的日志里发现了这个 2022/07/20 07:11:11.304 [I] [bridge.go:169] The client 115.236.14.158:64404 connect error%!(EXTRA string=EOF)

chenkehao1998 commented 2 years ago

我有两台电脑一台可以连上 另一条不行 请问一般是什么原因 不能连的那台电脑 telnet 这个端口也是可以通的

chenkehao1998 commented 2 years ago

2022/07/20 07:24:54.332 [I] [bridge.go:251] clientId 2 connection succeeded, address:223.104.244.135:4243 2022/07/20 07:24:58 mux: read session unpack from connection err read tcp 10.0.4.14:8024->223.104.244.135:4244: read: connection reset by peer 2022/07/20 07:24:58 close mux

fengqiangboy commented 2 years ago

我也是,周五开始,怎么都连不上

zhx47 commented 2 years ago

同,最近一段时间怎么也连不上了

leisurexi commented 2 years ago

大佬们,解决了吗,我也出现这个问题了

fengqiangboy commented 2 years ago

不知道是不是证书啥的过期了,反正我换其他工具了,这个搞不定

zhx47 commented 2 years ago

不知道是不是证书啥的过期了,反正我换其他工具了,这个搞不定

诡异的是,我家里有台N1可以继续连,其他的设备全挂了

leisurexi commented 2 years ago

@fengqiangboy 大佬换什么工具了,推荐一下

chenkehao1998 commented 2 years ago

不知道是不是证书啥的过期了,反正我换其他工具了,这个搞不定

诡异的是,我家里有台N1可以继续连,其他的设备全挂了

我笔记本可以连 但是我的台式机连不上了 真的诡异

fengqiangboy commented 2 years ago

@fengqiangboy 大佬换什么工具了,推荐一下

https://github.com/snail007/goproxy 用这个了

zhx47 commented 2 years ago

goproxy非专业版不能设置密码啊

chenkehao1998 commented 2 years ago

话说这个项目,作者是不维护了吗 我看好多issue都没人管了 而且仓库好久没有commit过了

fengqiangboy commented 2 years ago

goproxy非专业版不能设置密码啊

可以吧,客户端和服务端用证书认证的

chenkehao1998 commented 2 years ago

老哥们,直接用frp吧

fengqiangboy commented 2 years ago

老哥们,直接用frp吧

FRP也可以,还在更新维护

Matzoh commented 2 years ago

同样的问题,客户端和服务端版本一致:

the version of client is 0.26.10, the core version of client is 0.26.0

docker 中的客户端无法连接(之前一直正常使用,偶尔会隔几天断开一次,今天中午突然断开并无法重连,重启容器等都无效)(使用宿主机可以ping通,并且telnet及端口号都可以通,nps 服务端重启也无法重连) 另一台mac 客户端可以正常连接。

The connection server failed and will be reconnected in five seconds, error read tcp 192.168.101.15:56192->xxxxxx:8024: i/o timeout 2022/09/01 05:26:34.470 [E] [client.go:63] The connection server failed and will be reconnected in five seconds, error EOF 2022/09/01 05:26:45.247 [E] [client.go:63] The connection server failed and will be reconnected in five seconds, error EOF 2022/09/01 05:26:56.005 [E] [client.go:63] The connection server failed and will be reconnected in five seconds, error EOF 2022/09/01 05:27:06.778 [E] [client.go:63] The connection server failed and will be reconnected in five seconds, error EOF

DamonDBT commented 1 year ago

同样的问题,在公司网络Telnet端口能通,但是就不能连接,换成手机热点就可以连接。 公司网络报错: '''' 2022/10/08 12:36:35.922 [E] [control.go:231] read tcp ####:13954->####:8024: wsarecv: An existing connection was forcibly closed by the remote host. 2022/10/08 12:36:35.923 [E] [client.go:63] The connection server failed and will be reconnected in five seconds, error read tcp 10.76.35.156:13954->47.108.197.235:8024: wsarecv: An existing connection was forcibly closed by the remote host. 2022/10/08 12:36:41.167 [E] [control.go:231] read tcp ####:13957->####:8024: wsarecv: An existing connection was forcibly closed by the remote host. 2022/10/08 12:36:41.167 [E] [client.go:63] The connection server failed and will be reconnected in five seconds, error read tcp ####:13957->####:8024: wsarecv: An existing connection was forcibly closed by the remote host. ''''

DamonDBT commented 1 year ago

公司查 了一下,是硬件防火墙自己的规则自动触发拦截了。 image

fengqiangboy commented 1 year ago

公司查 了一下,是硬件防火墙自己的规则自动触发拦截了。 image

深信服?

DamonDBT commented 1 year ago

具体我不知道了,这是网络部门发过来的,加了特例,可以用了。

fengqiangboy commented 1 year ago

具体我不知道了,这是网络部门发过来的,加了特例,可以用了。

我感觉有可能是最近防火墙新增的规则,然后批量下发给全部防火墙了,然后就都突然被bang了

DamonDBT commented 1 year ago

是的,大概2个月前公司网络可以用的。但是这几天不行了。 但是另外一个客户的网络,是一直不能用,不知道为什么了。 如果是防火墙更新了规则,是根据8024端口扫的吗?那我修改默认端口是不是也可以绕过去?

zhx47 commented 1 year ago

因为nps,我服务器的ip被公司防火墙拉黑了。。。现在换回frp了,可能公司防火墙对frp做了处理,到目前为止还没有问题

fengqiangboy commented 1 year ago

是的,大概2个月前公司网络可以用的。但是这几天不行了。 但是另外一个客户的网络,是一直不能用,不知道为什么了。 如果是防火墙更新了规则,是根据8024端口扫的吗?那我修改默认端口是不是也可以绕过去?

换端口没用吧,应该不是简单的识别端口

zhx47 commented 1 year ago

是的,大概2个月前公司网络可以用的。但是这几天不行了。 但是另外一个客户的网络,是一直不能用,不知道为什么了。 如果是防火墙更新了规则,是根据8024端口扫的吗?那我修改默认端口是不是也可以绕过去?

换端口没用吧,应该不是简单的识别端口

确实,防火墙都是通过流量特征来识别的,不是简单的换端口这么简单。 比如很多防火墙会封堵todest、向日葵等远程桌面的流量,但是我发现rustdesk基本上没有封堵的

jsgzsjskj commented 1 year ago

@fengqiangboy大佬换什么工具了,推荐一下

https://github.com/snail007/goproxy用这个了

不知道会不会被校园网拦截,我使用frp和nps都被校园网拦截