Skip to content

Testing

Overview

This document presents the current status and progress of testing the TwPM module features. The tests used here are located in the Dasharo OSFV repository.

Tests results

The latest results (as of 14/03/2024) can be found here. It was run on Protectli VP6670, TwPM was connected through SPI interface. Previous version (running on LPC) is available here.

Hardware setup

Hardware list

Connection to the platform

Follow the mainboard connection tutorial. In case of LPC, make sure that LCLK and LAD lines aren't directly next to each other (e.g. separate those with GND), otherwise inter-signal noise would cause bad reads. No such interference was observed for SPI.

Development connection

The Orange Crab still requires reflashing over UART during testing, that is why the USB-UART converter must also be connected.

Running tests

  • Follow the Getting started section of test repository first

  • Apply the following diff if not using RTE. Adjust OS credentials to your case. Follow that issue for progress on improving the testing experience with no additional hardware involved.

  • Execute a selection of test:

At the moment, CreatePrimary() is not supported, that is why tests using it are excluded from the suite. More information can be found in this issue. Replace $DEVICE_IP with the IP address of your device, where TwPM is connected. It is assumed running Ubuntu 22.04 OS with OpenSSH server enabled via password authentication. For this test suite, both VP4670 and VP6670 may use protectli-vp4670 configuration.

robot -L TRACE -v device_ip:$DEVICE_IP -v config:protectli-vp4670 -v snipeit:no -t "TPMCMD00[0-469]*" -t "TPMCMD010*" dasharo-security/tpm2-commands.robot