Having issue with copy & paste function!

Hi,
Nothing is happening when I want to copy my password from keepass & paste it in another vm. I do:
Ctrl + C
Ctrl + Shift + C
Ctrl + Shift + V
Ctrl + V

What’s wrong? :frowning:

Also I wanted to make a shortcut for this function but I wasn’t successful based on this instruction:

qvm-features dom0 gui-default-secure-copy-sequence 'Mod4-c'
qvm-features dom0 gui-default-secure-paste-sequence 'Mod4-v'

When you press ctrl-shift-c, it is normal for qubes to show a message in the corner of the screen showing how many bytes you copied. Do you see this message?

Have you tried copying and pasting from other program, from a text file, for example?

Yes, I remember that message before but I don’t see it anymore.

By executing these comands, I believe you changed the shortcut ctrl-shift-c to windows-c.

So you should try:

Ctrl-c
Windows-c
Windows-v
Ctrl-v

You are right!

Just another thing. When I copy something from here and paste to another vm’s terminal it adds more charachter to the original one

For example if the original word is: Hey how are u

after paste in terminal it shows like this: ~[[200~Hey how are u~

Yes. I don’t know why that happens. Normally when copying or pasting in terminals I use the right mouse click to avoid this.

1 Like

Yes, I use right click mouse as well. because I wasn’t able to paste through keyboard. but it adds those charachters. It’s wierd

Thx anyway, :slight_smile:

I see this too, when I copy text from a terminal window and paste it in another terminal window. I believe these are ANSI vt100 control characters used for controlling the output positioning in the terminal window.

Theoretically I believe these control characters might be able to cause nefarious operations by overlaying visible text commands when pasting data from an untrusted vm to a more trusted one. This is something that would need to be verified but it seems plausible based on what ANSI sequences are capable of doing in a terminal.

It would be good if there was a way to strip these extraneous control characters when selecting or copying text from a terminal window when it passes through the qubes clipboard.

Would stripping ANSI sequences not be considered proper sanitization of the qubes clipboard data?

Would this sanitization step negatively affect other legitimate cut/paste operations? E.g. What is the chance that a password might contain something resembling an ansi control sequence?

When using Xfce4-terminal, there’s beautiful option to automatically copy selection to clipboard. Or, general in Qubes you can use CTRL+Insert to copy. Then SHIFT+Insert to paste. Hands friendly.

1 Like

My laptop keyboard doesn’t have any insert key

Sorry to horn in, I’ve a recommendation though for the OP. You may want to investigate whether your laptop really doesn’t have an INSERT key because due to the condensed platform many utilize a special key & triple-use some keys for extra wanted keys like sometimes the insert & delete keys. I of course cannot guarantee this but what can it hurt to re-examine yours? Look also for INS as the lack of space affects the laser-printing of keys too. Typically on laptops, you have something like a Fn key that you hold down while pressing the triple-function key & often times that key itself has the third function printed using radically different coloration than the regular use labeling that key would show.

What terminal are you running?
You’ll see this in gnome-terminal, but not in xterm, I think.
Also, if you examine the actual buffer, it’s most likely that it doesn’t
contain those characters at all - in gnome-terminal they seem to be an
artefact of the first paste operation.

I never presume to speak for the Qubes team. When I comment in the Forum or in the mailing lists I speak for myself.

Hi, The reason I mentioned this because I’m still looking for a better shortcut on my keyboard for copy/paste function

I’m getting more confused when I use Ctrl + C & Win + C instead of Ctrl + C & Ctrl + Shift + C.

It would be good if we could use a combination of two keys for copy. For example using Insert + C instead of Ctrl + C & Ctrl + Shift + C

Sorry to respond to a thread marked solved. Even though I suspect your response may not have been intended to be directed my way, I’m going to have to step back in for a comment about a detail of how computers (unfortunately referring to these forms as PCs for lack of better history to shield us from such an unfortunate event - and clearly doesn’t mean as much in this age of mobile devices with their own definitions of what matters & how things operate) function, specifically regarding keyboard entry methods. The control, shift, alt are what are specifically referred to as “modifiers” to other keypresses, insert & delete unfortunately are not. No offense meant but, you press it you get it (the controller reports a keypress on every keypress of a non-modifier key) & making it work any differently is a bit more than can usually be done (reprogramming the keyboard controller? Maybe it’s a common item but I’m a bit unsure there).

2 Likes

Global Copy/Paste broke on my install sometime in the last week. Copy still works, displaying he notification message, reporting the correct number of bytes. Pasting is seemingly impossible. Nothing relevant in the logs that I can see.

Edit: Rebooting a second time fixed it. No idea why the problem persisted through the first reboot.

Edit2: i take that back. Something about my vault Qube ia breaking it. Going to have to do a lot more digging.

@ashaman

I am experiencing similar here:

  1. Can you check the output of the following in dom0?
$ sudo qvm-features dom0

In dom0:

$ sudo qvm-features dom0

Returns:

updates-available
gui-default-secure-copy-sequence Ctrl-Mod4-c

Thanks to this thread, specifically this post:

I ‘learned’ that in order to copy to Global Clipboard, I now need to use the “Windows” key in place of Shift!?!?


But, I’d still VERY much like to understand how this was changed. Doesn’t look as though it could be due to any kind of corrupted/half-cocked process. Furthermore, why don’t I see the corresponding gui-default-secure-paste-sequence Ctrl-Shift-v OR gui-default-secure-paste-sequence Ctrl-Mod4-v ?


Well, to answer my own question and maybe someone else’s …

There is a handy section in “Qubes Global Settings” for “Keyboard shortcuts/Global Clipboard”. Changed that back to default (Ctrl+Shift+C) and now:

In dom0:

$ sudo qvm-features dom0

Returns (as expected):

updates-available

I’ve been aware that the UI for “Qubes Global Settings” does not respond well to arrow key (IE: Up/Down) navigation thus, easy to change a setting unknowingly BUT, it happened anyway. Lesson learned, sleep more, paranoia less. :blush: :wink: :blush: