|
|
@@ -40,52 +40,6 @@ desktop software that provides self-hosted solutions.
|
|
40
|
40
|
- Visitors are remotely to the device via a temporary sharing link
|
|
41
|
41
|
- CLI
|
|
42
|
42
|
- Reset admin password
|
|
43
|
|
-## Prerequisites
|
|
44
|
|
-
|
|
45
|
|
-### [Rustdesk](https://github.com/rustdesk/rustdesk)
|
|
46
|
|
-
|
|
47
|
|
-
|
|
48
|
|
-#### The PC client uses version ***1.3.0***, and versions ***1.2.6+*** have been tested to work.
|
|
49
|
|
-
|
|
50
|
|
-#### Solutions for PC client connection timeout or connection issues
|
|
51
|
|
-##### Connection issues or timeouts
|
|
52
|
|
-Because the server version lags behind the client version, the server does not respond to the client's `secure_tcp` request, causing the client to timeout.
|
|
53
|
|
- Relevant code can be found at `https://github.com/rustdesk/rustdesk/blob/master/src/client.rs#L322`
|
|
54
|
|
- ```rust
|
|
55
|
|
- if !key.is_empty() && !token.is_empty() {
|
|
56
|
|
- // mainly for the security of token
|
|
57
|
|
- allow_err!(secure_tcp(&mut socket, key).await);
|
|
58
|
|
- }
|
|
59
|
|
- ```
|
|
60
|
|
-
|
|
61
|
|
-As seen, when both `key` and `token` are not empty, `secure_tcp` is called, but the server does not respond, causing the client to timeout.
|
|
62
|
|
-The `secure_tcp` code is located at `https://github.com/rustdesk/rustdesk/blob/master/src/common.rs#L1203`
|
|
63
|
|
-
|
|
64
|
|
-##### Four Solutions
|
|
65
|
|
-1. Specify the key on the server.
|
|
66
|
|
- - Advantage: Simple
|
|
67
|
|
- - Disadvantage: The connection is not encrypted
|
|
68
|
|
- ```bash
|
|
69
|
|
- hbbs -r <relay-server-ip[:port]> -k <key>
|
|
70
|
|
- hbbr -k <key>
|
|
71
|
|
- ```
|
|
72
|
|
- For example
|
|
73
|
|
- ```bash
|
|
74
|
|
- hbbs -r <relay-server-ip[:port]> -k abc1234567
|
|
75
|
|
- hbbr -k abc1234567
|
|
76
|
|
- ```
|
|
77
|
|
-2. Use a system-generated key or a custom key pair on the server. If the client is already logged in, it may timeout or fail to connect. Logging out and reconnecting usually resolves the issue, and the web client does not need to log out.
|
|
78
|
|
- - Advantage: Encrypted connection
|
|
79
|
|
- - Disadvantage: Complicated operation
|
|
80
|
|
-3. Use a system-generated key or a custom key pair on the server, fork the official client code to modify `secure_tcp` to return directly, then compile using `Github Actions` and download the compiled client.
|
|
81
|
|
- Refer to [official documentation](https://rustdesk.com/docs/en/dev/build/all/)
|
|
82
|
|
- - Advantage: Encrypted connection, customizable client features, ready to use after compilation
|
|
83
|
|
- - Disadvantage: Requires forking code and compiling, which can be challenging
|
|
84
|
|
-4. Use [my forked code](https://github.com/lejianwen/rustdesk), which has already modified `secure_tcp`. You can download and use it directly from [here](https://github.com/lejianwen/rustdesk/releases)
|
|
85
|
|
- - Advantage: Code changes are viewable, compiled with `Github Actions`, encrypted connection, ready to use
|
|
86
|
|
- - Disadvantage: May not keep up with official version updates
|
|
87
|
|
-
|
|
88
|
|
-***If encryption is not a high priority, use `1`. If encryption is important, use `3` or `4`.***
|
|
89
|
43
|
|
|
90
|
44
|
## Overview
|
|
91
|
45
|
|