Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cloudflared tunnel via proxy #350

Closed
mcartmel opened this issue Apr 9, 2021 · 10 comments
Closed

Cloudflared tunnel via proxy #350

mcartmel opened this issue Apr 9, 2021 · 10 comments

Comments

@mcartmel
Copy link

mcartmel commented Apr 9, 2021

I see that cloudflared access has support for a proxy #317.

I'm trying to use cloudflared tunnel as well behind a corporate firewall, but this doesn't seem to support proxy? The connection attempt is always direct.

@op69qs
Copy link

op69qs commented Jun 3, 2021

same problem here

@Cnly
Copy link

Cnly commented Jul 12, 2021

Another related issue is #170. Also, 2021.7.0 has just been released and still has this problem.

@davidkarlsen
Copy link

Connecting will give this error:

2021-08-12T15:15:44Z INF Starting tunnel tunnelID=30b81b81-a872-476e-a41f-fb5631cd50f3
2021-08-12T15:15:44Z INF Version 
2021-08-12T15:15:44Z INF GOOS: linux, GOVersion: go1.16.4, GoArch: amd64
2021-08-12T15:15:44Z INF Settings: map[cred-file:/etc/cloudflared/credentials.json credentials-file:/etc/cloudflared/credentials.json no-autoupdate:true]
2021-08-12T15:15:44Z INF Generated Connector ID: fee7544b-448c-4c36-8f75-4c5be7f39f3c
2021-08-12T15:15:44Z INF Initial protocol http2
2021-08-12T15:15:44Z INF Starting metrics server on 127.0.0.1:46162/metrics
2021-08-12T15:15:59Z ERR Unable to establish connection with Cloudflare edge error="DialContext error: dial tcp 198.41.200.53:7844: i/o timeout" connIndex=0
2021-08-12T15:15:59Z INF Retrying connection in up to 2s seconds connIndex=0

@yggdrasil-tynor
Copy link

Any update on this?

@RainYang-RY
Copy link

ProxyCommand proxychains4 /usr/local/bin/cloudflared access ssh --hostname %h

Works for me.

@aatrcoutinho
Copy link

@wz1765 Please, How is your proxychains4 file configuration?

@joliveirinha
Copy link
Contributor

This is something that we don't actually want to support within cloudflared.
Furthermore, http2 transport only has a subset of features that cloudflared allows and the official transport to use should be QUIC, which wouldn't work for the SOCKS proxy.

@joaocc
Copy link

joaocc commented Sep 6, 2023

Hi.
Could you please confirm if cloudflared is not expected to work on a corp environment behind a proxy (as defined by HTTP_PROXY and HTTPS_PROXY) or, if that restriction only applies to SOCKS proxy?
Thanks

@aacoutinho
Copy link

aacoutinho commented Sep 6, 2023

After experiencing issues with Cloudflare and other services, I found a solution that worked perfectly and performed exceptionally well through a firewall:

https://github.com/FastTunnel/FastTunnel

All you need to do is set up a basic node on Google Cloud or Amazon to run the server (public IP), and then install the client on a machine within your internal network. Configuring both the server and client is straightforward in the appsettings.json file. In the client, you define the mappings for the internal machines.

@joaocc
Copy link

joaocc commented Sep 7, 2023

Thanks, I appreciate the pointer. However we were trying to understand if cloudflared would be expected to work in such a scenario, as we are not planning to move to another provider at this point.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
10 participants