Skip to content

KasmVNC does not correctly transmit shifted key combinations (Ctrl+Shift+Minus → underscore) #357

@dwave-chua

Description

@dwave-chua

Describe the bug
In KasmVNC version 1.4.0, I'm noticing a different behaviour in how shifted keys are passed to the remote session that I'm not seeing in KasmVNC version 1.3.4 and older.

When using KasmVNC, certain key combinations involving the Control key and the Shift modifier are not correctly interpreted on the remote host.

When pressing CTRL+SHIFT+MINUS (Or any symbol or number key along the top row), they aren't sent to the remote session as expected

System Description

$ cat /etc/os-release 
PRETTY_NAME="Debian GNU/Linux 12 (bookworm)"
NAME="Debian GNU/Linux"
VERSION_ID="12"
VERSION="12 (bookworm)"
VERSION_CODENAME=bookworm
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"
$ uname -a
Linux kasmvnc-1-4-0 6.12.31-talos #1 SMP Tue Jun 10 11:58:23 UTC 2025 x86_64 GNU/Linux

KasmVNC Details
Provide the filename of the package you installed KasmVNC with. The filename includes important details like the OS, architecture, and commit sha.

kasmvncserver_bookworm_1.4.0_amd64.deb

$ Xvnc -version

Xvnc KasmVNC 1.4.0.663b6d6a0bdd4638bff981c75a522056aaaa1c2e - built Sep 22 2025 14:47:59
Copyright (C) 1999-2018 KasmVNC Team and many others (see README.me)
See http://kasmweb.com for information on KasmVNC.
Underlying X server release 12101007

To Reproduce
Steps to reproduce the behavior (for non-installation issues):

  1. Open a KasmVNC session on version 1.4.0
  2. On Debian, open a terminal
  3. Launch xev
  4. Press CONTROL+SHIFT+MINUS
  5. Stop the key capture
  6. Review output, which will include minus key in the output

Expected behavior
In the KasmVNC session, when pressing CONTROL+SHIFT+MINUS, the expected xev output should only include the shifted key (CONTROL and UNDERSCORE), and not include the MINUS key input. This should be the case for any number or symbol pressed with CONTROL+SHIFT

Browser
If this is a problem with the KasmVNC client, provide details about the browser you are accessing KasmVNC from.

  • Device: Dell laptop
  • OS: Windows 11
  • Browser: Chrome
  • Version: 147.0.7727.55

Additional context
Add any other context about the problem here.

xev output for KasmVNC 1.3.4: This shows the xev output of the expected behaviour


KeyPress event, serial 35, synthetic NO, window 0x400001,
    root 0x519, subw 0x0, time 3540363630, (718,-165), root:(719,505),
    state 0x0, keycode 50 (keysym 0xffe1, Shift_L), same_screen YES,
    XLookupString gives 0 bytes: 
    XmbLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyPress event, serial 35, synthetic NO, window 0x400001,
    root 0x519, subw 0x0, time 3540363732, (718,-165), root:(719,505),
    state 0x1, keycode 37 (keysym 0xffe3, Control_L), same_screen YES,
    XLookupString gives 0 bytes: 
    XmbLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyPress event, serial 35, synthetic NO, window 0x400001,
    root 0x519, subw 0x0, time 3540363968, (718,-165), root:(719,505),
    state 0x5, keycode 20 (keysym 0x5f, underscore), same_screen YES,
    XLookupString gives 1 bytes: (1f) ""
    XmbLookupString gives 1 bytes: (1f) ""
    XFilterEvent returns: False

KeyRelease event, serial 35, synthetic NO, window 0x400001,
    root 0x519, subw 0x0, time 3540364054, (718,-165), root:(719,505),
    state 0x5, keycode 20 (keysym 0x5f, underscore), same_screen YES,
    XLookupString gives 1 bytes: (1f) ""
    XFilterEvent returns: False

KeyRelease event, serial 35, synthetic NO, window 0x400001,
    root 0x519, subw 0x0, time 3540364644, (718,-165), root:(719,505),
    state 0x5, keycode 50 (keysym 0xffe1, Shift_L), same_screen YES,
    XLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyRelease event, serial 35, synthetic NO, window 0x400001,
    root 0x519, subw 0x0, time 3540364644, (718,-165), root:(719,505),
    state 0x4, keycode 37 (keysym 0xffe3, Control_L), same_screen YES,
    XLookupString gives 0 bytes: 
    XFilterEvent returns: False

xev output for KasmVNC 1.4.0: This shows the xev output of the unexpected behaviour

KeyPress event, serial 35, synthetic NO, window 0x1400001,
    root 0x519, subw 0x0, time 3538299302, (673,-126), root:(674,544),
    state 0x0, keycode 50 (keysym 0xffe1, Shift_L), same_screen YES,
    XLookupString gives 0 bytes: 
    XmbLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyPress event, serial 35, synthetic NO, window 0x1400001,
    root 0x519, subw 0x0, time 3538299410, (673,-126), root:(674,544),
    state 0x1, keycode 37 (keysym 0xffe3, Control_L), same_screen YES,
    XLookupString gives 0 bytes: 
    XmbLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyRelease event, serial 35, synthetic NO, window 0x1400001,
    root 0x519, subw 0x0, time 3538299679, (673,-126), root:(674,544),
    state 0x5, keycode 50 (keysym 0xffe1, Shift_L), same_screen YES,
    XLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyPress event, serial 35, synthetic NO, window 0x1400001,
    root 0x519, subw 0x0, time 3538299679, (673,-126), root:(674,544),
    state 0x4, keycode 20 (keysym 0x2d, minus), same_screen YES,
    XLookupString gives 1 bytes: (2d) "-"
    XmbLookupString gives 1 bytes: (2d) "-"
    XFilterEvent returns: False

KeyPress event, serial 35, synthetic NO, window 0x1400001,
    root 0x519, subw 0x0, time 3538299679, (673,-126), root:(674,544),
    state 0x4, keycode 50 (keysym 0xffe1, Shift_L), same_screen YES,
    XLookupString gives 0 bytes: 
    XmbLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyRelease event, serial 35, synthetic NO, window 0x1400001,
    root 0x519, subw 0x0, time 3538299801, (673,-126), root:(674,544),
    state 0x5, keycode 20 (keysym 0x5f, underscore), same_screen YES,
    XLookupString gives 1 bytes: (1f) ""
    XFilterEvent returns: False

KeyRelease event, serial 35, synthetic NO, window 0x1400001,
    root 0x519, subw 0x0, time 3538299985, (673,-126), root:(674,544),
    state 0x5, keycode 50 (keysym 0xffe1, Shift_L), same_screen YES,
    XLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyRelease event, serial 35, synthetic NO, window 0x1400001,
    root 0x519, subw 0x0, time 3538299985, (673,-126), root:(674,544),
    state 0x4, keycode 37 (keysym 0xffe3, Control_L), same_screen YES,
    XLookupString gives 0 bytes: 
    XFilterEvent returns: False

I do not know if this is related, but I did see in the changelog for KasmVNC 1.4.0 that may relate to the issue I'm seeing: https://github.com/kasmtech/KasmVNC/releases/tag/v1.4.0

Fixed bug with Ctrl key not working on foreign language keyboards with Chromium based browsers.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions