sboxU.core.building_blocks package

Submodules

sboxU.core.building_blocks.butterflies module

sboxU.core.building_blocks.butterflies.closed_butterfly(alpha, beta)[source]
sboxU.core.building_blocks.butterflies.open_butterfly(alpha, beta)[source]

sboxU.core.building_blocks.cython_functions module

class sboxU.core.building_blocks.cython_functions.InsecurePRNG

Bases: object

sboxU.core.building_blocks.cython_functions.rand_S_box()
sboxU.core.building_blocks.cython_functions.rand_invertible_S_box()

sboxU.core.building_blocks.one_round_functions module

sboxU.core.building_blocks.one_round_functions.feistel_round(F1)[source]
Parameters:

F1 – an S_box-able object.

Returns:

An S_box which is the result of a classic feistel round with round function F1

sboxU.core.building_blocks.one_round_functions.swap_halves(n)[source]
Parameters:

n – The bit length of the result.

Returns:

A n-bit S_box which swaps the most significant half of the input and the least significant one.