debian + virtualbox с Win XP

Здравствуйте!
Сервер с debian x64
# uname -a
Linux server 3.16.0-4-amd64 #1 SMP Debian 3.16.7-ckt20-1+deb8u4 (2016-02-29) x86_64 GNU/Linux

на нем виртуалка Virtualbox с WinXP
# vboxmanage --version
5.0.16r105871

# lsusb | grep 0a89
Bus 007 Device 004: ID 0a89:0020 - рутокен S

# udevadm info -a /dev/vboxusb/007/004

Udevadm info starts with the device specified by the devpath and then
walks up the chain of parent devices. It prints for every device
found, all possible attributes in the udev rules key format.
A rule to match, can be composed by the attributes of the device
and the attributes from one single parent device.

  looking at device '/devices/pci0000:00/0000:00:12.0/usb7/7-1':
    KERNEL=="7-1"
    SUBSYSTEM=="usb"
    DRIVER=="usb"
    ATTR{bDeviceSubClass}=="00"
    ATTR{bDeviceProtocol}=="00"
    ATTR{devpath}=="1"
    ATTR{idVendor}=="0a89"
    ATTR{speed}=="12"
    ATTR{bNumInterfaces}==" 1"
    ATTR{bConfigurationValue}=="1"
    ATTR{bMaxPacketSize0}=="64"
    ATTR{busnum}=="7"
    ATTR{devnum}=="4"
    ATTR{configuration}==""
    ATTR{bMaxPower}=="100mA"
    ATTR{authorized}=="1"
    ATTR{bmAttributes}=="80"
    ATTR{bNumConfigurations}=="1"
    ATTR{maxchild}=="0"
    ATTR{bcdDevice}=="0200"
    ATTR{avoid_reset_quirk}=="0"
    ATTR{quirks}=="0x0"
    ATTR{version}==" 2.00"
    ATTR{urbnum}=="12"
    ATTR{ltm_capable}=="no"
    ATTR{manufacturer}=="Aktiv Co."
    ATTR{removable}=="unknown"
    ATTR{idProduct}=="0020"
    ATTR{bDeviceClass}=="ff"
    ATTR{product}=="Rutoken S"

  looking at parent device '/devices/pci0000:00/0000:00:12.0/usb7':
    KERNELS=="usb7"
    SUBSYSTEMS=="usb"
    DRIVERS=="usb"
    ATTRS{bDeviceSubClass}=="00"
    ATTRS{bDeviceProtocol}=="00"
    ATTRS{devpath}=="0"
    ATTRS{idVendor}=="1d6b"
    ATTRS{speed}=="12"
    ATTRS{bNumInterfaces}==" 1"
    ATTRS{bConfigurationValue}=="1"
    ATTRS{bMaxPacketSize0}=="64"
    ATTRS{authorized_default}=="1"
    ATTRS{busnum}=="7"
    ATTRS{devnum}=="1"
    ATTRS{configuration}==""
    ATTRS{bMaxPower}=="0mA"
    ATTRS{authorized}=="1"
    ATTRS{bmAttributes}=="e0"
    ATTRS{bNumConfigurations}=="1"
    ATTRS{maxchild}=="5"
    ATTRS{bcdDevice}=="0316"
    ATTRS{avoid_reset_quirk}=="0"
    ATTRS{quirks}=="0x0"
    ATTRS{serial}=="0000:00:12.0"
    ATTRS{version}==" 1.10"
    ATTRS{urbnum}=="91"
    ATTRS{ltm_capable}=="no"
    ATTRS{manufacturer}=="Linux 3.16.0-4-amd64 ohci_hcd"
    ATTRS{removable}=="unknown"
    ATTRS{idProduct}=="0001"
    ATTRS{bDeviceClass}=="09"
    ATTRS{product}=="OHCI PCI host controller"

  looking at parent device '/devices/pci0000:00/0000:00:12.0':
    KERNELS=="0000:00:12.0"
    SUBSYSTEMS=="pci"
    DRIVERS=="ohci-pci"
    ATTRS{irq}=="18"
    ATTRS{subsystem_vendor}=="0x1043"
    ATTRS{broken_parity_status}=="0"
    ATTRS{class}=="0x0c0310"
    ATTRS{driver_override}=="(null)"
    ATTRS{consistent_dma_mask_bits}=="32"
    ATTRS{dma_mask_bits}=="32"
    ATTRS{local_cpus}=="00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,0000000f"
    ATTRS{device}=="0x7807"
    ATTRS{enable}=="1"
    ATTRS{msi_bus}==""
    ATTRS{local_cpulist}=="0-3"
    ATTRS{vendor}=="0x1022"
    ATTRS{subsystem_device}=="0x85ca"
    ATTRS{numa_node}=="-1"
    ATTRS{d3cold_allowed}=="0"

  looking at parent device '/devices/pci0000:00':
    KERNELS=="pci0000:00"
    SUBSYSTEMS==""
    DRIVERS==""

https://forum.rutoken.ru/uploads/transfer/0/9500/9697/thumb/p1akng3f1fu561s6fvc1u5tbta1.png

Почему не получается проборосить RuToken S в virtualbox ?

Re: debian + virtualbox с Win XP

Здравствуйте, 2754425@gmail.com.

Уточните, пожалуйста, установлен ли драйвер для Рутокен S в среде хост-ОС и в гостевой?

(2016-06-08 18:52:04 отредактировано 2754425@gmail.com)

Re: debian + virtualbox с Win XP

# dpkg -l pcscd libccid libpcsclite1
||/ Имя                                     Версия                   Архитектура              Описание
+++-=======================================-========================-========================-===================================================================================
ii  libccid                                 1.4.18-1                 amd64                    PC/SC driver for USB CCID smart card readers
ii  libpcsclite1:amd64                      1.8.13-1                 amd64                    Middleware to access a smart card using PC/SC (library)
ii  pcscd                                   1.8.13-1                 amd64                    Middleware to access a smart card using PC/SC (daemon side)
# cat /usr/lib/pcsc/drivers/ifd-ccid.bundle/Contents/Info.plist | grep 0x0A89
        <string>0x0A89</string>
        <string>0x0A89</string>
        <string>0x0A89</string>
        <string>0x0A89</string>
        <string>0x0A89</string>
# cat /usr/lib/pcsc/drivers/ifd-ccid.bundle/Contents/Info.plist | grep 0x0020
                <string>0x0020</string>
# cat /usr/lib/pcsc/drivers/ifd-ccid.bundle/Contents/Info.plist | grep "Aktiv Rutoken lite"
        <string>Aktiv Rutoken lite</string>

+ я даже добавил в него

# cat /usr/lib/pcsc/drivers/ifd-ccid.bundle/Contents/Info.plist | grep "Aktiv Co. Rutoken S"
                <string>Aktiv Co. Rutoken S</string>
# /usr/sbin/pcscd -afddddd
00000000 debuglog.c:292:DebugLogSetLevel() debug level=debug
00000052 debuglog.c:292:DebugLogSetLevel() debug level=debug
00000024 debuglog.c:292:DebugLogSetLevel() debug level=debug
00000016 debuglog.c:292:DebugLogSetLevel() debug level=debug
00000017 debuglog.c:292:DebugLogSetLevel() debug level=debug
00000181 configfile.l:283:DBGetReaderListDir() Parsing conf directory: /etc/reader.conf.d
00000060 configfile.l:317:DBGetReaderListDir() Skipping non regular file: .
00000023 configfile.l:317:DBGetReaderListDir() Skipping non regular file: ..
00000021 configfile.l:355:DBGetReaderList() Parsing conf file: /etc/reader.conf.d/libccidtwin
00000083 pcscdaemon.c:569:main() pcsc-lite 1.8.13 daemon ready.
00002431 hotplug_libudev.c:296:get_driver() Looking for a driver for VID: 0x1D6B, PID: 0x0002, path: /dev/bus/usb/003/001
00000197 hotplug_libudev.c:296:get_driver() Looking for a driver for VID: 0x1D6B, PID: 0x0003, path: /dev/bus/usb/004/001
00000207 hotplug_libudev.c:296:get_driver() Looking for a driver for VID: 0x1D6B, PID: 0x0002, path: /dev/bus/usb/005/001
00000182 hotplug_libudev.c:296:get_driver() Looking for a driver for VID: 0x1D6B, PID: 0x0003, path: /dev/bus/usb/006/001
00000203 hotplug_libudev.c:296:get_driver() Looking for a driver for VID: 0x1D6B, PID: 0x0001, path: /dev/bus/usb/007/001
00000138 hotplug_libudev.c:296:get_driver() Looking for a driver for VID: 0x1D6B, PID: 0x0001, path: /dev/bus/usb/007/001
00000160 hotplug_libudev.c:296:get_driver() Looking for a driver for VID: 0x0A89, PID: 0x0020, path: /dev/bus/usb/007/005
00000026 hotplug_libudev.c:435:HPAddDevice() [b]Adding USB device: Aktiv Co. Rutoken S[/b]
00000071 readerfactory.c:1012:RFInitializeReader() Attempting startup of Aktiv Co. Rutoken S 00 00 using /usr/lib/pcsc/drivers/ifd-rutokens.bundle/Contents/Linux/librutokens.so
00000267 readerfactory.c:897:RFBindFunctions() Loading IFD Handler 3.0
00285305 readerfactory.c:355:RFAddReader() Using the reader polling thread
00002306 hotplug_libudev.c:296:get_driver() Looking for a driver for VID: 0x1D6B, PID: 0x0002, path: /dev/bus/usb/001/001
00000214 hotplug_libudev.c:296:get_driver() Looking for a driver for VID: 0x1D6B, PID: 0x0001, path: /dev/bus/usb/008/001
00000228 hotplug_libudev.c:296:get_driver() Looking for a driver for VID: 0x1D6B, PID: 0x0002, path: /dev/bus/usb/002/001
00000110 readerfactory.c:1353:RFWaitForReaderInit() Waiting init for reader: Aktiv Co. Rutoken S 00 00
00009142 eventhandler.c:289:EHStatusHandlerThread() powerState: POWER_STATE_POWERED
00000050 Card ATR: 3B 6F 00 FF 00 56 72 75 54 6F 6B 6E 73 30 20 00 00 90 00 
# pcsc_scan 
PC/SC device scanner
V 1.4.23 (c) 2001-2011, Ludovic Rousseau <ludovic.rousseau@free.fr>
Compiled with PC/SC lite version: 1.8.11
Using reader plug'n play mechanism
Scanning present readers...
0: Aktiv Co. Rutoken S 00 00

Wed Jun  8 18:50:48 2016
Reader 0: Aktiv Co. Rutoken S 00 00
  Card state: Card inserted, 
  ATR: 3B 6F 00 FF 00 56 72 75 54 6F 6B 6E 73 30 20 00 00 90 00

ATR: 3B 6F 00 FF 00 56 72 75 54 6F 6B 6E 73 30 20 00 00 90 00
+ TS = 3B --> Direct Convention
+ T0 = 6F, Y(1): 0110, K: 15 (historical bytes)
  TB(1) = 00 --> VPP is not electrically connected
  TC(1) = FF --> Extra guard time: 255 (special value)
+ Historical bytes: 00 56 72 75 54 6F 6B 6E 73 30 20 00 00 90 00
  Category indicator byte: 00 (compact TLV data object)
    Tag: 5, len: 6 (card issuer's data)
      Card issuer data: 72 75 54 6F 6B 6E
    Tag: 7, len: 3 (card capabilities)
      Selection methods: 30
        - DF selection by path
        - DF selection by file identifier
      Data coding byte: 20
        - Behaviour of write functions: proprietary
        - Value 'FF' for the first byte of BER-TLV tag fields: invalid
        - Data unit in quartets: 1
      Command chaining, length fields and logical channels: 00
        - Logical channel number assignment: No logical channel
        - Maximum number of logical channels: 1
    Mandatory status indicator (3 last bytes)
      LCS (life card cycle): 00 (No information given)
      SW: 9000 (Normal processing.)

Possibly identified card (using /usr/share/pcsc/smartcard_list.txt):
3B 6F 00 FF 00 56 72 75 54 6F 6B 6E 73 30 20 00 00 90 00
    ruToken-S (USB token)
    https://www.rutoken.ru/products/rutoken/rutoken-s/
^C

Re: debian + virtualbox с Win XP

в Гостевой ОС я драйвер еще не устанавливал, так как виртуалбокс не видит usb устройства, чтоб передать его на гостевую ОС.

Re: debian + virtualbox с Win XP

Пользователь добавлен в группу vboxusers?

Re: debian + virtualbox с Win XP

Какой пользователь?

Re: debian + virtualbox с Win XP

Текущий пользователь хост-ОС.

Немного ссылок про VirtualBox и Linux:

Re: debian + virtualbox с Win XP

# ps aux | grep Windows
vbox      5370  3.0 32.4 3973948 2282136 ?     Sl   июн08  53:25 /usr/lib/virtualbox/VBoxHeadless --comment Windows XP --startvm 8a66505c-9957-491d-94e3-8e8f16052d9f --vrde config

# groups  vbox
vbox : vbox vboxusers

# ls -l /dev/vboxusb/007/006 
crw-rw---- 1 root vboxusers 189, 773 июн  9 15:42 /dev/vboxusb/007/006

# udevadm info -a /dev/vboxusb/007/006 
looking at device '/devices/pci0000:00/0000:00:12.0/usb7/7-1':
    KERNEL=="7-1"
    SUBSYSTEM=="usb"
    DRIVER=="usb"
    ATTR{bDeviceSubClass}=="00"
    ATTR{bDeviceProtocol}=="00"
    ATTR{devpath}=="1"
    ATTR{idVendor}=="0a89"
    ATTR{speed}=="12"
    ATTR{bNumInterfaces}==" 1"
    ATTR{bConfigurationValue}=="1"
    ATTR{bMaxPacketSize0}=="64"
    ATTR{busnum}=="7"
    ATTR{devnum}=="6"
    ATTR{configuration}==""
    ATTR{bMaxPower}=="100mA"
    ATTR{authorized}=="1"
    ATTR{bmAttributes}=="80"
    ATTR{bNumConfigurations}=="1"
    ATTR{maxchild}=="0"
    ATTR{bcdDevice}=="0200"
    ATTR{avoid_reset_quirk}=="0"
    ATTR{quirks}=="0x0"
    ATTR{version}==" 2.00"
    ATTR{urbnum}=="20"
    ATTR{ltm_capable}=="no"
    ATTR{manufacturer}=="Aktiv Co."
    ATTR{removable}=="unknown"
    ATTR{idProduct}=="0020"
    ATTR{bDeviceClass}=="ff"
    ATTR{product}=="Rutoken S"
... и т.д.

# vboxmanage showvminfo 'Windows XP'
...
USB Device Filters:

<none>

Available remote USB devices:

<none>

Currently Attached USB Devices:

<none>

...

блин блинский

Re: debian + virtualbox с Win XP

Здравствуйте 2754425@gmail.com,

Воспроизвели вашу проблему на:
Linux debian 3.16.0-4-amd64 #1 SMP Debian 3.16.7-ckt25-2 (2016-04-08) x86_64 GNU/Linux,
VirtualBox 5.0.22r108108 (последняя версия на 22.06.2016) WinXP Professional SP3,
Дополнительные пакеты и драйверы в Debian для работы с Рутокен S не устанавливались,
https://forum.rutoken.ru/uploads/transfer/0/9500/9726/thumb/p1alrlqgsps00j93lqv1ea01jim1.png

Попробуйте обновить VirtualBox до версии 5.0.22r108108, запустить его из под пользователя root, и пробросить Рутокен в USB устройствах.