From f8fbf40f987c0cc20c7dc9b9e2ebeb9ad95f0c65 Mon Sep 17 00:00:00 2001 From: Adwin White Date: Sun, 16 Feb 2025 18:18:58 +0800 Subject: [PATCH 1/4] feat: add camera connection type --- protos/message.proto | 3 +++ protos/rendezvous.proto | 1 + 2 files changed, 4 insertions(+) diff --git a/protos/message.proto b/protos/message.proto index 55b5650..565d360 100644 --- a/protos/message.proto +++ b/protos/message.proto @@ -62,6 +62,8 @@ message FileTransfer { bool show_hidden = 2; } +message ViewCamera {} + message OSLogin { string username = 1; string password = 2; @@ -76,6 +78,7 @@ message LoginRequest { oneof union { FileTransfer file_transfer = 7; PortForward port_forward = 8; + ViewCamera view_camera = 15; } bool video_ack_required = 9; uint64 session_id = 10; diff --git a/protos/rendezvous.proto b/protos/rendezvous.proto index 2fc0d90..b9b8ed7 100644 --- a/protos/rendezvous.proto +++ b/protos/rendezvous.proto @@ -11,6 +11,7 @@ enum ConnType { FILE_TRANSFER = 1; PORT_FORWARD = 2; RDP = 3; + VIEW_CAMERA = 4; } message RegisterPeerResponse { bool request_pk = 2; } From 478db34b29b72a57c29f365ea3ea8b4946bafc04 Mon Sep 17 00:00:00 2001 From: Adwin White Date: Sun, 16 Feb 2025 18:20:10 +0800 Subject: [PATCH 2/4] feat: add config option for camera --- src/config.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/config.rs b/src/config.rs index ce4e89d..7e29120 100644 --- a/src/config.rs +++ b/src/config.rs @@ -2212,6 +2212,7 @@ pub mod keys { pub const OPTION_ENABLE_KEYBOARD: &str = "enable-keyboard"; pub const OPTION_ENABLE_CLIPBOARD: &str = "enable-clipboard"; pub const OPTION_ENABLE_FILE_TRANSFER: &str = "enable-file-transfer"; + pub const OPTION_ENABLE_CAMERA: &str = "enable-camera"; pub const OPTION_ENABLE_AUDIO: &str = "enable-audio"; pub const OPTION_ENABLE_TUNNEL: &str = "enable-tunnel"; pub const OPTION_ENABLE_REMOTE_RESTART: &str = "enable-remote-restart"; @@ -2362,6 +2363,7 @@ pub mod keys { OPTION_ENABLE_KEYBOARD, OPTION_ENABLE_CLIPBOARD, OPTION_ENABLE_FILE_TRANSFER, + OPTION_ENABLE_CAMERA, OPTION_ENABLE_AUDIO, OPTION_ENABLE_TUNNEL, OPTION_ENABLE_REMOTE_RESTART, From 4b161a2050f18d22c00ed93c42a9c924d5b59607 Mon Sep 17 00:00:00 2001 From: Adwin White Date: Sat, 15 Feb 2025 17:40:57 +0800 Subject: [PATCH 3/4] feat: add camera permission --- protos/message.proto | 2 ++ 1 file changed, 2 insertions(+) diff --git a/protos/message.proto b/protos/message.proto index 565d360..741d24d 100644 --- a/protos/message.proto +++ b/protos/message.proto @@ -606,6 +606,7 @@ message PermissionInfo { Restart = 5; Recording = 6; BlockInput = 7; + Camera = 8; } Permission permission = 1; @@ -663,6 +664,7 @@ message OptionMessage { // starting from 15 please, do not use removed fields BoolOption follow_remote_cursor = 15; BoolOption follow_remote_window = 16; + BoolOption disable_camera = 17; } message TestDelay { From 895024221ed76b9980469d312e16b863e144e822 Mon Sep 17 00:00:00 2001 From: RustDesk <71636191+rustdesk@users.noreply.github.com> Date: Thu, 20 Feb 2025 01:12:25 +0800 Subject: [PATCH 4/4] Update message.proto --- protos/message.proto | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/protos/message.proto b/protos/message.proto index 741d24d..6507bf2 100644 --- a/protos/message.proto +++ b/protos/message.proto @@ -78,7 +78,7 @@ message LoginRequest { oneof union { FileTransfer file_transfer = 7; PortForward port_forward = 8; - ViewCamera view_camera = 15; + ViewCamera view_camera = 9; } bool video_ack_required = 9; uint64 session_id = 10;