QubesOS / qubes-issues

The Qubes OS Project issue tracker
https://www.qubes-os.org/doc/issue-tracking/
543 stars 48 forks source link

qvm-open-in-vm doesn't fill Target with vmname #4207

Closed ghost closed 6 years ago

ghost commented 6 years ago

Qubes OS version:

R4.0

Affected component(s):

qvm-open-in-vm ?


Steps to reproduce the behavior:

Actual behavior:

qvm-open-in-vm_screenshot_2018-08-12_10-45-02 (vm1 is work in this screenshot)

A dialog appears with title [Dom0] Operation execution with two fields: first is an uneditable Source: vm1 and the second is an editable Target: which is empty. In other words, the vmname arg for qvm-open-in-vm is not in the Target: field.

Expected behavior:

dialog's Target: field should contain the text: vm2

General notes:

vm1 is a fedora 28 vm I'm pretty sure that I'm using the testing repositories...

Bonus question: has anyone patched firefox to add a menu entry, near Open Link in New Tab for example, to open that link in a different VM ? (even if the VM names aren't included in a submenu, for security reasons?, but rather just like this issue, you're expected to fill in the Target VM name yourself in the dialog that opens) EDIT: YES - someone has here and it's even better(an extension): https://github.com/raffaeleflorio/qubes-url-redirector


Related issues:

Related comment: https://github.com/QubesOS/qubes-issues/issues/2436#issuecomment-260727458

ghost commented 6 years ago

I just noticed that the above is true for qvm-copy (from within a vm1) too, like $ qvm-copy vm2 file.jpg will have Target: be empty in the dialog. I'm assuming the root cause will fix both of these issues.

However it's interesting that qvm-copy-to-vm says:

qvm-copy-to-vm/qvm-move-to-vm tools are deprecated,
use qvm-copy/qvm-move to avoid typing target qube name twice

$ qvm-copy usage: /usr/bin/qvm-copy-to-vm [--without-progress] dest_vmname file [file]+ $ qvm-copy-to-vm usage: /usr/bin/qvm-copy-to-vm [--without-progress] dest_vmname file [file]+

Hmm... however, in practice looks-like, qvm-copy expects all its args to be files(because it's equivalent to qvm-copy-to-vm '$default'), then you select the Target vm in the dialog. Whilst qvm-copy-to-vm actually expects the first arg to be the dest_vm_name and it looks like it's known that you have to type the dest_vmname twice(once as arg and once in the Target field of the dialog), according to the above message that says: use qvm-copy/qvm-move to avoid typing target qube name twice.

This leads me to believe the original issue is actually a feature: expecting to type vmname twice(as arg and as dialog).

andrewdavidwong commented 6 years ago

Duplicate of #3251

andrewdavidwong commented 6 years ago

This appears to be a duplicate of an existing issue. If you believe this is not really a duplicate, please leave a comment briefly explaining why. We'll be happy to take another look and, if appropriate, reopen this issue. Thank you.