RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1437569 - x0vncserver incorrectly maps keysym from vncclient running german keyboard
Summary: x0vncserver incorrectly maps keysym from vncclient running german keyboard
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: tigervnc
Version: 8.7
Hardware: All
OS: Linux
unspecified
high
Target Milestone: rc
: ---
Assignee: Jan Grulich
QA Contact: Radek Duda
URL:
Whiteboard:
Depends On:
Blocks: 2119017 2150915 2150916
TreeView+ depends on / blocked
 
Reported: 2017-03-30 14:45 UTC by Dmitry Zhukovski
Modified: 2023-05-16 09:56 UTC (History)
5 users (show)

Fixed In Version: tigervnc-1.12.0-9.el8
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 2119017 2150915 2150916 (view as bug list)
Environment:
Last Closed: 2023-05-16 08:36:47 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
xev trace from linux client where Pipe is working (6.75 KB, text/plain)
2017-04-03 09:30 UTC, Dmitry Zhukovski
no flags Details
xev trace from windows client where Pipe is not working (6.19 KB, text/plain)
2017-04-03 09:31 UTC, Dmitry Zhukovski
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker RHELPLAN-118337 0 None None None 2022-04-08 08:22:49 UTC
Red Hat Product Errata RHSA-2023:2830 0 None None None 2023-05-16 08:37:16 UTC

Description Dmitry Zhukovski 2017-03-30 14:45:05 UTC
Description of problem:
x0vncserver incorrectly maps keysym from vncclient running german keyboard

Version-Release number of selected component (if applicable):
7.3 and also tested on 7.4/fedora 25

How reproducible:


Steps to Reproduce:
1. Set Windows client to German keyboard
2. configure x0vncserver and connect to it from win client
3.

Actual results:
at least |(pipe) is not mapped anywhere

Expected results:


Additional info:
Linux to Linux works without problems.
x11vnc has -modtweak functionality that fixes it.

Comment 2 Dmitry Zhukovski 2017-04-03 09:30:36 UTC
Created attachment 1268319 [details]
xev trace from linux client where Pipe is working

Comment 3 Dmitry Zhukovski 2017-04-03 09:31:08 UTC
Created attachment 1268320 [details]
xev trace from windows client where Pipe is not working

Comment 4 Jan Grulich 2017-04-04 09:12:32 UTC
Hi,

I managed to reproduce this issue with TigerVNC client (viewer) running on windows and TigerVNC server running on Linux. I did some investigation and it appears that this is not actually a bug, but it's by designed to work this way. here is a snip of documentation about keyboard keys from TigerVNC:

- Modifiers:

  X11: You can usually toggle Hyper/Super and Compose/Scroll_Lock using
       XKB options.

  - CapsLock, NumLock (sent but ignored by server)
  - Shift, Ctrl
  - Alt, AltGr, Super [Win, X11] (FIXME: AltGr broken on Win)
  - Meta [X11]
  - Left/right identification (FIXME: broken for Shift on Win)
  - CmdL => AltL, CmdR => SuperL, AltL => ModeSwitch, AltR => Level3Shift [OS X]
  - Hyper sends Super [X11]

  - CapsLock, Shift and AltGr affect symbol lookup
  - Ctrl does not affect symbol lookup
  - CtrlL+AltR is fake released to compensate for Windows' AltGr magic [Win]
  - Ctrl+Alt+<ANY> sends the same symbol as <ANY> (note behaviour above though)
  - Ctrl+AltGr+<ANY> sends the same symbol as AltGr+<ANY> (FIXME: broken on Win)
  - "Shift press, A press, Shift release, A release" should not send "a release"

So as you can see, using Ctrl + Alt + ANY_KEY results into pressing just ANY_KEY. I don't think I can do anything about this at this moment. I also tested this with TightVNC (another vnc client) and this one is configured differently and sending Ctrl + Alt + ANY_KEY worked just fine.

Comment 5 Jan Grulich 2017-04-18 08:45:54 UTC
Source code for reference:
https://github.com/TigerVNC/tigervnc/blob/master/vncviewer/Viewport.cxx#L447

Comment 18 Jan Grulich 2022-04-26 12:11:55 UTC
I tested following:

1) Install RHEL Workstation 9 (with RHEL 8 it should be same) into GNOME Boxes
2) Disable GDM with "systemctl disable gdm.service"
3) Reboot → Login → run "startx" 
4) GNOME starts → open GNOME terminal
5) Run "vncpasswd" to setup password for VNC
6) Run "x0vncserver -Display :0 -PasswordFile=/home/jgrulich/.vnc/passwd -AlwaysShared=1"
7) Set German keyboard layout on the client
8) Run "vncviewer" for Windows using Wine and connect to the server
9) Try to type e.g. "|" with AltGr + "|" on the keyboard button next to the shift on the left side
10) Observe it doesn't type anything

Workaround:
1) Set German keyboard layout on the server
2) Run "x0vncserver -Display :0 -PasswordFile=/home/jgrulich/.vnc/passwd -AlwaysShared=1 -RawKeyboard" 
- from documentation: send keyboard events straight through and avoids mapping them to the current keyboard layout. This effectively makes the keyboard behave according to the layout configured on the server instead of the layout configured on the client.
3) Run "vncviewer" for Windows using Wine and connect to the server
4) Try to type e.g. "|" with AltGr + "|" on the keyboard button next to the shift on the left side
5) Observe it types "|" as expected

Can you try to use "-RawKeyboard" option and verify it works for you as expected?

Comment 20 Jan Grulich 2022-08-15 10:24:04 UTC
I have a fix pending upstream: https://github.com/TigerVNC/tigervnc/pull/1510

It was confirmed by the customer that this fixes the issue, I'm just waiting on feedback from upstream whether we should do it this way or whether we should hide it under an option so we don't break default behavior for other users.

Comment 22 Radek Duda 2022-12-05 13:39:41 UTC
Reproduced with old tigervnc-1.12.0-7 - cannot type '|' to vnc server

installed new tigervnc-1.12.0-8 - I can now type the '|' from Win10 client to RHEL8 vnc server

Comment 30 errata-xmlrpc 2023-05-16 08:36:47 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Moderate: tigervnc security and bug fix update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2023:2830


Note You need to log in before you can comment on or make changes to this bug.