How to download ChipWhisperer Analyzer tool?

I am currently working on ChipWhisperer pro and try to understand its working. On internet I found that it has a python file of ChipWhispererAnalyzer and ChipWhispererCapture, but I am unable to find them now. Can you tell me from which website/link I have to download them? Kindly review the given link for what I am asking, I would be grateful to you for this act of kindness. The image of tool is also attached

Link: https://wiki.newae.com/CW-Analyzer_Tool#Using_the_Analyzer

This is our old GUI, which was in version 4 and earlier of ChipWhisperer. All releases are here but we really do not recommend using the old versions; we don’t update or support them.

The GUI was replaced by Jupyter notebooks; we have a comprehensive series of tutorials to teach how to use that: https://github.com/newaetech/chipwhisperer-jupyter/tree/master/courses

Thanks @jpthibault a lot for guidance but for many codes in this link needs a folder named “hardware” which is not in this git repository. Kindly tell me where can I find that folder so that I can run examples.

The chipwhisperer-jupyter repository is meant to be installed as a submodule of the main chipwhisperer repository; if you follow our installation instructions, this is what you’ll have (e.g. Windows Installation — ChipWhisperer 5.7.0 documentation for Windows, or see here for all the supported installation methods).

If you follow these instructions, then the links to “hardware” will work.

@jpthibault I have followed the instructions on this page and installed the required packages successfully, but there are no folders in jupyter notebook. Kindly see the attached image for reference.

You must have missed this step:

git submodule update --init jupyter

@jpthibault thanks a lot this resolved my issue. Can you kindly tell me where I can find AES side channel attack using power analysis code, as I want to implement it using chipwhisperer CW1200.

At the end of the installation instructions, we direct you to this notebook; we recommend you follow along, and eventually you’ll get to the sca101 series of notebooks, which feature a number of AES side channel attacks.

Thanks @jpthibault I would follow these tutorials. Can you kindly tell me why serial communication code is not working on my side. As I have tried it many time, either I get a ascii value of y^… or empty value no matter how many times I run the code.
I don’t know why it is giving this error, kindly help me out regarding this issue. I would be very grateful to you for this act of kindness.

the code I am running: http://localhost:8888/notebooks/jupyter/1%20-%20Connecting%20to%20Hardware.ipynb

I am also getting following error on respective line:

What did you send to the target? You probably sent a message that is too short; if so, the target will not respond to it.

Simpleserial commands have a fixed payload length; in the case of the “p” and “k” commands in this firmware, it’s 16 bytes (if you want to understand how this works under the hood, you can see this here).

So, if you were to send:
target.write('p' + "ff"*16 + "\n")

Then you should get back:

recv_msg += target.read()
print(recv_msg)

> rFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
> z00
1 Like

@jpthibault thanks I would try this code

@jpthibault I have tried the code but still getting no response (empty response). I am using latest drivers and Jupyter link.

When I am running following code I get this error:

Code:
%%sh
cd …/hardware/victims/firmware/simpleserial-base/
make PLATFORM= CRYPTO_TARGET=NONE

Error:
SS_VER set to SS_VER_1_1
SS_VER set to SS_VER_1_1

…/./hal/Makefile.hal:250: *** Invalid or empty PLATFORM: . Known platforms:
±------------------------------------------------------+
| PLATFORM | DESCRIPTION |
+=======================================================+
| AVR/XMEGA Targets (8-Bit RISC) |
+=======================================================+
±------------------------------------------------------+
| CWLITEXMEGA | CW-Lite XMEGA (Alias for CW303) |
±------------------------------------------------------+
| CW301_AVR | Multi-Target Board, AVR Target |
±------------------------------------------------------+
| CW303 | XMEGA Target (CWLite), Also works |
| | for CW308T-XMEGA |
±------------------------------------------------------+
| CW304 | ATMega328P (NOTDUINO), Also works |
| | for CW308T-AVR |
±------------------------------------------------------+
| CW308_MEGARF | ATMega2564RFR2 Target for CW308T |
±------------------------------------------------------+
+=======================================================+

  • ARM Cortex-M Targets (Generic) |
    +=======================================================+
    ±------------------------------------------------------+
    | CWLITEARM | CW-Lite Arm (Alias for CW308_STM32F3) |
    ±------------------------------------------------------+
    | CWNANO | CW-Lite Nano (STM32F0_NANO) |
    ±------------------------------------------------------+
    | CW308_STM32F0 | CW308T-STM32F0 (ST Micro STM32F0) |
    ±------------------------------------------------------+
    | CW308_STM32F1 | CW308T-STM32F1 (ST Micro STM32F1) |
    ±------------------------------------------------------+
    | CW308_STM32F2 | CW308T-STM32F2 (ST Micro STM32F2) |
    ±------------------------------------------------------+
    | CW308_STM32F3 | CW308T-STM32F3 (ST Micro STM32F3) |
    ±------------------------------------------------------+
    | CW308_STM32F4 | CW308T-STM32F4 (ST Micro STM32F405) |
    ±------------------------------------------------------+
    +=======================================================+
  • ARM Cortex-M Targets (Support CRYPTO_TARGET=HWAES) |
    +=======================================================+
    ±------------------------------------------------------+
    | CW308_CC2538 | CW308T-CC2538 (TI CC2538) |
    ±------------------------------------------------------+
    | CW308_ | CW308T-EFM32GG11 |
    | EFM32GG11 | (Silicon Labs Giant Gecko) |
    ±------------------------------------------------------+
    | CW308_ | CW-Lite EFM32TG11B |
    | EFM32TG11B | (Silicon Labs Tiny Geko) |
    ±------------------------------------------------------+
    | CW308_ | CW308T-EFR32MG21 (A version without |
    | EFR32MG21A | ‘secure vault’) |
    ±------------------------------------------------------+
    | CW308_ | CW308T-IMXRT1062 (iMX RT1062) |
    | IMXRT1062 | NXP “Cross-Over” Microcontroller |
    ±------------------------------------------------------+
    | CW308_K24F | CW308T-K24F (NXP Kinetis K24F) |
    ±------------------------------------------------------+
    | CW308_K82F | CW308T-K82F (NXP Kinetis K82F) |
    ±------------------------------------------------------+
    | CW308_LPC55S6X| CW308T-LPC55S69 (NXP LPC55S69) |
    ±------------------------------------------------------+
    | CW308_NRF52 | CW308T-NRF52840 (Nordic Semi) |
    ±------------------------------------------------------+
    | CW308_PSOC62 | CW308T-PSOC62 (Cypress PSOC 62) |
    ±------------------------------------------------------+
    | CW308_SAM4L | CW308T-SAM4L (Atmel SAM4L) |
    ±------------------------------------------------------+
    | CW308_SAML11 | CW-Lite SAML11 (Atmel SAML11) |
    ±------------------------------------------------------+
    | CW308_STM32F2 | CW308T-STM32F2HWC (ST Micro STM32F215)|
    ±------------------------------------------------------+
    | CW308_STM32F4 | CW308T-STM32F4HWC (ST Micro STM32F415)|
    ±------------------------------------------------------+
    | CW308_STM32L4 | CW308T-STM32L4 (ST Micro STM32L443) |
    ±------------------------------------------------------+
    | CW308_STM32L5 | CW308T-STM32L5HWC (ST Micro STM32L562)|
    ±------------------------------------------------------+
    | CW308_SAM4S | CW308T-SAM4S (Microchip SAM4S) |
    ±------------------------------------------------------+
    +=======================================================+
  • Other 32-bit Architecture |
    +=======================================================+
    ±------------------------------------------------------+
    | CW308_AURIX | CW-Lite AURIX (Infineon TC233A) |
    ±------------------------------------------------------+
    | CW308_FE310 | CW308T-FE310-G002 (RISC-V) |
    ±------------------------------------------------------+
    | CW308_ | CW308T-MPC5676R (NXP MPC5676R) |
    | MPC5676R | |
    ±--------------|---------------------------------------+
    | CW308_NEORV32 | CW308/CW312-iCE40 with neorv32 |
    | | (RISC-V) soft-core processor. |
    ±--------------|---------------------------------------+

Options to define platform:
(1) Run make with PLATFORM specified as follows:
make PLATFORM=CW304

(2) Save a file called Makefile.platform with contents:
PLATFORM=CW304
. Stop.


CalledProcessError Traceback (most recent call last)
Cell In[29], line 1
----> 1 get_ipython().run_cell_magic(‘sh’, ‘’, ‘cd …/hardware/victims/firmware/simpleserial-base/\nmake PLATFORM= CRYPTO_TARGET=NONE\n’)

File C:\Users\MYPC~1\CHIPWH~1\cw\home\portable\WPy64-31080\python-3.10.8.amd64\lib\site-packages\IPython\core\interactiveshell.py:2422, in InteractiveShell.run_cell_magic(self, magic_name, line, cell)
2420 with self.builtin_trap:
2421 args = (magic_arg_s, cell)
→ 2422 result = fn(*args, **kwargs)
2423 return result

File C:\Users\MYPC~1\CHIPWH~1\cw\home\portable\WPy64-31080\python-3.10.8.amd64\lib\site-packages\IPython\core\magics\script.py:153, in ScriptMagics._make_script_magic..named_script_magic(line, cell)
151 else:
152 line = script
→ 153 return self.shebang(line, cell)

File C:\Users\MYPC~1\CHIPWH~1\cw\home\portable\WPy64-31080\python-3.10.8.amd64\lib\site-packages\IPython\core\magics\script.py:305, in ScriptMagics.shebang(self, line, cell)
300 if args.raise_error and p.returncode != 0:
301 # If we get here and p.returncode is still None, we must have
302 # killed it but not yet seen its return code. We don’t wait for it,
303 # in case it’s stuck in uninterruptible sleep. -9 = SIGKILL
304 rc = p.returncode or -9
→ 305 raise CalledProcessError(rc, cell)

CalledProcessError: Command ‘b’cd …/hardware/victims/firmware/simpleserial-base/\nmake PLATFORM= CRYPTO_TARGET=NONE\n’’ returned non-zero exit status 2.

Kindly note that I have tried unplugging chipwhisperer, unplugging target board, resetting kernel, restarting notebook, tried same command with bash, set all the switches according to the guise, setting all the scope values (as given in guide) and restaring chipwhisperer bash.

Kindly tell me what else I can try to resolve this issue. Setting on my target board are as follow:

J1-VREF ==> J1-3.3V (CW3.3V)
J14 ==> FILT/FILT_LP/FILT_HP
J16 ==> no connection
S1 ==> ON
3.3V SRC ==> J1/CW
VADJ SRC ==> 3.3V
1.2V, 1.8V, 2.5V, 3.3V, LDO SRC ==> J1/CW
5V SRC ==> J1/CW

My target board is currently: STM32F

@jpthibault I finally managed to run the commands, turns out I was not burning hex file to my target board.

I am trying following code:

target.write(‘p’ + “ff”*16 + “\n”)
recv_msg = “”
recv_msg += target.read()
print(recv_msg)

I am getting following output, can you kindly guide me why I am getting wrong output?:
r3F5B8CC9EA855A0AFA7347D23E8D664E
z00

I would guess that you programmed the simpleserial-aes firmware instead of the simpleserial-base firmware that is intended to be used with this notebook.

1 Like

Thanks @jpthibault for your guidance.