Bug 1031065

Summary: USB device is redirected to guest even is blocked by filter string
Product: Red Hat Enterprise Linux 7 Reporter: Vaclav Ehrlich <vehrlich>
Component: spice-gtkAssignee: Default Assignee for SPICE Bugs <rh-spice-bugs>
Status: CLOSED WORKSFORME QA Contact: Desktop QE <desktop-qa-list>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 7.0CC: acathrow, dblechte, marcandre.lureau, tpelka, vehrlich
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-08-05 16:09:30 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Vaclav Ehrlich 2013-11-15 14:42:36 UTC
Description of problem:
When USB mass storage device is connected to client, it's redirected into guest, even mass storage class is bocked by filter string. 
This happens only when spice-xpi page is used.

Guest recognize USB mass storage media with proper class: 
bInterfaceClass         8 Mass Storage
Qemu-kvm on host logs connected device:
attaching high speed device 0951:162d version 1.0 class 00
And device is redirected even filter log is used:
USB Filter String was set to: '"8,-1,-1,-1,0"'

If client is connected via command line:
remote-viewer spice://localhost?port=3334 --spice-usbredir-auto-redirect-filter="8,-1,-1,-1,0"
everything is fine and USB is not redirected.

Version-Release number of selected component (if applicable):
spice-server-0.12.4-3.el7.x86_64
spice-vdagent-0.14.0-5.el7.x86_64
spice-gtk3-0.20-6.el7.x86_64
spice-xpi-2.8-4.el7.x86_64
spice-glib-0.20-6.el7.x86_64
usbredir-0.6-5.el7.x86_64

How reproducible:
Always from spice xpi test page http://people.freedesktop.org/~teuf/test.html

Steps to Reproduce:
1.Go to spice xpi test page http://people.freedesktop.org/~teuf/test.html
2.Fill in host, port, usb listen port to 0, usb autoredirect, usb filter to "8,-1,-1,-1,0" (blocking USB class 8)
3.Connect to guest
4.Plug USB mass storage device into client

Actual results:
USB is redirected into guest

Expected results:
USB is not redirected into guest

Additional info:
Host: RHEL7 64
Client: RHEL7 64
Guest: Win7 64, RHEL7 64

Comment 2 RHEL Program Management 2014-03-22 06:31:24 UTC
This request was not resolved in time for the current release.
Red Hat invites you to ask your support representative to
propose this request, if still desired, for consideration in
the next release of Red Hat Enterprise Linux.

Comment 3 Marc-Andre Lureau 2014-07-02 17:53:08 UTC
It is working for me, does it work for you now?

virt-viewer-0.5.7-7.el7.x86_64
spice-xpi-2.8-5.el7.x86_64
spice-gtk3-0.20-8.el7.x86_64

if not, please run firefox from command line, with G_MESSAGES_DEBUG=all and SPICE_DEBUG=1 and provide full log. thanks

Comment 5 Marc-Andre Lureau 2014-08-05 16:09:30 UTC
Closing, feel free to reopen with further details.

Comment 6 David Jaša 2015-01-07 14:44:48 UTC
Removing needinfo on Spice QE members from closed bugs.