Energy Testing Tool Overview and Requirements - crt26/PQC-LEO GitHub Wiki

Available Automated Testing Tools

The automated testing scripts provided by PQC-LEO currently support three types of energy usage testing:

  • PQC computational energy usage testing
  • TLS handshake energy usage testing
  • TLS operations energy usage testing

PQC Computational Energy Usage Testing

This testing category evaluates the energy usage of the raw cryptographic operations performed by the supported PQC algorithms provided by the Liboqs library. It supports key generation, encapsulation, and decapsulation testing for KEM algorithms, as well as key generation, signing, and verification testing for digital signature algorithms.

TLS Handshake Energy Usage Testing

This testing category evaluates the energy usage of supported PQC, Hybrid-PQC, and classical algorithms within a TLS 1.3 handshake. PQC and Hybrid-PQC testing uses signing-algorithm/KEM pairings, while classical testing uses every configured signing-algorithm/key-exchange-group/ciphersuite combination.

TLS Operations Energy Usage Testing

This testing category evaluates the energy usage of PQC, Hybrid-PQC, and classical algorithms when performing cryptographic operations through the OpenSSL command-line tool. This includes the overhead introduced by using these algorithms through the OpenSSL library. It supports key generation, encapsulation, and decapsulation for PQC/Hybrid-PQC KEMs; key generation, signing, and verification for PQC/Hybrid-PQC and classical digital signatures; and key generation and shared-secret derivation for classical key-exchange algorithms.

Software and Hardware Requirements

General Requirements

To utilise the automated testing script for PQC energy usage evaluation, there are a few general requirements and details to be aware of:

  • On the testing machine, select installation mode 1 or 2 for computational testing, or mode 2 (or 3 with an existing computational setup) for TLS testing, and enable the energy usage testing tools when prompted. Use mode 4 for a collector-only machine.

  • A supported energy meter must be properly set up and configured for use with the testing scripts. For details on supported energy meters and testing environment setup instructions, please refer to the Supported Energy Meters page.

  • A sufficient form of communication between the testing and collection machine must be available and operational for control signalling to effectively take place. For details on the required communication setup and configuration, please refer to the Enabling Support for Test Control Signalling section.

All setup modes use the OpenSSL Compatibility for Energy Tools. The automated collector and computational energy scripts configure LD_LIBRARY_PATH for the project build when selected during setup; manual tool execution requires the library path configuration described in the tool usage guides.

Supported Hardware

The automated testing tool is currently only supported on the following devices:

  • x86 Linux Machines using a Debian-based operating system
  • ARM Linux devices using a 64-bit Debian-based Operating System

To collect energy usage metrics during testing, a collection machine must be used in conjunction with the testing machine and energy meter. The collection machine must also be a supported device and must be able to communicate with the energy meter to collect the energy usage metrics data during testing.

Supported Energy Meters

The automated energy testing scripts and collection tools provided by PQC-LEO are designed to support a variety of energy meters. However, current support is limited. The tools have been developed to allow users to add support for new energy meters with relative ease, while continued development aims to provide support for additional energy meters in the future.

For details on the currently supported energy meters and instructions for configuring them for use with the testing scripts, please refer to the following wiki page:

Supported Energy Meters

For details on how to add support for new energy meters, please refer to the following wiki page:

Integrating New Energy Meters

Supported Algorithms

The algorithms supported for energy usage testing depend on the testing category, as detailed below.

Computational energy testing covers PQC algorithms from Liboqs. TLS handshake and TLS operations energy testing cover PQC, Hybrid-PQC, and classical algorithms. Classical TLS operations energy testing includes all configured classical digital signature and key-exchange algorithms. The following OpenSSL Hybrid-PQC KEMs are exceptions and are not supported by TLS operations energy testing because the required key encoders are unavailable:

  • X25519MLKEM768
  • X448MLKEM1024
  • SecP256r1MLKEM768
  • SecP384r1MLKEM1024
  • curveSM2MLKEM768

For RSA signature measurements, the TLS operations energy test explicitly selects PSS padding. This permits separate results for generic RSA keys (RSA_*) and RSA-PSS-restricted keys (RSA-PSS_*), which the standard openssl speed command cannot test as distinct categories.

For further details on supported algorithms, please refer to the following wiki page:

Supported Algorithms

⚠️ **GitHub.com Fallback** ⚠️