feat(websocket): add websocket-port for a proxy off the default port

check_ws turns a domain endpoint into ws(s)://<domain>/ws/id or
/ws/relay with no port, so a reverse proxy that cannot take 443 (or 80)
is unreachable, even when api-server already points at it, for example
https://example.com:8443.

websocket-port adds that port for the hosts this client is configured
with: custom-rendezvous-server and relay-server. A relay that hbbs hands
out on another host, or a peer's server, keeps the default port, since
another machine has its own proxy. IP endpoints are unchanged, and an
empty option gives the same URL as before.

https://github.com/rustdesk/rustdesk-server-pro/discussions/1029

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
rustdeskandClaude Opus 5.5 committed 2026-10-22 16:05:24 +08:00
1 parent ed07431021
commit 34846eef9f
2 files changed
+60 -1

No files matched your search

+1
View File
@@ -2869,6 +2869,7 @@ pub mod keys {
pub const OPTION_ALLOW_NUMERNIC_ONE_TIME_PASSWORD: &str = "allow-numeric-one-time-password";
pub const OPTION_DIRECT_SERVER: &str = "direct-server";
pub const OPTION_ALLOW_WEBSOCKET: &str = "allow-websocket";
pub const OPTION_WEBSOCKET_PORT: &str = "websocket-port";
pub const OPTION_TRACKPAD_SPEED: &str = "trackpad-speed";
pub const OPTION_REGISTER_DEVICE: &str = "register-device";
pub const OPTION_RELAY_SERVER: &str = "relay-server";