International Association for Cryptologic Research

International Association
for Cryptologic Research

Transactions on Cryptographic Hardware and Embedded Systems 2026

ARMOR:

First-Order Masking of Activation and ArgMax Gadgets for Side-Channel Resistant Neural Networks


README

ARMOR: First-Order Masking of Activation and ArgMax Gadgets for Side-Channel Resistant Neural Networks

This artifact provides an implementation of our paper ARMOR: First-Order Masking of Activation and ArgMax Gadgets for Side-Channel Resistant Neural Networks accepted at TCHES 2026, Issue 2.

The artifact includes:

Requirements

Tested on:

System dependencies:

The MNIST dataset files required for our experiments were converted into a single combined file containing both images and labels:

This artifact uses the MNIST dataset, which is third-party material. The file data/combined.bytes is derived from the MNIST dataset. MNIST is distributed under the Creative Commons Attribution-Share Alike 3.0 license. Source: http://yann.lecun.com/exdb/mnist/

Running the Experiments

Build

Compile the project with:

make

Run

This artifact provides two evaluation modes:

The desired mode is selected via a command-line argument:

Additionally, the user can select the MNIST dataset size, up to a maximum of 10,000 samples.

For example, to run the accuracy loss measurement with 10,000 MNIST samples illustrated in Table 4:

./test 1 10000

The expected result includes label loss, which measures whether the predicted label differs from the true label:

hidden layer node loss: 0
hidden layer loss: 0
output layer loss: 0
output loss: 0
label loss: 1097