/prange_isd

C++ implementation of the Prange information set decoding algorithm

Primary LanguageC++

README

This is a tutorial of the PrangeISD project.
For testing purposes, the following files contained in the test/ folder can be used:

  • a Hamming(7,4) code, which can correct errors with Hamming weight equal to 1, and
  • a Goppa(12,4,5) code, which can correct errors with Hamming weight up to 2.

For information about the Prange instruction set decoding algorithm, refer to: https://hackingthe.net/downloads/isd.pdf.

Compiling instructions

  1. Clone the PrangeISD project from the repository:
:::bash
  $ git clone https://github.com/agalimberti/prange_isd.git
  1. Create a bin/ folder inside the root of the project, and run make with the chosen N and K parameters:
:::bash
  $ mkdir bin
  $ make N=(codeword length) K=(message length)

Testing instructions (wrt Goppa test)

  1. Enter the test/ folder, and run g++:
:::bash
  $ cd test
  $ g++ test_prange_goppa_N12_K4.cpp -c -I../include -DN=12 -DK=4 -o test_prange_goppa_N12_K4.o
  $ g++ test_prange_goppa_N12_K4.o ../bin/prange_N12_K4.a -o test_goppa
  1. Launch the executable:
:::bash
  $ ./test_goppa