RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1446161 - virt-viewer window can leave fullscreen in kiosk mode but cannot be quitted
Summary: virt-viewer window can leave fullscreen in kiosk mode but cannot be quitted
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: virt-viewer
Version: 7.4
Hardware: x86_64
OS: Unspecified
medium
medium
Target Milestone: rc
: ---
Assignee: Eduardo Lima (Etrunko)
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-04-27 11:12 UTC by Xiaodai Wang
Modified: 2017-08-01 15:06 UTC (History)
9 users (show)

Fixed In Version: virt-viewer-5.0-7.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-08-01 15:06:41 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
virt-viewer --debug log (2.40 KB, application/octet-stream)
2017-04-27 11:14 UTC, Xiaodai Wang
no flags Details
screenshot (324.44 KB, image/png)
2017-04-27 11:15 UTC, Xiaodai Wang
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2017:1849 0 normal SHIPPED_LIVE virt-viewer bug fix and enhancement update 2017-08-01 17:49:46 UTC

Description Xiaodai Wang 2017-04-27 11:12:17 UTC
Description of problem:
virt-viewer window can leave fullscreen in kiosk mode but cannot be quitted

Version-Release number of selected component (if applicable):
virt-viewer-5.0-2.el7.x86_64

How reproducible:
100%

Steps to Reproduce:
1. Configure a spice guest with password set.
2. Open the guest with -k option, the Authentication required dialog pops.
$ virt-viewer -c qemu:///system rhel7.3 -k
3. Cancel the authentication.

Actual results:
1) The hints "Guest domain has shutdown" in main window is wrong. The guest is running status.
2) The virt-viewer window can exit fullscreen mode by clinking 'leave fullscreen' button, but the app cannot quit.

Expected results:
1) If cancelled the authentication, virt-viewer should display correct hints.
2) Let virt-viewer can't exit fullscreen mode and supply a way to re-authentication with the guest.  Another way is let virt-viewer window can quit after cancelling the authentication. 
3) Must supply a way to re-authentication? if --kiosk-quit never is specified, when destroy and then start the guest again, the user cancel the authentication dialog, now no way to re-connect to graphic server.
4) if specified --kiosk --kiosk-quit on-disconnect --reconnect options, when destroy and then start the guest again, the user cancel the authentication dialog, the virt-viewer can quit. May be this behavior is as expected?


Additional info:

Comment 2 Xiaodai Wang 2017-04-27 11:14:13 UTC
Created attachment 1274576 [details]
virt-viewer --debug log

Comment 3 Xiaodai Wang 2017-04-27 11:15:02 UTC
Created attachment 1274577 [details]
screenshot

Comment 4 Eduardo Lima (Etrunko) 2017-05-19 19:47:30 UTC
There are a couple of things to consider here:

1) When in kiosk mode, there should be no toolbar presented to the user so they can leave fullscreen mode.

2) In the case of cancelling the authentication while in kiosk mode, the app should either quit or present the dialog again. I tend to prefer the first option, otherwise there will be complaints about never being able to quit.

Comment 5 Victor Toso 2017-05-19 20:45:20 UTC
Please, mark as regression if bug wasn't present in previous release

Comment 7 Eduardo Lima (Etrunko) 2017-06-01 19:49:25 UTC
Fixed by upstream commits 8ab98eec203e0a113be7509e36d10c8511e186ac and 5d9e6d2338cbb680fe761b86e6ca433b1234e6e0

Comment 9 Xiaodai Wang 2017-06-02 03:43:06 UTC
I verified it with virt-viewer-5.0-5.el7.x86_64.

The leave fullscreen problem has been fixed. 

But another problem, after clicking cancel button, "Authentication failed: wrong password?" dialog pops.
This is not as expected. Can we just close the 'Authentication required' dialog and pops it again and no any failed dialog pops when users cancel it?

Comment 10 Xiaodai Wang 2017-06-02 08:06:44 UTC
There are still other problems about authentication in -k mode.
1. 
Steps:
1). Run "virt-viewer -c qemu:///system $guest -k" to open a running password specified guest, and "Authentication required" dialog pops up.
2). Leave the dialog there and Destroy the guest, "Authentication failed: wrong password" dialog pops up (I think this dialog should not pop up and "Authentication required" dialog should be closed and correct status be displayed in virt-viewer main window).
3). Click ok to close "Authentication failed: wrong password" dialog and leave "Authentication required" dialog there, then start the guest again. A new "Authentication required" dialog pops up and covers the previous one (Now there are two dialogs).
4). Type correct password in the top of the dialog. graphic server can be connected successfully. But the previous "Authentication required" dialog is still there.
5). Following step4, now you two choices. If click 'ok', yes, the dialog can be closed and you can do operation with the guest normally. But if click 'cancel',  "Authentication required" dialog will pop up and "unable to connect to the graphic server xxxx" dialog pops. You lost connection with the graphic server.  and have to restart the guest to reauthentication or restart virt-viewer process to reconnect to the graphic server.

2. Run "virt-viewer -c qemu:///system $guest -k --kiosk-quit on-disconnect" and "Authentication required" dialog pops, then destroy the guest,  virt-viewer cannot quit at once. "Authentication failed: wrong password?" dialog pops first. If close the authentication failed dialog, "Authentication required" dialog is still there. virt-viewer can quit after clicking 'cancel' or 'ok'.

I think 1&2 are same problems and need virt-viewer to do more changes to fix them. i can file another bug to trace the problem.


3. Run "remote-viewer spice://localhost:5900 -k" to connect to guest, then shutdown the guest, start up the guest again. remote-viewer cannot reconnect to the graphic server (The listen port doesn't change during testing).

I think this is a new problem, i'll file a new bug.

Comment 11 Victor Toso 2017-06-02 09:27:26 UTC
(In reply to xiaodwan from comment #9)
> I verified it with virt-viewer-5.0-5.el7.x86_64.
> 
> The leave fullscreen problem has been fixed. 
> 
> But another problem, after clicking cancel button, "Authentication failed:
> wrong password?" dialog pops.
> This is not as expected. Can we just close the 'Authentication required'
> dialog and pops it again and no any failed dialog pops when users cancel it?

Yes, you are right.
I think it is best to failedQA and we do a new build with an extra patch to work around the error.

(In reply to xiaodwan from comment #10)
> I think 1&2 are same problems and need virt-viewer to do more changes to fix
> them. i can file another bug to trace the problem.

Yes, please. Please do check for regression in those behaviors too.

> 3. Run "remote-viewer spice://localhost:5900 -k" to connect to guest, then
> shutdown the guest, start up the guest again. remote-viewer cannot reconnect
> to the graphic server (The listen port doesn't change during testing).
> 
> I think this is a new problem, i'll file a new bug.

Thanks again

Comment 12 Victor Toso 2017-06-02 10:41:56 UTC
Sent a patch to work around the dialog error
https://www.redhat.com/archives/virt-tools-list/2017-June/msg00009.html

Comment 13 Eduardo Lima (Etrunko) 2017-06-05 17:09:47 UTC
Patch merged upstream 6480e52f62bc7c87bbdca1aa50f7ff08b09e9845, will be included in 5.0-6 build.

Comment 15 Xiaodai Wang 2017-06-06 03:37:30 UTC
(In reply to Eduardo Lima (Etrunko) from comment #13)
> Patch merged upstream 6480e52f62bc7c87bbdca1aa50f7ff08b09e9845, will be
> included in 5.0-6 build.

This patch doesn't fix the issue for vnc server.

Comment 16 Victor Toso 2017-06-06 08:26:02 UTC
(In reply to xiaodwan from comment #15)
> (In reply to Eduardo Lima (Etrunko) from comment #13)
> > Patch merged upstream 6480e52f62bc7c87bbdca1aa50f7ff08b09e9845, will be
> > included in 5.0-6 build.
> 
> This patch doesn't fix the issue for vnc server.

This is the first time you have mentioned vnc in this bug.
You mean the kiosk mode in fullscreen, described in comment #0 but for vnc? Or do you mean the error dialog? I'll be checking this shortly as well.

Comment 17 Xiaodai Wang 2017-06-06 08:34:44 UTC
> This is the first time you have mentioned vnc in this bug.
> You mean the kiosk mode in fullscreen, described in comment #0 but for vnc?
> Or do you mean the error dialog? I'll be checking this shortly as well.

I mean when connecting to a vnc server, after cancel the authentication, the error dialog also displays. 

And above patch only fixes spice.

I thought you know. In the previous patch series, you modified both spice and vnc.
:)

Comment 18 Victor Toso 2017-06-06 09:45:25 UTC
(In reply to xiaodwan from comment #17)
> I thought you know. In the previous patch series, you modified both spice
> and vnc.

The patch that changed vnc was a preparatory patch, it would still show this error. But don't worry about it.

A proposal patch was sent to fix vnc behavior, that is:
https://www.redhat.com/archives/virt-tools-list/2017-June/msg00024.html

I'm doing a scratch build too, feel free to test in the meanwhile.
https://brewweb.engineering.redhat.com/brew/taskinfo?taskID=13351751

Comment 19 Xiaodai Wang 2017-06-06 10:53:07 UTC
I tested the scratch build.

After authentication dialog pops for vnc server, then click ok with blank password, the dialog will be closed and will not pop up again. And the virt-viewer cannot be closed normally except kill the process.

Comment 20 Victor Toso 2017-06-06 12:28:15 UTC
Thanks for testing. I missed that.

V2 is:
https://www.redhat.com/archives/virt-tools-list/2017-June/msg00025.html

scratch-build is:
https://brewweb.engineering.redhat.com/brew/taskinfo?taskID=13353651

Comment 22 Xiaodai Wang 2017-06-07 06:44:46 UTC
(In reply to Victor Toso from comment #20)
> Thanks for testing. I missed that.
> 
> V2 is:
> https://www.redhat.com/archives/virt-tools-list/2017-June/msg00025.html
> 
> scratch-build is:
> https://brewweb.engineering.redhat.com/brew/taskinfo?taskID=13353651

I verified this build.
virt-viewer work well for spice and vnc.


and I also tried a missed scenario of "remote-viewer --ovirt-ca-file=xxx ovirt://xxx/xxx -k", when clicking cancel button, remote-viewer quit directly.

Do you think this should be fixed, too? If you don't have enough time for rhel7.4, i can file a new bug to rhel7.5.

Thanks and sorry for the missed scenario when i verified it.

Comment 23 Victor Toso 2017-06-07 07:19:58 UTC
> > scratch-build is:
> > https://brewweb.engineering.redhat.com/brew/taskinfo?taskID=13353651
> 
> I verified this build.
> virt-viewer work well for spice and vnc.

Thank you for testing.

> and I also tried a missed scenario of "remote-viewer --ovirt-ca-file=xxx
> ovirt://xxx/xxx -k", when clicking cancel button, remote-viewer quit
> directly.
> 
> Do you think this should be fixed, too? If you don't have enough time for
> rhel7.4, i can file a new bug to rhel7.5.

That would mean that kiosk mode is not being handled correctly. Yes, I think this need to be fixed but definitely not in 7.4

> Thanks and sorry for the missed scenario when i verified it.

No worries, good job.

Comment 25 tingting zheng 2017-06-07 07:55:33 UTC
(In reply to Victor Toso from comment #23)
> > > scratch-build is:
> > > https://brewweb.engineering.redhat.com/brew/taskinfo?taskID=13353651
> > 
> > I verified this build.
> > virt-viewer work well for spice and vnc.
> 
> Thank you for testing.
> 
> > and I also tried a missed scenario of "remote-viewer --ovirt-ca-file=xxx
> > ovirt://xxx/xxx -k", when clicking cancel button, remote-viewer quit
> > directly.
> > 
> > Do you think this should be fixed, too? If you don't have enough time for
> > rhel7.4, i can file a new bug to rhel7.5.
> 
> That would mean that kiosk mode is not being handled correctly. Yes, I think
> this need to be fixed but definitely not in 7.4
> 
> > Thanks and sorry for the missed scenario when i verified it.
> 
> No worries, good job.

So there is a new virt-viewer build including the above fix with both spice and vnc guest,and all left issues can be tracked by a new bug,am I right?

If so,pls build the new package as soon as possible,we will do some testing for that and use the new build to do regression testing,thanks.

Comment 26 Victor Toso 2017-06-07 08:04:01 UTC
> If so,pls build the new package as soon as possible,we will do some testing
> for that and use the new build to do regression testing,thanks.

Sure, I'll be doing a build in the next half hour or so.

Comment 28 Xiaodai Wang 2017-06-07 09:27:30 UTC
I verified it with virt-viewer-5.0-7.el7.x86_64 and tried both spicea and vnc.

All work well.

so move the bug to VERIFIED.

Comment 29 errata-xmlrpc 2017-08-01 15:06:41 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2017:1849


Note You need to log in before you can comment on or make changes to this bug.