Trx Checker
Script for verifying the parameters generated by Trx.
All relevant information about Trx can be found on: http://trx.epfl.ch/
Verification consists of two parts:
- SlothUnicorn verification: Check if sloth hash generated by Trx is indeed generated from given tweets and image files.
- Trx verification: Check if generated elliptic curve parameters are OK.
For running the script, you need Python, Sage and Magma installed.
- Script is implemented in Python.
- Sage is used because of its interface to Magma.
- Magma is used for SEA algorithm, because the SEA implementation in Sage does not support early abort and this is huge efficiency problem.
Following command runs the script:
sage -python trx_checker.py
For available options add '-h'. There is one mandatory command line argument:
- the name of the directory where all the needed files are located. Optional arguments are:
- -t NUM_THREADS, set number of threads to be used
- -ss, skip verification of Sloth
- -sc, skip verification of curve parameters
- -r , use the information from rejected_curves file in process of curve parameter verification(this will speed up the verification)
Script expects to find given directory in curve_parameters directory, so if you want to check parameters for one of the curves published on the website (http://trx.epfl.ch/), just download the corresponding .zip file end extract it to the curve_parameters directory.
Example: Check parameters for curve located in dir '128_664'
sage -python trx_checker.py 128_664
The result will be dumped in the same directory in the file named 'trx_checker_output.txt'