Skip to content

Commit

Permalink
Merge branch 'develop' of github.com:newaetech/chipwhisperer into dev…
Browse files Browse the repository at this point in the history
…elop
  • Loading branch information
alex-dewar committed Jun 6, 2022
2 parents 2dcf45a + 7aa97c9 commit f17e71d
Show file tree
Hide file tree
Showing 8 changed files with 43 additions and 14 deletions.
6 changes: 3 additions & 3 deletions README.md
Expand Up @@ -17,23 +17,23 @@ chipwhisperer.readthedocs.io
## Getting Started
First time using ChipWhisperer? Check out these links:
* [Getting started](https://chipwhisperer.readthedocs.io/en/latest/getting-started.html)
* [Installing ChipWhisperer](https://chipwhisperer.readthedocs.io/en/latest/installing.html) if you're trying to set up this software package
* [Installing ChipWhisperer](https://chipwhisperer.readthedocs.io/en/latest/index.html#install) if you're trying to set up this software package
* [Hardware Docs](https://rtfm.newae.com) for hardware information. Also has helpful comparison between different NewAE products.

## ChipWhisperer 5.5: All-in-one installer, Serial Port, ECC, and Segmented Capture

ChipWhisperer 5.5 has brought some exciting new features that make it easier to use and allow you to do some cool new things:

1. The ChipWhisperer Windows installer now includes everything you need to use ChipWhisperer, including
Python/Juptyer, Git, Make, and compilers! For more information, check out our [Windows installer page](https://chipwhisperer.readthedocs.io/en/latest/installing.html#windows-installer) on ReadTheDocs.
Python/Juptyer, Git, Make, and compilers! For more information, check out our [Windows installer page](https://chipwhisperer.readthedocs.io/en/latest/windows-install.html) on ReadTheDocs.
1. ChipWhisperer capture devices (CWLite, Nano, Pro, etc.) have gotten a new firmware update that gives them a
USB-CDC serial port for talking over USART. This means you can use your favourite serial program, such as PuTTy,
to talk to and listen to the target's USART communication. For more info, see our [rtfm serial port page](https://rtfm.newae.com/Serial%20Ports/).
1. We've recently added two ECC power analysis attack notebooks. One attacks a hardware ECC implementation running on the CW305
and the other attacks a software ECC implementation running on a microcontroller. Both can be found in `jupyter/demos`.
1. There's a new segmented capture mode that allows you to fill the ChipWhisperer capture buffer with multiple power traces
before transferring data to the PC. This greatly reduces the overhead on trace transfer, allowing capture speeds
of 1000+ captures/second for FPGA AES implementations. See our [API documentation](https://chipwhisperer.readthedocs.io/en/latest/api.html#chipwhisperer.capture.scopes._OpenADCInterface.OpenADC.TriggerSettings.fifo_fill_mode) to see how to use it.
of 1000+ captures/second for FPGA AES implementations. See our [API documentation](https://chipwhisperer.readthedocs.io/en/latest/scope-api.html#chipwhisperer.capture.scopes._OpenADCInterface.TriggerSettings.fifo_fill_mode) to see how to use it.

Also, if you haven't checked it out yet, ChipWhisperer 5.4 included TraceWhisperer, which allows you to use Arm trace to
timestamp microcontroller operations/functions in your powertrace. It requires a CW305 or PhyWhisperer. For more information, see
Expand Down
2 changes: 1 addition & 1 deletion cw_openocd.cfg
Expand Up @@ -16,7 +16,7 @@ adapter driver ftdi

ftdi channel 1
ftdi layout_init 0x001B 0x001B
ftdi layout_signal nTRST -data 0x0010 -oe 0x0010
#ftdi layout_signal nTRST -data 0x0010 -oe 0x0010

ftdi layout_signal SWD_EN -data 0x0100
ftdi layout_signal SWDIO_OE -data 0x0200
6 changes: 3 additions & 3 deletions docs/conf.py
Expand Up @@ -115,9 +115,9 @@
html_sidebars = {
'index': ['about.html', 'testtoc.html', 'searchbox.html'],
'api': ['about.html', 'navigation.html', 'searchbox.html'],
'prerequisites': ['about.html', 'navigation.html', 'searchbox.html'],
'tutorials': ['about.html', 'navigation.html', 'searchbox.html'],
'install': ['about.html', 'navigation.html', 'searchbox.html'],
'prerequisites': ['about.html', 'testtoc.html', 'searchbox.html'],
'tutorials': ['about.html', 'testtoc.html', 'searchbox.html'],
'installing': ['about.html', 'testtoc.html', 'searchbox.html'],
'**': ['about.html', 'localtoc.html', 'searchbox.html']
}

Expand Down
34 changes: 33 additions & 1 deletion docs/debugging.rst
Expand Up @@ -147,7 +147,7 @@ a firmware file onto the target:
targets
halt
flash write_image erase /path/to/fw.elf
verify image /path/to/fw.elf
flash verify_image /path/to/fw.elf
reset run
shutdown
Expand Down Expand Up @@ -212,6 +212,38 @@ ChipWhisperer via the Python interface and via OpenOCD at the same time.
General Limitations
===================

Feature Limitations
-------------------

Pin Based Limitations
^^^^^^^^^^^^^^^^^^^^^

MPSSE mode takes control of some ChipWhisperer pins, meaning the following features will not be available:

* Non MPSSE target programming (STM32, XMEGA, AVR)
* ChipWhisperer-Husky stream mode
* Control of PDIC, PDID, and the SPI pins

You can give normal functionality back to these pins by running the following::

scope.io.cwe.setAVRISPMode(0)

MPSSE can be reenabled by running the following command::

scope.io.cwe.setAVRISPMode(1)

Other Limitations
^^^^^^^^^^^^^^^^^^^^^

The following features are not available when MPSSE mode is active:

* CDC serial (normal cw.target based serial still works)
* ChipWhisperer-Pro stream mode

To regain usage of these features, you must leave MPSSE mode by running::

scope.enable_MPSSE(0)

Communication Speed
-------------------

Expand Down
2 changes: 1 addition & 1 deletion docs/index.rst
Expand Up @@ -116,6 +116,6 @@ and will be removed in the future:
.. toctree::

api <api.rst>
install <install.rst>
install <installing.rst>
prerequisites <prerequisites.rst>
tutorials <tutorials.rst>
File renamed without changes.
2 changes: 1 addition & 1 deletion hardware/victims/firmware/hal/Makefile.hal
Expand Up @@ -105,7 +105,7 @@ define KNOWN_PLATFORMS
| CW308_ | CW308T-MPC5676R (NXP MPC5676R) |
| MPC5676R | |
+---------------|---------------------------------------+
| CW308_NEORV | CW308/CW312-iCE40 with neorv32 |
| CW308_NEORV32 | CW308/CW312-iCE40 with neorv32 |
| | (RISC-V) soft-core processor. |
+---------------|---------------------------------------+

Expand Down
5 changes: 1 addition & 4 deletions software/chipwhisperer/analyzer/attacks/_stats.py
Expand Up @@ -209,10 +209,7 @@ def find_maximums(self, bytelist=None, use_absolute=True, use_single=False):
mvalue = v

#Get maximum value for this hypothesis
try:
mindex = np.amin(np.where(v == mvalue))
except ValueError:
mindex = self.numPerms-1
mindex = np.nanargmax(np.fabs(self.diffs[i][hyp]))
self.maxes[i][hyp]['hyp'] = hyp
self.maxes[i][hyp]['point'] = mindex
self.maxes[i][hyp]['value'] = mvalue
Expand Down

0 comments on commit f17e71d

Please sign in to comment.