[GH-ISSUE #3730] frps日志中的未知IP地址 #2969

Closed
opened 2026-05-05 13:55:03 -06:00 by gitea-mirror · 5 comments
Owner

Originally created by @zhixin612 on GitHub (Oct 29, 2023).
Original GitHub issue: https://github.com/fatedier/frp/issues/3730

Bug Description

请问通过frps连接其他设备时,frps服务器端日志中的“userConn.RemoteAddr”地址是什么
(即日志中“userConn l[AAA] r[BBB]”的BBB部分)

为什么会解析出来不属于自己服务器、客户端的地址?并且使用防火墙屏蔽该IP之后下次连接还会出现新的IP?

图片

图中红色遮挡部分是我终端设备的IP,但黄色标注部分的IP地址并非我的服务器、任一终端设备的IP

frpc Version

0.52.3

frps Version

0.52.3

System Architecture

linux/amd64

Configurations

NULL

Logs

No response

Steps to reproduce

No response

Affected area

  • Docs
  • Installation
  • Performance and Scalability
  • Security
  • User Experience
  • Test and Release
  • Developer Infrastructure
  • Client Plugin
  • Server Plugin
  • Extensions
  • Others
Originally created by @zhixin612 on GitHub (Oct 29, 2023). Original GitHub issue: https://github.com/fatedier/frp/issues/3730 ### Bug Description 请问通过frps连接其他设备时,frps服务器端日志中的“userConn.RemoteAddr”地址是什么 (即日志中“userConn l[AAA] r[BBB]”的BBB部分) 为什么会解析出来不属于自己服务器、客户端的地址?并且使用防火墙屏蔽该IP之后下次连接还会出现新的IP? ![图片](https://github.com/fatedier/frp/assets/53746620/ecaad40c-5521-4486-a1b3-c01efa9bbf75) 图中红色遮挡部分是我终端设备的IP,但黄色标注部分的IP地址并非我的服务器、任一终端设备的IP ### frpc Version 0.52.3 ### frps Version 0.52.3 ### System Architecture linux/amd64 ### Configurations NULL ### Logs _No response_ ### Steps to reproduce _No response_ ### Affected area - [ ] Docs - [ ] Installation - [ ] Performance and Scalability - [X] Security - [ ] User Experience - [ ] Test and Release - [ ] Developer Infrastructure - [ ] Client Plugin - [ ] Server Plugin - [ ] Extensions - [ ] Others
Author
Owner

@superzjg commented on GitHub (Oct 29, 2023):

这个我观察过我的https代理,workConn 的 l 后面是frps服务器ip,r 后面是客户端外网ip
userConn的 r 对应我的客户端内网ip。

你的ip若有问题,尝试更换端口,可能是有人在扫描并尝试连接,一般不会造成损失,因为你转发的服务肯定有强密码,别人登录不上。。
其实我觉得还是stcp更安全。

<!-- gh-comment-id:1784043080 --> @superzjg commented on GitHub (Oct 29, 2023): 这个我观察过我的https代理,workConn 的 l 后面是frps服务器ip,r 后面是客户端外网ip userConn的 r 对应我的客户端内网ip。 你的ip若有问题,尝试更换端口,可能是有人在扫描并尝试连接,一般不会造成损失,因为你转发的服务肯定有强密码,别人登录不上。。 其实我觉得还是stcp更安全。
Author
Owner

@zhixin612 commented on GitHub (Oct 29, 2023):

这个我观察过我的https代理,workConn 的 l 后面是frps服务器ip,r 后面是客户端外网ip userConn的 r 对应我的客户端内网ip。

你的ip若有问题,尝试更换端口,可能是有人在扫描并尝试连接,一般不会造成损失,因为你转发的服务肯定有强密码,别人登录不上。。 其实我觉得还是stcp更安全。

谢谢回复,你说的有道理,不过我没有明白为什么这个userConn.RemoteAddr的IP为什么不是我的终端设备的实际IP地址,我并没有使用代理。不知道是bug还是怎样

<!-- gh-comment-id:1784045755 --> @zhixin612 commented on GitHub (Oct 29, 2023): > 这个我观察过我的https代理,workConn 的 l 后面是frps服务器ip,r 后面是客户端外网ip userConn的 r 对应我的客户端内网ip。 > > 你的ip若有问题,尝试更换端口,可能是有人在扫描并尝试连接,一般不会造成损失,因为你转发的服务肯定有强密码,别人登录不上。。 其实我觉得还是stcp更安全。 谢谢回复,你说的有道理,不过我没有明白为什么这个userConn.RemoteAddr的IP为什么不是我的终端设备的实际IP地址,我并没有使用代理。不知道是bug还是怎样
Author
Owner

@superzjg commented on GitHub (Oct 29, 2023):

这个我观察过我的https代理,workConn 的 l 后面是frps服务器ip,r 后面是客户端外网ip userConn的 r 对应我的客户端内网ip。
你的ip若有问题,尝试更换端口,可能是有人在扫描并尝试连接,一般不会造成损失,因为你转发的服务肯定有强密码,别人登录不上。。 其实我觉得还是stcp更安全。

谢谢回复,你说的有道理,不过我没有明白为什么这个userConn.RemoteAddr的IP为什么不是我的终端设备的实际IP地址,我并没有使用代理。不知道是bug还是怎样

我刚试了,是显示自己的ip的。

<!-- gh-comment-id:1784052198 --> @superzjg commented on GitHub (Oct 29, 2023): > > 这个我观察过我的https代理,workConn 的 l 后面是frps服务器ip,r 后面是客户端外网ip userConn的 r 对应我的客户端内网ip。 > > 你的ip若有问题,尝试更换端口,可能是有人在扫描并尝试连接,一般不会造成损失,因为你转发的服务肯定有强密码,别人登录不上。。 其实我觉得还是stcp更安全。 > > 谢谢回复,你说的有道理,不过我没有明白为什么这个userConn.RemoteAddr的IP为什么不是我的终端设备的实际IP地址,我并没有使用代理。不知道是bug还是怎样 我刚试了,是显示自己的ip的。
Author
Owner

@wuai1024 commented on GitHub (Oct 30, 2023):

我怎么看不到这样的日志?

<!-- gh-comment-id:1784509950 --> @wuai1024 commented on GitHub (Oct 30, 2023): 我怎么看不到这样的日志?
Author
Owner

@zhixin612 commented on GitHub (Oct 30, 2023):

我怎么看不到这样的日志?

日志等级没有设对吧,debug级别才行

<!-- gh-comment-id:1784550713 --> @zhixin612 commented on GitHub (Oct 30, 2023): > 我怎么看不到这样的日志? 日志等级没有设对吧,debug级别才行
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/frp#2969
No description provided.