rustdesk / rustdesk-server

RustDesk Server Program

Home Page:https://rustdesk.com/server

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Linux Server - RustDesk Server - Key Mismatch

marcoczen opened this issue · comments

Guys,

I followed instructions from

https://rustdesk.com/docs/en/self-host/rustdesk-server-oss/install/

for the installation.

Relevant ports at the firewall ( pfsense ) are opened.
No UFW on the server.
Nmap from WAN confirms that the ports are open.

Server processes are;

ps -ef | grep /opt
root      2178     1  0 Feb05 ?        00:00:00 /opt/gohttp/gohttpserver -r ./public --port 8000 --auth-type http --auth-http admin:8xnHKk8gD5oV9M8m
root      6188     1  0 20:49 ?        00:00:00 /opt/rustdesk/hbbs -k _
root      6213     1  0 20:49 ?        00:00:00 /opt/rustdesk/hbbr -k _

But when I ( Linux laptop ) try to connect to a remote client ( Windows laptop ) - It says Key Mismatch

Pls note that during the installation, no public key was generated as shown below;

  Your IP/DNS Address is rustdesk.somedomain.net

  Your public key is  

  Install Rustdesk on your machines and change your public key and IP/DNS name to the above
  You can access your install scripts for clients by going to http://rustdesk.somedomain.net:8000
  Username is admin and password is xxxxxxxxxxxxxxxxxxxxxxx

So how do I troubleshoot / proceed ?

a.) Why were the public keys not generated ?
b.) Proceed With Keys
c.) Proceed without keys ?

The documentation is pretty bad and misses a lot of important points.

First, never use the -k _ parameter because that makes rustdesk run without any protection, it will accept any key (or an empty key?)

When running without -k, both hbbs and hbbr should generate a key in the same directory. If the two executables are placed in the same directory with each other, then they will share the same key (otherwise you'd get different keys and nothing would work).

I hope the above gives you some clarity.

Noted.

So I shouldnt use -k _ ? What is the replacement ? How do i get hbbs and hbbr to accepts keys ?
Also - I have reinstalled rustdesk and the private key / pub key appeared.

There is no need to make adjustments, the two daemons hbbs/hbbr will automatically load the key from the current directory!

If you like, you can take a look at my systemd service scripts that I posted here: #365

Thanks !
Closed.