[GH-ISSUE #4744] not routing local http server with ssh command #3749

Closed
opened 2026-05-05 14:24:05 -06:00 by gitea-mirror · 2 comments
Owner

Originally created by @itsKV on GitHub (Apr 6, 2025).
Original GitHub issue: https://github.com/fatedier/frp/issues/4744

Bug Description

I am using ssh gateway of frps to proxy local server to frps. Following is the ssh command I am executing on local machine...

ssh -R :8080:localhost:80 sub.domain.tld -p 2200 http --proxy_name proxy -t 12345678 -u user --custom_domain random

I can confirm that domain dns configuration is correct as random.sub.domain.tld is replying frp's default 404 error while accessing random proxy. Otherwise, that would trigger my web-server's default 404 error file. When I try to access the url, I am getting following error in frps log file

[httputil/reverseproxy.go:486] do http proxy request [host: random.sub.domain.tld:8080] error: no route found: random.sub.domain.tld:8080 /

And I am not getting any traffic on web server of local machine. Server log says that. That means frp is not hitting my local web server which I am trying to proxy onto frps using frpc

Also, is there any exhaustive list of ssh switches frps is using? I couldn't find all the switches in available documentations. Also, --help show very few switches to use with frps

frpc Version

0.61.2

frps Version

0.61.2

System Architecture

linux/arm64

Configurations

#frps.toml
bindAddr = "0.0.0.0"
bindPort = 1777
kcpBindPort = 1777

webServer.addr = "127.0.0.1"
webServer.port = 7500
webServer.user = "adm"
webServer.password = "adm"
webServer.pprofEnable = true

vhostHTTPPort = 8080

auth.method = "token"
auth.token = "12345678"

subDomainHost = "sub.domain.tld"

sshTunnelGateway.bindPort = 2200

Logs

No response

Steps to reproduce

  1. Run any http web server on client machine.
  2. Run ssh command as shown in the description.
  3. Try accessing url from third machine using any web browser.
    ...

Affected area

  • Docs
  • Installation
  • Performance and Scalability
  • Security
  • User Experience
  • Test and Release
  • Developer Infrastructure
  • Client Plugin
  • Server Plugin
  • Extensions
  • Others
Originally created by @itsKV on GitHub (Apr 6, 2025). Original GitHub issue: https://github.com/fatedier/frp/issues/4744 ### Bug Description I am using ssh gateway of frps to proxy local server to frps. Following is the ssh command I am executing on local machine... `ssh -R :8080:localhost:80 sub.domain.tld -p 2200 http --proxy_name proxy -t 12345678 -u user --custom_domain random` I can confirm that domain dns configuration is correct as `random.sub.domain.tld` is replying frp's default 404 error while accessing random proxy. Otherwise, that would trigger my web-server's default 404 error file. When I try to access the url, I am getting following error in frps log file `[httputil/reverseproxy.go:486] do http proxy request [host: random.sub.domain.tld:8080] error: no route found: random.sub.domain.tld:8080 /` And I am not getting any traffic on web server of local machine. Server log says that. That means frp is not hitting my local web server which I am trying to proxy onto frps using frpc **Also, is there any exhaustive list of ssh switches frps is using? I couldn't find all the switches in available documentations. Also, --help show very few switches to use with frps** ### frpc Version 0.61.2 ### frps Version 0.61.2 ### System Architecture linux/arm64 ### Configurations ``` #frps.toml bindAddr = "0.0.0.0" bindPort = 1777 kcpBindPort = 1777 webServer.addr = "127.0.0.1" webServer.port = 7500 webServer.user = "adm" webServer.password = "adm" webServer.pprofEnable = true vhostHTTPPort = 8080 auth.method = "token" auth.token = "12345678" subDomainHost = "sub.domain.tld" sshTunnelGateway.bindPort = 2200 ``` ### Logs _No response_ ### Steps to reproduce 1. Run any http web server on client machine. 2. Run ssh command as shown in the description. 3. Try accessing url from third machine using any web browser. ... ### Affected area - [x] Docs - [x] Installation - [ ] Performance and Scalability - [ ] Security - [ ] User Experience - [ ] Test and Release - [ ] Developer Infrastructure - [ ] Client Plugin - [ ] Server Plugin - [ ] Extensions - [ ] Others
gitea-mirror 2026-05-05 14:24:05 -06:00
Author
Owner

@itsKV commented on GitHub (Apr 12, 2025):

Additionally, after starting proxy from client, running curl random.localhost:8080 directly on server also giving same output. Following is the frps log.

2025-04-12 08:47:41.410 [W] [httputil/reverseproxy.go:486] do http proxy request [host: test-http.localhost:8080] error: no route found: test-http.localhost /

Using same config via frpc client works well and that can serve web file.

<!-- gh-comment-id:2798789457 --> @itsKV commented on GitHub (Apr 12, 2025): Additionally, after starting proxy from client, running `curl random.localhost:8080` directly on server also giving same output. Following is the frps log. `2025-04-12 08:47:41.410 [W] [httputil/reverseproxy.go:486] do http proxy request [host: test-http.localhost:8080] error: no route found: test-http.localhost /` Using same config via frpc client works well and that can serve web file.
Author
Owner

@github-actions[bot] commented on GitHub (May 3, 2025):

Issues go stale after 14d of inactivity. Stale issues rot after an additional 3d of inactivity and eventually close.

<!-- gh-comment-id:2848320161 --> @github-actions[bot] commented on GitHub (May 3, 2025): Issues go stale after 14d of inactivity. Stale issues rot after an additional 3d of inactivity and eventually close.
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#3749
No description provided.