Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

libvncserver should not advertize ExtendedClipboard support if server app doesn't supoort it #638

Open
gujjwal00 opened this issue Nov 18, 2024 · 2 comments
Labels

Comments

@gujjwal00
Copy link
Contributor

Describe the bug

libvncserver always enables ExtendedClipboard encoding if client supports it. When client sends cut text, it is reported to server app via setXCutTextUTF8() callback, which is no-op by default. If app doesn't support UTF-8 cut text, it will not set this callback. As a result, client to server clipboard transfer will be completely broken.

To my knowledge, x11vnc and Gnome Remote Desktop are affected by this.

libvncserver should check whether the callback is set before enabling ExtendedClipoard encoding. This is how libvncclient does it.

@bk138
Copy link
Member

bk138 commented Nov 19, 2024

Yes, clipboard cleanup is the last missing bit for v0.9.15 - I just need to find some time to tackle this ;-)

gujjwal00 added a commit to gujjwal00/libvncserver that referenced this issue Nov 19, 2024
… support for UTF-8 cut-text

A UTF-8 capable client will usually prefer to send cut-text via ExtendedClipboard encoding once libvncserver declares support for it. If app doesn't assign a setXCutTextUTF8() callback, the default handler is used which is no-op. So client-to-server clipboard transfer will not work.

Re: LibVNC#638
gujjwal00 added a commit to gujjwal00/libvncserver that referenced this issue Nov 19, 2024
… support for UTF-8 cut-text

A UTF-8 capable client will usually prefer to send cut-text via ExtendedClipboard encoding once libvncserver declares support for it. If app doesn't assign a setXCutTextUTF8() callback, the default handler is used which is no-op. So client-to-server clipboard transfer will not work.

Re: LibVNC#638
@gujjwal00
Copy link
Contributor Author

Opened a PR with the fix. Let me know if I can help with something else.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants