Skip to content

desktop RDP works but RemoteApp does not work: [com.freerdp.core.update] - order flags 00 failed #11218

Closed
@Botspot

Description

@Botspot

This may seem like a niche use-case, but the underlying problem likely affects more users than only me.

Big idea: run a KVM windows 11 VM headless, then run programs on it on the native desktop OS on linux. I have used https://github.com/xiagw/winapps as a starting point for setting the correct Windows registry keys and getting RDP in order. The VM works, and I can use xfreerdp to connect to the machine normally.
What doesn't work is running a single app using RemoteApp mode in xfreerdp.

Here is an example of a failure:

pi@raspberrypi:~ $ env GDK_BACKEND=x11 xfreerdp /v:127.0.0.1 /u:Quickemu /p:quickemu /app:"Explorer.exe" /relax-order-checks +offscreen-cache /cert:ignore -fast-path +auto-reconnect -compression -encryption /gfx:mask:0xZZZ
[02:30:47:977] [976463:976464] [WARN][com.freerdp.core.gcc] - Server uses non-advertised encryption method 0x00000000
[02:30:48:080] [976463:976464] [INFO][com.freerdp.gdi] - Local framebuffer format  PIXEL_FORMAT_BGRX32
[02:30:48:080] [976463:976464] [INFO][com.freerdp.gdi] - Remote framebuffer format PIXEL_FORMAT_BGRA32
[02:30:48:086] [976463:976464] [INFO][com.freerdp.channels.rdpsnd.client] - [static] Loaded fake backend for rdpsnd
[02:30:48:086] [976463:976464] [INFO][com.freerdp.channels.drdynvc.client] - Loading Dynamic Virtual Channel rdpgfx
[02:30:49:629] [976463:976464] [WARN][com.freerdp.client.x11] - xf_Pointer: Invalid appWindow
[02:30:49:668] [976463:976464] [WARN][com.freerdp.client.x11] - xf_Pointer: Invalid appWindow
[02:30:49:668] [976463:976464] [WARN][com.freerdp.client.x11] - xf_Pointer_Set: handle=0
[02:30:49:700] [976463:976464] [WARN][com.freerdp.client.x11] - xf_Pointer: Invalid appWindow
[02:30:49:700] [976463:976464] [WARN][com.freerdp.client.x11] - xf_Pointer_Set: handle=0
[02:30:49:845] [976463:976464] [WARN][com.freerdp.client.x11] - xf_Pointer: Invalid appWindow
[02:30:49:845] [976463:976464] [WARN][com.freerdp.client.x11] - xf_Pointer_Set: handle=0
[02:30:49:928] [976463:976464] [WARN][com.freerdp.client.x11] - xf_Pointer: Invalid appWindow
[02:30:49:928] [976463:976464] [WARN][com.freerdp.client.x11] - xf_Pointer_Set: handle=0
[02:30:49:946] [976463:976464] [WARN][com.freerdp.client.x11] - xf_Pointer: Invalid appWindow
[02:30:49:946] [976463:976464] [WARN][com.freerdp.client.x11] - xf_Pointer_Set: handle=0
[02:30:49:121] [976463:976464] [WARN][com.freerdp.client.x11] - xf_Pointer: Invalid appWindow
[02:30:49:121] [976463:976464] [WARN][com.freerdp.client.x11] - xf_Pointer_Set: handle=0
[02:30:49:188] [976463:976464] [WARN][com.freerdp.client.x11] - xf_Pointer: Invalid appWindow
[02:30:49:188] [976463:976464] [WARN][com.freerdp.client.x11] - xf_Pointer_Set: handle=0
[02:30:50:128] [976463:976464] [WARN][com.freerdp.core.rdp] - pduType PDU_TYPE_DATA not properly parsed, 562 bytes remaining unhandled. Skipping.
[02:30:51:324] [976463:976464] [ERROR][com.freerdp.cache.offscreen] - invalid offscreen bitmap at index: 0x00000000
[02:30:51:324] [976463:976464] [WARN][com.freerdp.core.update] - Alternate Secondary Drawing Order [0x00] Switch Surface failed
[02:30:51:324] [976463:976464] [ERROR][com.freerdp.core.update] - order flags 00 failed
[02:30:51:324] [976463:976464] [ERROR][com.freerdp.core.fastpath] - Fastpath update Orders [0] failed, status 0
[02:30:51:325] [976463:976464] [ERROR][com.freerdp.core.fastpath] - fastpath_recv_update() - -1
[02:30:51:325] [976463:976464] [ERROR][com.freerdp.core.fastpath] - fastpath_recv_update_data() fail
[02:30:51:325] [976463:976464] [ERROR][com.freerdp.core.transport] - transport_check_fds: transport->ReceiveCallback() - -3
[02:30:51:325] [976463:976464] [ERROR][com.freerdp.core] - freerdp_abort_connect:freerdp_set_last_error_ex ERRCONNECT_CONNECT_CANCELLED [0x0002000B]
[02:30:51:325] [976463:976464] [INFO][com.freerdp.client.common] - Network disconnect!
[02:30:51:325] [976463:976464] [INFO][com.freerdp.client.common] - Attempting reconnect (1 of 20)

I should note that for about a half-second, a window does appear on the host Linux depicting the Windows logon screen. That command above was after many added flags to try to work around the issue. Here is a minimal command which exhibits similar behavior:

pi@raspberrypi:~ $ xfreerdp /v:127.0.0.1 /u:Quickemu /p:quickemu /app:"Explorer.exe"
[02:44:41:452] [1049561:1049563] [WARN][com.freerdp.crypto] - Certificate verification failure 'self-signed certificate (18)' at stack position 0
[02:44:41:452] [1049561:1049563] [WARN][com.freerdp.crypto] - CN = RDPWindows
[02:44:43:967] [1049561:1049563] [INFO][com.freerdp.gdi] - Local framebuffer format  PIXEL_FORMAT_BGRX32
[02:44:43:967] [1049561:1049563] [INFO][com.freerdp.gdi] - Remote framebuffer format PIXEL_FORMAT_BGRA32
[02:44:43:063] [1049561:1049563] [INFO][com.freerdp.channels.rdpsnd.client] - [static] Loaded fake backend for rdpsnd
[02:44:43:063] [1049561:1049563] [INFO][com.freerdp.channels.drdynvc.client] - Loading Dynamic Virtual Channel rdpgfx
[02:44:44:985] [1049561:1049563] [WARN][com.freerdp.client.x11] - xf_Pointer: Invalid appWindow
[02:44:44:994] [1049561:1049563] [WARN][com.freerdp.client.x11] - xf_Pointer_Set: handle=0
[02:44:44:066] [1049561:1049563] [WARN][com.freerdp.client.x11] - xf_Pointer: Invalid appWindow
[02:44:44:066] [1049561:1049563] [WARN][com.freerdp.client.x11] - xf_Pointer_Set: handle=0
[02:44:44:066] [1049561:1049563] [WARN][com.freerdp.client.x11] - xf_Pointer: Invalid appWindow
[02:44:44:066] [1049561:1049563] [WARN][com.freerdp.client.x11] - xf_Pointer_Set: handle=0
[02:44:44:447] [1049561:1049563] [WARN][com.freerdp.client.x11] - xf_Pointer: Invalid appWindow
[02:44:44:447] [1049561:1049563] [WARN][com.freerdp.client.x11] - xf_Pointer_Set: handle=0
[02:44:44:514] [1049561:1049563] [WARN][com.freerdp.client.x11] - xf_Pointer: Invalid appWindow
[02:44:44:515] [1049561:1049563] [WARN][com.freerdp.client.x11] - xf_Pointer_Set: handle=0
[02:44:45:746] [1049561:1049563] [WARN][com.freerdp.client.x11] - xf_Pointer: Invalid appWindow
[02:44:45:746] [1049561:1049563] [WARN][com.freerdp.client.x11] - xf_Pointer_Set: handle=0
[02:44:45:850] [1049561:1049563] [WARN][com.freerdp.client.x11] - xf_Pointer: Invalid appWindow
[02:44:45:851] [1049561:1049563] [WARN][com.freerdp.client.x11] - xf_Pointer_Set: handle=0
[02:44:46:992] [1049561:1049563] [WARN][com.freerdp.core.rdp] - pduType PDU_TYPE_DATA not properly parsed, 562 bytes remaining unhandled. Skipping.
[02:44:50:787] [1049561:1049563] [ERROR][com.freerdp.core.update] - [0x00] Switch Surface - SERVER BUG: The support for this feature was not announced! Use /relax-order-checks to ignore
[02:44:50:787] [1049561:1049563] [WARN][com.freerdp.core.update] - Adding +offscreen-cache might mitigate
[02:44:50:787] [1049561:1049563] [ERROR][com.freerdp.core.update] - order flags 00 failed
[02:44:50:787] [1049561:1049563] [ERROR][com.freerdp.core.fastpath] - Fastpath update Orders [0] failed, status 0
[02:44:50:788] [1049561:1049563] [ERROR][com.freerdp.core.fastpath] - fastpath_recv_update() - -1
[02:44:50:788] [1049561:1049563] [ERROR][com.freerdp.core.fastpath] - fastpath_recv_update_data() fail
[02:44:50:788] [1049561:1049563] [ERROR][com.freerdp.core.transport] - transport_check_fds: transport->ReceiveCallback() - -3
[02:44:50:788] [1049561:1049563] [ERROR][com.freerdp.core] - freerdp_abort_connect:freerdp_set_last_error_ex ERRCONNECT_CONNECT_CANCELLED [0x0002000B]
[02:44:50:788] [1049561:1049563] [INFO][com.freerdp.client.common] - Network disconnect!
pi@raspberrypi:~ $ 

It is important to note that omitting the /app: flag does result in a successful connection.

pi@raspberrypi:~ $ xfreerdp /v:127.0.0.1 /u:Quickemu /p:quickemu
[02:45:50:717] [1055399:1055400] [WARN][com.freerdp.crypto] - Certificate verification failure 'self-signed certificate (18)' at stack position 0
[02:45:50:717] [1055399:1055400] [WARN][com.freerdp.crypto] - CN = RDPWindows
[02:45:51:031] [1055399:1055400] [INFO][com.freerdp.gdi] - Local framebuffer format  PIXEL_FORMAT_BGRX32
[02:45:51:031] [1055399:1055400] [INFO][com.freerdp.gdi] - Remote framebuffer format PIXEL_FORMAT_BGRA32
[02:45:51:072] [1055399:1055400] [INFO][com.freerdp.channels.rdpsnd.client] - [static] Loaded fake backend for rdpsnd
[02:45:51:073] [1055399:1055400] [INFO][com.freerdp.channels.drdynvc.client] - Loading Dynamic Virtual Channel rdpgfx
[02:45:54:017] [1055399:1055400] [WARN][com.freerdp.core.rdp] - pduType PDU_TYPE_DATA not properly parsed, 562 bytes remaining unhandled. Skipping.
[02:46:03:122] [1055399:1055399] [ERROR][com.freerdp.core] - freerdp_abort_connect:freerdp_set_last_error_ex ERRCONNECT_CONNECT_CANCELLED [0x0002000B]

Reproducing this bug on a dev machine may be tricky, especially if it turns out to be architecture-specific. You may have noticed from the terminal output I am using a Raspberry Pi. Yes, it's a raspberry pi that I have set up running a Windows 11 ARM VM in QEMU with KVM acceleration. If helpful, I could make a full list of commands to replicate my setup, but that would take several days of work to gather it all together. Hopefully that is unnecessary. I can offer remote connection to my Pi via RustDesk if that helps.

Using the Debian Bookworm version of xfreerdp, 2.10.0.

Environment:

  • Hardware: Raspberry Pi 5 8GB
  • OS: Raspberry Pi OS 12 (Debian Bookworm 12 ARM64)
  • Host Desktop environment: Wayland LabWC
  • Guest: Windows 11 ARM64 Pro with RDP enabled and this registry file applied

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions