mirror of
https://github.com/rustdesk/rustdesk.git
synced 2026-03-02 19:26:56 -05:00
Connection Problem with dual stack IPv4 / IPv6 server #2921
Labels
No labels
bug
documentation
duplicate
enhancement
enhancement
enhancement
good first issue
help wanted
invalid
question
unreproducible
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/rustdesk-rustdesk#2921
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @admin-igpm on GitHub (Aug 19, 2024).
Bug Description
I have a self-hosted rustdesk server, which has a dual stack network connection (IPv4 and IPv6 address).
Usuallly I get a 'Connection Ready' when I connect with a client to the server.
But there is at least one Internet Service Provider in germany, where I have problems getting the green 'Connection ready'
status. This ISP has a IPv6 only network, where a ds-lite connection setup is used to connect to the IPv4 world.
When I disable the IPv6 protocol on the server side, the connection gets ready from the client on this ISP.
So I think, the problem with the dual-stack is, that somewhere in setting up the connection the client switches to a IPv6 connection, instead of using / staying with the IPv4 connection.
On initializing the connection, the client on this ISP uses the IPv4 dns IP address (this I can see in the logs on the server).
But then the client gets stuck, when at some time during the connection setup it switches to the IPv6 dns entry.
This is, because the IPv6 connection to the server is not working on this ISP.
I tested this with using a IPv6 only server. When using IPv6 only, I did not see a connection setup from the client.
Is it possible to modify the client code, so that only one protocol type (either IPv4 or IPv6) is used to connect to the
dual stack server?
My current workaround is to use a second dns entry for the server, which only has the IPv4 address.
Serverversion is 1.11.1
Client version is 1.2.7
How to Reproduce
When you have a dualstack IPv4 / IPv6 server and a dual stack IPv4 / IPv6 client and you try to connect from the
client to the server, and you do a tcpdump on the server, you will see both client IP-addresses (IPv4 and IPv6)
in the dump.
Expected Behavior
For the dualstack servers, maybe it would be possible, to program the client in that way, that first,
it will try to connect with the IPv6 address only, and if that is not successful tries to connect with the IPv4 address only
(or the other way round).
Operating system(s) on local side and remote side
Windows 11 client or Ubuntu linux client - Linux server
RustDesk Version(s) on local side and remote side
1.2.7 - 1.11.1
Screenshots
Here is an example dump of setting up the connection on dualstack server / dualstack client
client version 1.2.7 on ubuntu linux and server version 1.11.1
12:11:13.450939 IP IPv4.client.address.42204 > dualstack.rustdesk.server.21114: Flags ...
12:11:13.450957 IP dualstack.rustdesk.server.21114 > IPv4.client.address.42204: Flags ...
12:11:13.453570 IP IPv4.client.address.42206 > dualstack.rustdesk.server.21114: Flags ...
12:11:13.453588 IP dualstack.rustdesk.server.21114 > IPv4.client.address.42206: Flags ...
12:11:11.665813 IP6 IPv6.client.address.35943 > dualstack.rustdesk.server.21116: Flags ...
12:11:11.665842 IP6 dualstack.rustdesk.server.21116 > IPv6.client.address.35943: Flags ...
12:11:11.666176 IP6 IPv6.client.address.35943 > dualstack.rustdesk.server.21116: Flags ...
12:11:11.675098 IP6 IPv6.client.address.58456 > dualstack.rustdesk.server.21116: Flags ...
12:11:11.675127 IP6 dualstack.rustdesk.server.21116 > IPv6.client.address.58456: Flags ...
12:11:11.675686 IP6 IPv6.client.address.58456 > dualstack.rustdesk.server.21116: Flags ...
12:11:11.675687 IP6 IPv6.client.address.58456 > dualstack.rustdesk.server.21116: Flags ...
12:11:11.675951 IP6 dualstack.rustdesk.server.21116 > IPv6.client.address.58456: Flags ...
12:11:11.676333 IP6 IPv6.client.address.58456 > dualstack.rustdesk.server.21116: Flags ...
12:11:11.682961 IP6 IPv6.client.address.35943 > dualstack.rustdesk.server.21116: Flags ...
12:11:11.682995 IP6 dualstack.rustdesk.server.21116 > IPv6.client.address.35943: Flags ...
12:11:11.683103 IP6 dualstack.rustdesk.server.21116 > IPv6.client.address.35943: Flags ...
12:11:11.683128 IP6 dualstack.rustdesk.server.21116 > IPv6.client.address.35943: Flags ...
12:11:11.683575 IP6 IPv6.client.address.35943 > dualstack.rustdesk.server.21116: Flags ...
12:11:11.692416 IP6 IPv6.client.address.51054 > dualstack.rustdesk.server.21116: UDP, length 15
12:11:11.692588 IP6 dualstack.rustdesk.server.21116 > IPv6.client.address.51054: UDP, length 2
12:11:11.708441 IP6 IPv6.client.address.35943 > dualstack.rustdesk.server.21115: Flags ...
12:11:11.708469 IP6 dualstack.rustdesk.server.21115 > IPv6.client.address.35943: Flags ...
12:11:11.709021 IP6 IPv6.client.address.35943 > dualstack.rustdesk.server.21115: Flags ...
12:11:11.709022 IP6 IPv6.client.address.35943 > dualstack.rustdesk.server.21115: Flags ...
12:11:11.709072 IP6 dualstack.rustdesk.server.21115 > IPv6.client.address.35943: Flags ...
12:11:11.709290 IP6 dualstack.rustdesk.server.21115 > IPv6.client.address.35943: Flags ...
12:11:11.709308 IP6 dualstack.rustdesk.server.21115 > IPv6.client.address.35943: Flags ...
12:11:11.709722 IP6 IPv6.client.address.35943 > dualstack.rustdesk.server.21115: Flags ...
12:11:11.709723 IP6 IPv6.client.address.35943 > dualstack.rustdesk.server.21115: Flags ...
12:11:11.709750 IP6 dualstack.rustdesk.server.21115 > IPv6.client.address.35943: Flags ...
12:11:11.711111 IP6 IPv6.client.address.35943 > dualstack.rustdesk.server.21116: Flags ...
12:11:11.711135 IP6 dualstack.rustdesk.server.21116 > IPv6.client.address.35943: Flags ...
12:11:12.116195 IP6 IPv6.client.address.37657 > dualstack.rustdesk.server.21115: Flags ...
12:11:12.116224 IP6 dualstack.rustdesk.server.21115 > IPv6.client.address.37657: Flags ...
12:11:12.116649 IP6 IPv6.client.address.37657 > dualstack.rustdesk.server.21115: Flags ...
12:11:12.116650 IP6 IPv6.client.address.37657 > dualstack.rustdesk.server.21115: Flags ...
12:11:12.116702 IP6 dualstack.rustdesk.server.21115 > IPv6.client.address.37657: Flags ...
12:11:12.116928 IP6 dualstack.rustdesk.server.21115 > IPv6.client.address.37657: Flags ...
12:11:12.116948 IP6 dualstack.rustdesk.server.21115 > IPv6.client.address.37657: Flags ...
12:11:12.117348 IP6 IPv6.client.address.37657 > dualstack.rustdesk.server.21115: Flags ...
12:11:12.117349 IP6 IPv6.client.address.37657 > dualstack.rustdesk.server.21115: Flags ...
12:11:12.117367 IP6 dualstack.rustdesk.server.21115 > IPv6.client.address.37657: Flags ...
12:11:13.445048 IP6 IPv6.client.address.58320 > dualstack.rustdesk.server.21114: Flags ...
12:11:13.445066 IP6 dualstack.rustdesk.server.21114 > IPv6.client.address.58320: Flags ...
12:11:13.453053 IP6 IPv6.client.address.58334 > dualstack.rustdesk.server.21114: Flags ...
12:11:13.453070 IP6 dualstack.rustdesk.server.21114 > IPv6.client.address.58334: Flags ...
Additional Context
No response
@rustdesk commented on GitHub (Aug 19, 2024):
#763