Page 3 of 3

Re: Broadcom 5880 Smart Card Reader

Posted: 13. Feb 2019, 01:26
by socratis
bmwsandman wrote:if i just shutdown the guest, it does not release the usb device back to the host correctly. ie. the host does not recognize the usb device correctly.
I'm sorry, but you definitely have to explain that part. AFAIK there's absolutely no difference between ejecting from the guest before the guest shuts down, after the guest shuts down and it's released automatically, force closing the guest, or the guest aborting.

Is there anything specific about your device that makes it behave differently when released "softly" (ejected) versus a "hard" release (guest shuts down)? Does it get into a different state, a "park" state?
bmwsandman wrote:so i was thinking if i could run a shutdown script that would first release the usb device, then the host would happy.
If such a script exists, it would be guest specific, something that you would do in a physical computer. There's no such mechanism built-into VirtualBox. Even now (if you think about it) you're not ejecting the device from VirtualBox, you eject it from the guest.

Re: Broadcom 5880 Smart Card Reader

Posted: 13. Feb 2019, 02:03
by bmwsandman
the usb device a internal smartcard reader so there is no physically ejecting this device.

what i would like to be able to do via a script is to "uncheck" the captured usb device from the virtualbox device/usb menu within the guest. this seems to make the smartcard reader available on the host even before the guest is shutdown.

Re: Broadcom 5880 Smart Card Reader

Posted: 13. Feb 2019, 08:11
by socratis
bmwsandman wrote:what i would like to be able to do via a script is to "uncheck" the captured usb device from the virtualbox device/usb menu within the guest
As I previously said, this is a action initiated from the host, not the guest. And since it's a ReallyBadIdeaâ„¢ to control the host from the guest, you need to think this from a different angle. Say, create a script on the host that first ejects the USB device in question and then initiates an ACPI shutdown.

Again, I fail to see the difference between user-freeing the device from the Devices menu, vs auto-releasing the device when the guest shuts down. You haven't told me what the difference is.

Re: Broadcom 5880 Smart Card Reader

Posted: 13. Feb 2019, 10:18
by bmwsandman
socratis wrote: Again, I fail to see the difference between user-freeing the device from the Devices menu, vs auto-releasing the device when the guest shuts down. You haven't told me what the difference is.
i think its a timing thing. I have no idea when virtualbox actually releases the device during its shutdown process. But if i can release the device before the actual guest shutdown or even regardless of a shutdown, then I know the device should be available to the host regardless of the state of the guest.

Re: Broadcom 5880 Smart Card Reader

Posted: 28. Feb 2019, 10:04
by michal.behun
bmwsandman wrote:I wanted to post an update to this solution:
1. Name=broadcom corp [0101], Vendor id=0a5c, product id=5834, revision=0101 {your values may vary}
2. Name=Broadcom CV, vendor id=0a5c, product id=5831 {again, your values may vary}
Hi, I only found smart card in device manager, other CV devices are not there. Where should I look?
I tried to add filters anyway, but my guest don't see any broadcom devices.
Thanks for help.

Re: Broadcom 5880 Smart Card Reader

Posted: 28. Feb 2019, 11:22
by socratis
michal.behun wrote:I tried to add filters anyway, but my guest don't see any broadcom devices.
The question is: does your host see it? If it does, you should be able to add the filter. Then read the thread from the beginning. Twice, and realy carefully, in case you missed something.

Re: Broadcom 5880 Smart Card Reader

Posted: 28. Feb 2019, 12:22
by michal.behun
I see Microsoft Usbccid Smartcard Reader (WUDF) device under smart card readers in host device manager (HW ID USB\VID_0A5C&PID_5832&REV_0101&MI_01)
So I added filter in virtualbox Name=broadcom corp [0101], Vendor id=0a5c, product id=5832, revision=0101
There is no smart card reader nor unknown device In guest VM's device manager.

Re: Broadcom 5880 Smart Card Reader

Posted: 1. Mar 2019, 09:46
by socratis
When I said "does the host see it", I meant in the context of VirtualBox. Please read the following thread: USB basics and troubleshooting, all of the posts.

If you still have a problem after reading through the whole thing, please follow the advice of the last post, #8: Asking for help and post the information requested.

Re: Broadcom 5880 Smart Card Reader

Posted: 1. Mar 2019, 11:09
by michal.behun
Hi.
I gathered all of the info. I try to use dell internal smartcard reader in VM. Smartcard reader is not visible in guest after adding it on-the-fly, and also with usb capture filter.
VirtualBox version: Version 6.0.4 r128413 (Qt5.6.2)
Guest Additions installed on guest.
Oracle VM VirtualBox Extension Pack 6.0.4 r128413
Screenshot of usb filter settings is attached.

Code: Select all

C:\Program Files\Oracle\VirtualBox>VBoxManage list usbhost
Host USB Devices:

UUID:               829dc237-24d2-465d-9d63-1b8be964557d
VendorId:           0x8087 (8087)
ProductId:          0x0a2b (0A2B)
Revision:           0.16 (0016)
Port:               7
USB version/speed:  2/Full
Manufacturer:       Intel Corp.
Address:            {e0cbf06c-cd8b-4647-bb8a-263b43f0f974}\0000
Current State:      Busy

UUID:               72763609-71d8-4873-a4b8-820fc78d04e9
VendorId:           0x413c (413C)
ProductId:          0x81b6 (81B6)
Revision:           0.6 (0006)
Port:               14
USB version/speed:  3/Super
Manufacturer:       Dell Computer Corp.
Address:            {36fc9e60-c465-11cf-8056-444553540000}\0011
Current State:      Busy

UUID:               aa4b3c92-4283-41c1-acab-3e0248b2e8d4
VendorId:           0x1bcf (1BCF)
ProductId:          0x2b96 (2B96)
Revision:           104.37 (10437)
Port:               5
USB version/speed:  2/High
Manufacturer:       Sunplus Innovation Technology Inc.
Address:            {36fc9e60-c465-11cf-8056-444553540000}\0004
Current State:      Busy

UUID:               48a8104a-accc-4a1b-84e6-3460f3822a84
VendorId:           0x1532 (1532)
ProductId:          0x0016 (0016)
Revision:           1.0 (0100)
Port:               2
USB version/speed:  2/Full
Manufacturer:       Razer
Product:            Razer DeathAdder
Address:            {745a17a0-74d3-11d0-b6fe-00a0c90f57da}\0021
Current State:      Busy

UUID:               869e5a1b-86fc-47b2-9f29-ce49003006d9
VendorId:           0x0a5c (0A5C)
ProductId:          0x5832 (5832)
Revision:           1.1 (0101)
Port:               10
USB version/speed:  1/Full
Manufacturer:       Broadcom Corp.
Address:            {36fc9e60-c465-11cf-8056-444553540000}\0005
Current State:      Busy

UUID:               c8fc01ab-1a62-46b4-a489-69697de7cc43
VendorId:           0x045e (045E)
ProductId:          0x0768 (0768)
Revision:           1.80 (0180)
Port:               9
USB version/speed:  2/Full
Manufacturer:       Microsoft
Product:            Microsoft® SiderWinderTM X4 Keyboard
Address:            {36fc9e60-c465-11cf-8056-444553540000}\0020
Current State:      Busy

Code: Select all

C:\Program Files\Oracle\VirtualBox>VBoxManage list usbfilters
Global USB Device Filters:

<none>

Code: Select all

C:\Program Files\Oracle\VirtualBox>VBoxManage showvminfo mv
Name:                        mv
Groups:                      /
Guest OS:                    Windows 7 (64-bit)
UUID:                        2e509b6b-8a44-4b61-bddb-2d4f4229fc9b
Config file:                 D:\VMs\mv\mv\mv.vbox
Snapshot folder:             D:\VMs\mv\mv\Snapshots
Log folder:                  D:\VMs\mv\mv\Logs
Hardware UUID:               2e509b6b-8a44-4b61-bddb-2d4f4229fc9b
Memory size                  2048MB
Page Fusion:                 disabled
VRAM size:                   30MB
CPU exec cap:                100%
HPET:                        disabled
CPUProfile:                  host
Chipset:                     piix3
Firmware:                    BIOS
Number of CPUs:              1
PAE:                         disabled
Long Mode:                   enabled
Triple Fault Reset:          disabled
APIC:                        enabled
X2APIC:                      disabled
Nested VT-x/AMD-V:           disabled
CPUID Portability Level:     0
CPUID overrides:             None
Boot menu mode:              message and menu
Boot Device 1:               Floppy
Boot Device 2:               DVD
Boot Device 3:               HardDisk
Boot Device 4:               Not Assigned
ACPI:                        enabled
IOAPIC:                      enabled
BIOS APIC mode:              APIC
Time offset:                 0ms
RTC:                         local time
Hardw. virt.ext:             enabled
Nested Paging:               enabled
Large Pages:                 enabled
VT-x VPID:                   enabled
VT-x unr. exec.:             enabled
Paravirt. Provider:          Default
Effective Paravirt. Prov.:   HyperV
State:                       powered off (since 2019-03-01T08:14:37.000000000)
Monitor count:               1
3D Acceleration:             disabled
2D Video Acceleration:       disabled
Teleporter Enabled:          disabled
Teleporter Port:             0
Teleporter Address:
Teleporter Password:
Tracing Enabled:             disabled
Allow Tracing to Access VM:  disabled
Tracing Configuration:
Autostart Enabled:           disabled
Autostart Delay:             0
Default Frontend:
Storage Controller Name (0):            SATA
Storage Controller Type (0):            IntelAhci
Storage Controller Instance Number (0): 0
Storage Controller Max Port Count (0):  30
Storage Controller Port Count (0):      2
Storage Controller Bootable (0):        on
SATA (0, 0): D:\VMs\win7.vdi (UUID: b38a5803-5f74-4c84-8c8e-cf640f1c3c87)
SATA (1, 0): C:\Program Files\Oracle\VirtualBox\VBoxGuestAdditions.iso (UUID: 2fe9281e-408a-4ada-95d8-c90506b5acfc)
NIC 1:                       MAC: 080027E07264, Attachment: NAT, Cable connected: on, Trace: off (file: none), Type: 82540EM, Reported speed: 0 Mbps, Boot priority: 0, Promisc Policy: deny, Bandwidth group: none
NIC 1 Settings:  MTU: 0, Socket (send: 64, receive: 64), TCP Window (send:64, receive: 64)
NIC 2:                       disabled
NIC 3:                       disabled
NIC 4:                       disabled
NIC 5:                       disabled
NIC 6:                       disabled
NIC 7:                       disabled
NIC 8:                       disabled
Pointing Device:             USB Tablet
Keyboard Device:             PS/2 Keyboard
UART 1:                      disabled
UART 2:                      disabled
UART 3:                      disabled
UART 4:                      disabled
LPT 1:                       disabled
LPT 2:                       disabled
Audio:                       enabled (Driver: DSOUND, Controller: HDA, Codec: STAC9221)
Audio playback:              disabled
Audio capture:               enabled
Clipboard Mode:              Bidirectional
Drag and drop Mode:          disabled
VRDE:                        disabled
OHCI USB:                    enabled
EHCI USB:                    enabled
xHCI USB:                    disabled

USB Device Filters:

Index:                       0
Active:                      yes
Name:                        Broadcom Corp.  [0101]
VendorId:                    0a5c
ProductId:                   5832
Revision:                    0101
Manufacturer:
Product:
Remote:                      0
Serial Number:

Bandwidth groups:  <none>

Shared folders:

Name: 'C_DRIVE', Host path: 'C:\' (machine mapping), writable, auto-mount
Name: 'D_DRIVE', Host path: 'D:\' (machine mapping), writable, auto-mount

Capturing:                   not active
Capture audio:               not active
Capture screens:             0
Capture file:                D:\VMs\mv\mv\mv.webm
Capture dimensions:          1024x768
Capture rate:                512kbps
Capture FPS:                 25kbps
Capture options:

Guest:

Configured memory balloon size: 0MB

Re: Broadcom 5880 Smart Card Reader

Posted: 1. Mar 2019, 11:21
by socratis
  1. You didn't have to include the screenshot, all the information from that screenshot are included in the "VBoxManage showvminfo", and much more.
  2. Everything seems all right. So, what you need to do now, is to read the thread from the beginning, as I already told you. And find that service that's grabbing your Smart Card...

Re: Broadcom 5880 Smart Card Reader

Posted: 1. Mar 2019, 14:14
by michal.behun
I managed to solve my issue. I didn't disable any of the services.
Problem was in missing driver for smart card itself (not reader) on host PC. After instalation of that driver, and running VM with card inserted, virtualbox captured new broadcom device, even thogh with the same IDs as original one.
Now virtualbox is able capture card reader with or without card insted. Even after uninstallation of the card driver it is still working.