cloudflare / cloudflare/cloudflared

[QUESTION] Windows RDP connection fail 🐛

Open
#1,102 1 comment 0 reactions 0 assignees View on GitHub
Priority: Normal Type: Bug
Dominant language
Go
Stars
15.6k
Forks
1.4k
PR merge metrics
No merged PRs in 30d

Description

**Describe the bug**
I think this is not a bug but there is no option for just a question. Anyway here goes:

I'm trying to use the trycloudflare since i haven't purchased a domain yet.

I have to Windows 10 PCs:
On host side, i run this command:
```
cloudflared-windows-amd64.exe tunnel --url rdp://localhost:3389
```

which gives a url:
```
https://optional-archive-electric-uruguay.trycloudflare.com
```

On client side, i run this command:
```
cloudflared-windows-amd64.exe access rdp --hostname optional-archive-electric-uruguay.trycloudflare.com
```

No output was generated, it just executed then I was able to run another command like nothing happened, however, on host side:
```
2023-11-07T15:39:32Z INF Registered tunnel connection connIndex=0 connection=4f25cc7c-1637-4f67-98ba-b490adf13db8 event=0 ip=xxx.xxx.xxx.xxx location=sin13 protocol=quic
2023-11-07T15:39:36Z ERR error="dial tcp [::1]:3389: connectex: No connection could be made because the target machine actively refused it." cfRay=8226ab69409221a6-HKG event=1 originService=rdp://localhost:3389
2023-11-07T15:39:36Z ERR Request failed error="dial tcp [::1]:3389: connectex: No connection could be made because the target machine actively refused it." connIndex=0 dest=https://optional-archive-electric-uruguay.trycloudflare.com/ event=0 ip=xxx.xxx.xxx.xxx type=http
2023-11-07T15:39:37Z ERR error="dial tcp [::1]:3389: operation was canceled" cfRay=8226ab7954bb21a6-HKG event=1 originService=rdp://localhost:3389
2023-11-07T15:39:37Z ERR Request failed error="dial tcp [::1]:3389: operation was canceled" connIndex=0 dest=https://optional-archive-electric-uruguay.trycloudflare.com/favicon.ico event=0 ip=xxx.xxx.xxx.xxx type=http
2023-11-07T15:39:54Z ERR error="dial tcp [::1]:3389: connectex: No connection could be made because the target machine actively refused it." cfRay=8226abdd964eb44b-HKG event=1 originService=rdp://localhost:3389
2023-11-07T15:39:54Z ERR Request failed error="dial tcp [::1]:3389: connectex: No connection could be made because the target machine actively refused it." connIndex=0 dest=https://optional-archive-electric-uruguay.trycloudflare.com/ event=0 ip=xxx.xxx.xxx.xxx type=ws
2023-11-07T15:40:16Z ERR error="dial tcp [::1]:3389: connectex: No connection could be made because the target machine actively refused it." cfRay=8226ac64e40e0791-HKG event=1 originService=rdp://localhost:3389
2023-11-07T15:40:16Z ERR Request failed error="dial tcp [::1]:3389: connectex: No connection could be made because the target machine actively refused it." connIndex=0 dest=https://optional-archive-electric-uruguay.trycloudflare.com/ event=0 ip=xxx.xxx.xxx.xxx type=ws
2023-11-07T15:41:49Z ERR error="dial tcp [::1]:3389: connectex: No connection could be made because the target machine actively refused it." cfRay=8226aeaa513904b5-HKG event=1 originService=rdp://localhost:3389
2023-11-07T15:41:49Z ERR Request failed error="dial tcp [::1]:3389: connectex: No connection could be made because the target machine actively refused it." connIndex=0 dest=https://optional-archive-electric-uruguay.trycloudflare.com/ event=0 ip=xxx.xxx.xxx.xxx type=ws
2023-11-07T15:42:10Z ERR error="dial tcp [::1]:3389: connectex: No connection could be made because the target machine actively refused it." cfRay=8226af2b7327106d-HKG event=1 originService=rdp://localhost:3389
2023-11-07T15:42:10Z ERR Request failed error="dial tcp [::1]:3389: connectex: No connection could be made because the target machine actively refused it." connIndex=0 dest=https://optional-archive-electric-uruguay.trycloudflare.com/ event=0 ip=xxx.xxx.xxx.xxx type=ws

```

if i try and run this command on the client side:
```
cloudflared-windows-amd64.exe access rdp --hostname optional-archive-electric-uruguay.trycloudflare.com --url localhost:3389
```

The output is:
```
2023-11-07T15:56:28Z INF Start Websocket listener host=localhost:3389
2023-11-07T15:56:28Z ERR Error on Websocket listener error="failed to start forwarding server: listen tcp 127.0.0.1:3389: bind: An attempt was made to access a socket in a way forbidden by its access permissions."
failed to start forwarding server: listen tcp 127.0.0.1:3389: bind: An attempt was made to access a socket in a way forbidden by its access permissions.
```

I know based on the documentation, there should be a hostname for my domain, i'm just trying it out though.

**To Reproduce**
Steps to reproduce the behavior:
Same command as above.

If it's an issue with Cloudflare Tunnel:
No config needed.

**Expected behavior**
A clear and concise description of what you expected to happen.

**Environment and versions**
- OS: Windows 10
- Architecture: AMD

**Logs and errors**
Provided above.

**Additional context**
Add any other context about the problem here.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.