|
| 1 | +# BoolCrypt 0.1 |
| 2 | + |
| 3 | +BoolCrypt is a Python 3 library for vectorial Boolean functions in cryptography. In particular, it provides the following features: |
| 4 | + |
| 5 | +- Represent vectorial Boolean functions in ANF, LUT, univariate polynomials and matrices and change one representation to another. |
| 6 | +- List of 3- 4- 5- and 6- bit affine classes and some classes of rotation-symmetric S-boxes. |
| 7 | +- Classify a list of S-boxes according to some cryptographic properties. |
| 8 | +- Find permutations, rotation-symmetric,reduced-size,... binary and non-binary polynomials. |
| 9 | +- Find whether two functions are linear or affine equivalent and count the number of linear or affine self-equivalences. |
| 10 | +- Solve functional equations and linear/affine/CCZ equivalence and self-equivalence problems using SAT solvers. |
| 11 | + |
| 12 | +Most of the functions and classes in BoolCrypt contain many examples of their usage in their docstrings, |
| 13 | +also available in the HTML documentation in [html_documentation.zip](html_documentation.zip). |
| 14 | + |
| 15 | +BoolCrypt was proposed in [Implicit White-Box Implementations: White-Boxing ARX Ciphers](https://eprint.iacr.org/2022/XXX), |
| 16 | +and it is a dependency of [whiteboxarx](https://github.com/ranea/whiteboxarx). |
| 17 | + |
| 18 | +## Installation |
| 19 | + |
| 20 | +BoolCrypt requires Python >= 3.7 and SageMath >= 9.1. |
| 21 | +Although BoolCrypt is meant to be used as a Python library, it can also be used in a Sage shell. |
| 22 | + |
| 23 | +Solving functional equations or equivalence problems requires CryptoMiniSat, which can be installed in SageMath by |
| 24 | +``` |
| 25 | +sage -i cryptominisat |
| 26 | +``` |
| 27 | + |
| 28 | +BoolCrypt also requires [sboxU](https://github.com/lpp-crypto/sboxU) v1.0., |
| 29 | +but with some modifications described in [modifications_sboxU.md](modifications_sboxU.md). |
| 30 | +A modified version of sboxU is given in the directory [sboxU](sboxU). |
| 31 | +Then compile the modified sboxU by |
| 32 | +``` |
| 33 | +cd sboxU/sboxU_cython |
| 34 | +sage setup.py build_ext --inplace |
| 35 | +``` |
0 commit comments