GUACAMOLE-381: Disable inbound clipboard transfer if "disable-paste" is set.
This commit is contained in:
parent
7d2b7126db
commit
993d5c5707
@ -79,9 +79,12 @@ int guac_kubernetes_user_join_handler(guac_user* user, int argc, char** argv) {
|
|||||||
/* Only handle events if not read-only */
|
/* Only handle events if not read-only */
|
||||||
if (!settings->read_only) {
|
if (!settings->read_only) {
|
||||||
|
|
||||||
/* General mouse/keyboard/clipboard events */
|
/* General mouse/keyboard events */
|
||||||
user->key_handler = guac_kubernetes_user_key_handler;
|
user->key_handler = guac_kubernetes_user_key_handler;
|
||||||
user->mouse_handler = guac_kubernetes_user_mouse_handler;
|
user->mouse_handler = guac_kubernetes_user_mouse_handler;
|
||||||
|
|
||||||
|
/* Inbound (client to server) clipboard transfer */
|
||||||
|
if (!settings->disable_paste)
|
||||||
user->clipboard_handler = guac_kubernetes_clipboard_handler;
|
user->clipboard_handler = guac_kubernetes_clipboard_handler;
|
||||||
|
|
||||||
/* STDIN redirection */
|
/* STDIN redirection */
|
||||||
|
@ -97,9 +97,12 @@ int guac_rdp_user_join_handler(guac_user* user, int argc, char** argv) {
|
|||||||
/* Only handle events if not read-only */
|
/* Only handle events if not read-only */
|
||||||
if (!settings->read_only) {
|
if (!settings->read_only) {
|
||||||
|
|
||||||
/* General mouse/keyboard/clipboard events */
|
/* General mouse/keyboard events */
|
||||||
user->mouse_handler = guac_rdp_user_mouse_handler;
|
user->mouse_handler = guac_rdp_user_mouse_handler;
|
||||||
user->key_handler = guac_rdp_user_key_handler;
|
user->key_handler = guac_rdp_user_key_handler;
|
||||||
|
|
||||||
|
/* Inbound (client to server) clipboard transfer */
|
||||||
|
if (!settings->disable_paste)
|
||||||
user->clipboard_handler = guac_rdp_clipboard_handler;
|
user->clipboard_handler = guac_rdp_clipboard_handler;
|
||||||
|
|
||||||
/* Display size change events */
|
/* Display size change events */
|
||||||
|
@ -80,9 +80,12 @@ int guac_ssh_user_join_handler(guac_user* user, int argc, char** argv) {
|
|||||||
/* Only handle events if not read-only */
|
/* Only handle events if not read-only */
|
||||||
if (!settings->read_only) {
|
if (!settings->read_only) {
|
||||||
|
|
||||||
/* General mouse/keyboard/clipboard events */
|
/* General mouse/keyboard events */
|
||||||
user->key_handler = guac_ssh_user_key_handler;
|
user->key_handler = guac_ssh_user_key_handler;
|
||||||
user->mouse_handler = guac_ssh_user_mouse_handler;
|
user->mouse_handler = guac_ssh_user_mouse_handler;
|
||||||
|
|
||||||
|
/* Inbound (client to server) clipboard transfer */
|
||||||
|
if (!settings->disable_paste)
|
||||||
user->clipboard_handler = guac_ssh_clipboard_handler;
|
user->clipboard_handler = guac_ssh_clipboard_handler;
|
||||||
|
|
||||||
/* STDIN redirection */
|
/* STDIN redirection */
|
||||||
|
@ -79,9 +79,12 @@ int guac_telnet_user_join_handler(guac_user* user, int argc, char** argv) {
|
|||||||
/* Only handle events if not read-only */
|
/* Only handle events if not read-only */
|
||||||
if (!settings->read_only) {
|
if (!settings->read_only) {
|
||||||
|
|
||||||
/* General mouse/keyboard/clipboard events */
|
/* General mouse/keyboard events */
|
||||||
user->key_handler = guac_telnet_user_key_handler;
|
user->key_handler = guac_telnet_user_key_handler;
|
||||||
user->mouse_handler = guac_telnet_user_mouse_handler;
|
user->mouse_handler = guac_telnet_user_mouse_handler;
|
||||||
|
|
||||||
|
/* Inbound (client to server) clipboard transfer */
|
||||||
|
if (!settings->disable_paste)
|
||||||
user->clipboard_handler = guac_telnet_clipboard_handler;
|
user->clipboard_handler = guac_telnet_clipboard_handler;
|
||||||
|
|
||||||
/* STDIN redirection */
|
/* STDIN redirection */
|
||||||
|
@ -91,9 +91,12 @@ int guac_vnc_user_join_handler(guac_user* user, int argc, char** argv) {
|
|||||||
/* Only handle events if not read-only */
|
/* Only handle events if not read-only */
|
||||||
if (!settings->read_only) {
|
if (!settings->read_only) {
|
||||||
|
|
||||||
/* General mouse/keyboard/clipboard events */
|
/* General mouse/keyboard events */
|
||||||
user->mouse_handler = guac_vnc_user_mouse_handler;
|
user->mouse_handler = guac_vnc_user_mouse_handler;
|
||||||
user->key_handler = guac_vnc_user_key_handler;
|
user->key_handler = guac_vnc_user_key_handler;
|
||||||
|
|
||||||
|
/* Inbound (client to server) clipboard transfer */
|
||||||
|
if (!settings->disable_paste)
|
||||||
user->clipboard_handler = guac_vnc_clipboard_handler;
|
user->clipboard_handler = guac_vnc_clipboard_handler;
|
||||||
|
|
||||||
#ifdef ENABLE_COMMON_SSH
|
#ifdef ENABLE_COMMON_SSH
|
||||||
|
Loading…
Reference in New Issue
Block a user