Public bug reported:

After the freerdp3 security update from 3.32.1+dfsg-0ubuntu0.26.04.1 to
3.32.2+dfsg-0ubuntu0.26.04.1, WinPR can no longer convert HTML clipboard
data. ClipboardGetData() returns NULL for "HTML Format" -> "text/html"
and for "text/html" -> "HTML Format".

I noticed it with gnome-remote-desktop on Ubuntu 26.04 (Remote Login,
Windows mstsc client). When I copied formatted text on Windows and
pasted it into an Electron app on Ubuntu, the paste hung for about 15
seconds and gnome-remote-desktop logged:

[RDP.CLIPRDR] Converting clipboard content failed: Failed to get
converted data

The 15 second wait itself comes from mutter, which I reported
separately: https://gitlab.gnome.org/GNOME/mutter/-/issues/5199

3.32.2 includes upstream commit 2ecbfaf1f1f7 ("[winpr,clipboard] Add
ClipboardRegisterSynthesizerEx"). The new API passes the destination
format to clipboard_synthesize_html_format() and
clipboard_synthesize_ms_html_format()
(winpr/libwinpr/clipboard/synthetic.c), but their inner checks still
compare it with the source format, so the conversion is always skipped.
Upstream fixed this in commit ffdee9b6c2d3
(https://github.com/FreeRDP/FreeRDP/pull/13734), a two-line change that
is in 3.33.0.

The attached html.c shows it. Build with: gcc -o html html.c 
/usr/lib/x86_64-linux-gnu/libwinpr3.so.3
Output with libwinpr3-3 3.32.2+dfsg-0ubuntu0.26.04.1:

HTML Format -> text/html: NULL
text/html -> HTML Format: NULL

I rebuilt libwinpr3 from the 3.32.2+dfsg-0ubuntu0.26.04.1 source with
ffdee9b applied, and both conversions work.

noble and stonking got the same 3.32.2, but I only tested resolute.

Could ffdee9b be included in the next freerdp3 update?

** Affects: freerdp3 (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: regression-update resolute

** Attachment added: "html.c test program"
   https://bugs.launchpad.net/bugs/2173827/+attachment/6016578/+files/html.c

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/2173827

Title:
  3.32.2 regression: WinPR HTML clipboard conversion always fails

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/freerdp3/+bug/2173827/+subscriptions


-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to