Using Chipwhisperer 305 and Lite boards on Ubuntu 18.0.4.
When running jupyter notebook script: PA_HW_CW305_1-Attacking_AES_on_an_FPGA
Get the following error:
Traceback (most recent call last):
File "/home/jackie/chipwhisperer5/software/chipwhisperer/hardware/naeusb/naeusb.py", line 424, in get_possible_devices
devlist = [{'sn': d.serial_number, 'product': d.product, 'pid': d.idProduct, 'vid': d.idVendor} for d in devlist]
File "/home/jackie/chipwhisperer5/software/chipwhisperer/hardware/naeusb/naeusb.py", line 424, in <listcomp>
devlist = [{'sn': d.serial_number, 'product': d.product, 'pid': d.idProduct, 'vid': d.idVendor} for d in devlist]
File "/home/jackie/.local/lib/python3.6/site-packages/usb/core.py", line 830, in serial_number
self._serial_number = util.get_string(self, self.iSerialNumber)
File "/home/jackie/.local/lib/python3.6/site-packages/usb/util.py", line 314, in get_string
raise ValueError("The device has no langid")
ValueError: The device has no langid
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/jackie/chipwhisperer5/software/chipwhisperer/hardware/naeusb/naeusb.py", line 293, in txrx
response = self.get_possible_devices(payload)
File "/home/jackie/chipwhisperer5/software/chipwhisperer/hardware/naeusb/naeusb.py", line 432, in get_possible_devices
"-Not having the correct libusb backend loaded (common on Windows with 64bit Python). We try to handle this by loading the correct backend on Windows"
OSError: 'This device has no langid' ValueError caught. This is usually caused by us trying to read the serial number of the chipwhisperer, but it failing. The device is here and we can see it, but we can't access it. This has a number of root causes, including:
-Not having permission to access the ChipWhisperer (this still crops up if you have permission for one ChipWhisperer, but another ChipWhisperer is connected that you don't have access to)
-Not having the correct libusb backend loaded (common on Windows with 64bit Python). We try to handle this by loading the correct backend on Windows
---------------------------------------------------------------------------
OSError Traceback (most recent call last)
<ipython-input-2-d1177bac8d2a> in <module>
1 import chipwhisperer as cw
2
----> 3 scope = cw.scope()
4 scope.gain.db = 25
5 scope.adc.samples = 129
~/chipwhisperer5/software/chipwhisperer/__init__.py in scope(scope_type, sn)
207 from chipwhisperer.common.utils.util import get_cw_type
208 if scope_type is None:
--> 209 scope_type = get_cw_type(sn)
210 scope = scope_type()
211 scope.con(sn)
~/chipwhisperer5/software/chipwhisperer/common/utils/util.py in get_cw_type(sn)
490
491 cwusb = NAEUSB()
--> 492 possible_sn = cwusb.get_possible_devices(idProduct=possible_ids)
493 name = ""
494 if len(possible_sn) == 0:
~/chipwhisperer5/software/chipwhisperer/hardware/naeusb/naeusb.py in get_possible_devices(self, idProduct)
549
550 def get_possible_devices(self, idProduct):
--> 551 return self.usbseralizer.get_possible_devices(idProduct)
552
553 def con(self, idProduct=[0xACE2], connect_to_first=False, serial_number=None):
~/chipwhisperer5/software/chipwhisperer/hardware/naeusb/naeusb.py in get_possible_devices(self, idProduct)
129 """Get a list of connected USB devices."""
130 cmdpacket = self.make_cmd(self.GET_POSSIBLE_DEVICES, idProduct)
--> 131 return self.process_rx(self.txrx(tx=cmdpacket))
132
133 def process_rx(self, inp):
~/chipwhisperer5/software/chipwhisperer/hardware/naeusb/naeusb.py in process_rx(self, inp)
149
150 if resp == self.ERROR:
--> 151 raise payload
152
153 return payload
OSError: 'This device has no langid' ValueError caught. This is usually caused by us trying to read the serial number of the chipwhisperer, but it failing. The device is here and we can see it, but we can't access it. This has a number of root causes, including:
-Not having permission to access the ChipWhisperer (this still crops up if you have permission for one ChipWhisperer, but another ChipWhisperer is connected that you don't have access to)
-Not having the correct libusb backend loaded (common on Windows with 64bit Python). We try to handle this by loading the correct backend on Windows