XRDP uses wrong (old?) Xorg keycodes
Closed this issue · 15 comments
For example, left arrow (RDP 75, extended) is mapped as 100. However, xev reports that Xorg is using 113 for it. I don't know if it's specific to hardware, architecture or X11 version. But the result is that keymap created by genkeymap doesn't work correctly with xrdp — has mis-mapped keys.
I also don't have a good solution here. In any case, I don't think we can use keycodes reliably.
This is the evdev vs base rules in xkb.
Most linux system use evdev now.
You can see the info by typeing
setxkbmap -query
vnc servers use the base rules mapping
All this doesn't matter if X11rdp is used.
Any suggestion on possible improvement? evdev->xfree86 mapping in genkeymap?
The problem is that Xvnc uses base, not evdev.
We can switch in xrdp but Xvnc sessions wont work.
I actually want to remove support for Xvnc session entirely.
Is there any documentation on how to build X11rdp?
See documentation at
http://www.xrdp.org/index.php?option=com_content&view=category&id=2&Itemid=7
Another great choice is to use xrdp-o-matic from scarygliders.net f you are using debian or ubuntu
Jay
As far as I understand, X11rdp requires building patched half-of-Xorg. This is nowhere near acceptable for us.
Unfortunately, this is what you get when you run Xvnc too.
A completely separate Xorg with all of it's separate security issues.
One solution I'm working on is an Xorg driver for xrdp that uses the Xorg on your system.
This will be much easier to build as you just build the driver.
Package maintainers and security groups will be much happier too.
Yes, the xorg driver would be awesome.
I have tried building x11rdp but so far with no success. It certainly doesn't build against any modern xorg-server, and with 1.9.3 I get:
rdpComposite.c: In function ‘compsoite_print’:
rdpComposite.c:245:56: error: ‘struct _Picture’ has no member named ‘dither’
pSrc->repeat, pSrc->repeatType, pSrc->dither, pSrc->filter,
^
rdpComposite.c:31:41: note: in definition of macro ‘LLOGLN’
do { if (_level < LOG_LEVEL) { ErrorF _args ; ErrorF("\n"); } } while (0)
^
rdpComposite.c:282:56: error: ‘struct _Picture’ has no member named ‘dither’
pDst->repeat, pDst->repeatType, pDst->dither, pDst->filter,
^
rdpComposite.c:31:41: note: in definition of macro ‘LLOGLN’
do { if (_level < LOG_LEVEL) { ErrorF _args ; ErrorF("\n"); } } while (0)
^
But this may be related to mixing old xorg-server with newer Xorg libraries.
Even after hacking all my way through it, it requires old Xorg server modules and it's basically a no-go for us. In comparison, tigervnc is constantly being patched to work with current Xorg versions…
You should have a look at rdp driver for xorg, I've added a page in the wiki for its usage. It's really fast to test: RDP driver for xorg
It is possible to use a new Xorg. I have a branch in my repo that links (shared libs) the existing X11 install and only adds a 1.4Mb binary to bootstrap the thing (the code from Jay). So patches on the x11 code will be automatically fixed in x11rdp as well. I am running on quite some machines daily development work with abt 200+ devs.
So I've been finally able to build X11rdp with some hackery. Sadly, it's even worse than Xvnc. It seems that any altgr+letter keypress is causing a noticeable lag, and if followed by any other keypresses often results in missing characters in output.
I will try the Xorg drivers now :).
Ok, the Xorg drivers have the same issues as X11rdp — altgr causes awful lag. It has also has an extra feature of bringing down my local Xorg on remote session logout :).
Thanks for all the help. Since underlying issue is resolved now, I've opened Pull Request #180 that brings conditional evdev support to genkeymap. This way, it's possible to generate correct keymaps on systems using evdev.
Just to clear the record.
TigerVNC 1.3.0 uses xorg 1.7.7.
X11rdp uses 1.9.3, a new version.
If you use TigerVNC you are using a totally separate Xorg than what's installed on your system.
X11rdp does work with new version of Xorg including the latest version 1.15.x
X11rdp is not a "patched" Xorg, it's just a DDX build of Xorg to use the RDP DDX
None of the Xorg is patched other than to just get them to build.
I agree that Xorg driver is the best model but X11rdp is not less secure than tigerVNC, tightVNC or any X11 VNC that I know about.
Note, tightVNC(vnc4server) installed from my Debian 7 system(from apt-get) is based on XFree86 4.3!
Remember that?