[GH-ISSUE #3842] [Feature Request] 不懂网络,请教下关于连接加密的问题 #3052

Closed
opened 2026-05-05 13:58:34 -06:00 by gitea-mirror · 2 comments
Owner

Originally created by @Buliet on GitHub (Dec 13, 2023).
Original GitHub issue: https://github.com/fatedier/frp/issues/3842

Describe the feature request

首先感谢作者大大提供这么给力的工具,让内网穿透如此顺畅

但在连接加密方面,有点疑问,请路过的大佬帮忙看看,万分感谢

所用设备:公司主机A作为访问端,公网服务器B作为frps服务端,家庭网络C作为frpc客户端

  1. 在C中设定 http 代理,配置如下,此时通过A访问时,B和C之间的连接是否加密
    proxies
    name = "web"
    type = "http"
    localPort = 80
    customDomains = ["www.yourdomain.com"]

  2. 在C中设定 http 代理,配置如下,此时通过A访问时,B和C之间的连接加密是通过何种方式,强度如何
    proxies
    name = "web"
    type = "http"
    localPort = 80
    customDomains = ["www.yourdomain.com"]
    transport.useEncryption = true

  3. 在C中设定 https 代理,配置如下,此时通过A访问时,B和C之间的连接是否加密
    proxies
    name = "test_htts2http"
    type = "https"
    customDomains = ["test.yourdomain.com"]
    [proxies.plugin]
    type = "https2http"
    localAddr = "127.0.0.1:80"
    crtPath = "./server.crt"
    keyPath = "./server.key"
    hostHeaderRewrite = "127.0.0.1"
    requestHeaders.set.x-from-where = "frp"

Describe alternatives you've considered

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 @Buliet on GitHub (Dec 13, 2023). Original GitHub issue: https://github.com/fatedier/frp/issues/3842 ### Describe the feature request 首先感谢作者大大提供这么给力的工具,让内网穿透如此顺畅 但在连接加密方面,有点疑问,请路过的大佬帮忙看看,万分感谢 所用设备:公司主机A作为访问端,公网服务器B作为frps服务端,家庭网络C作为frpc客户端 1. 在C中设定 **http** 代理,配置如下,此时通过A访问时,B和C之间的连接是否加密 [[proxies]] name = "web" type = "http" localPort = 80 customDomains = ["www.yourdomain.com"] 2. 在C中设定 **http** 代理,配置如下,此时通过A访问时,B和C之间的连接加密是通过何种方式,强度如何 [[proxies]] name = "web" type = "http" localPort = 80 customDomains = ["www.yourdomain.com"] **transport.useEncryption = true** 3. 在C中设定 **https** 代理,配置如下,此时通过A访问时,B和C之间的连接是否加密 [[proxies]] name = "test_htts2http" type = "https" customDomains = ["test.yourdomain.com"] [proxies.plugin] type = "https2http" localAddr = "127.0.0.1:80" crtPath = "./server.crt" keyPath = "./server.key" hostHeaderRewrite = "127.0.0.1" requestHeaders.set.x-from-where = "frp" ### Describe alternatives you've considered _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 (Dec 13, 2023):

frp的加密是指 C(frpc) 与 B(frps) 之间的,与A无关(因为A上未使用frp)。
1、B和C 默认开起了TLS加密;A与B http未加密
2、B和C 默认开起了TLS加密,且代理开启了transport.useEncryption,进行了两次加密(没必要,浪费资源);A与B http未加密
3、B和C 默认开起了TLS加密,且代理的转换的https本身也是加密的;A与B https本身加密
第3种方式比较安全,因为A访问B用的加密的https。
更安全的方式是A上也装个frpc,采用 stcp 方式访问。
参看:https://gofrp.org/zh-cn/docs/features/common/network/

<!-- gh-comment-id:1854012776 --> @superzjg commented on GitHub (Dec 13, 2023): frp的加密是指 C(frpc) 与 B(frps) 之间的,与A无关(因为A上未使用frp)。 1、B和C 默认开起了TLS加密;A与B http未加密 2、B和C 默认开起了TLS加密,且代理开启了transport.useEncryption,进行了两次加密(没必要,浪费资源);A与B http未加密 3、B和C 默认开起了TLS加密,且代理的转换的https本身也是加密的;A与B https本身加密 第3种方式比较安全,因为A访问B用的加密的https。 更安全的方式是A上也装个frpc,采用 stcp 方式访问。 参看:https://gofrp.org/zh-cn/docs/features/common/network/
Author
Owner

@Buliet commented on GitHub (Dec 13, 2023):

@superzjg
感谢大佬 清晰明了的回复,完美且直接解答了所提出的疑问
这甚至是发生在官方已经提供了相关的文档说明的情况下
再次感谢如此耐心地回复

<!-- gh-comment-id:1854061650 --> @Buliet commented on GitHub (Dec 13, 2023): @superzjg 感谢大佬 清晰明了的回复,完美且直接解答了所提出的疑问 这甚至是发生在官方已经提供了相关的文档说明的情况下 再次感谢如此耐心地回复
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#3052
No description provided.