[GH-ISSUE #1256] questions about host_header_rewrite = 127.0.0.1 #991

Closed
opened 2026-05-05 12:38:21 -06:00 by gitea-mirror · 2 comments
Owner

Originally created by @zzjjbb on GitHub (May 23, 2019).
Original GitHub issue: https://github.com/fatedier/frp/issues/1256

Issue is only used for submiting bug report and documents typo. If there are same issues or answers can be found in documents, we will close it directly.
(为了节约时间,提高处理问题的效率,不按照格式填写的 issue 将会直接关闭。)

Use the commands below to provide key information from your environment:
You do NOT have to include this information if this is a FEATURE REQUEST

What version of frp are you using (./frpc -v or ./frps -v)?
均为0.27.0

What operating system and processor architecture are you using (go env)?
x86-64 Ubuntu16.04

Configures you used:
type = http
custom_domains = www.abc.def
use_encryption = false
use_compression = false
local_port = 8000
host_header_rewrite = 127.0.0.1
(或host_header_rewrite = localhost)

Describe the results you received:
浏览器访问后,会直接跳转到http://127.0.0.1或localhost

Describe the results you expected:
本意是希望可以转发一些原本只允许本机访问的http服务,像syncthing等。
请问正确做法该如何实现?谢谢!
另外,如果不支持这种写法,希望Example里不要给出这样的例子

Originally created by @zzjjbb on GitHub (May 23, 2019). Original GitHub issue: https://github.com/fatedier/frp/issues/1256 Issue is only used for submiting bug report and documents typo. If there are same issues or answers can be found in documents, we will close it directly. (为了节约时间,提高处理问题的效率,不按照格式填写的 issue 将会直接关闭。) Use the commands below to provide key information from your environment: You do NOT have to include this information if this is a FEATURE REQUEST **What version of frp are you using (./frpc -v or ./frps -v)?** 均为0.27.0 **What operating system and processor architecture are you using (`go env`)?** x86-64 Ubuntu16.04 **Configures you used:** type = http custom_domains = www.abc.def use_encryption = false use_compression = false local_port = 8000 host_header_rewrite = 127.0.0.1 (或host_header_rewrite = localhost) **Describe the results you received:** 浏览器访问后,会直接跳转到http://127.0.0.1或localhost **Describe the results you expected:** 本意是希望可以转发一些原本只允许本机访问的http服务,像syncthing等。 请问正确做法该如何实现?谢谢! 另外,如果不支持这种写法,希望Example里不要给出这样的例子
Author
Owner

@duanzan commented on GitHub (May 25, 2019):

不知道 你这么做意义何在 既然只允许本机访问了 那frps不可能访问的

<!-- gh-comment-id:495897512 --> @duanzan commented on GitHub (May 25, 2019): 不知道 你这么做意义何在 既然只允许本机访问了 那frps不可能访问的
Author
Owner

@fatedier commented on GitHub (Jun 4, 2019):

跳不跳转是你自己服务的问题,frp 提供的是功能,并不解决所有 web 应用相关的问题。

<!-- gh-comment-id:498538427 --> @fatedier commented on GitHub (Jun 4, 2019): 跳不跳转是你自己服务的问题,frp 提供的是功能,并不解决所有 web 应用相关的问题。
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#991
No description provided.