cascada.primitives.hight module
HIGHT cipher.
While HIGHT is defined for 32 rounds, this implementation considers 34 rounds, where the first and last round are the initial and final key-whitening.
- class cascada.primitives.hight.HightKeySchedule(*args, **options)[source]
Bases:
cascada.bitvector.ssa.RoundBasedFunction
Key schedule function.
- classmethod set_num_rounds(new_num_rounds)[source]
Set
RoundBasedFunction.num_rounds
and updateinput_widths
andoutput_widths
if necessary.
- class cascada.primitives.hight.HightEncryption(*args, **options)[source]
Bases:
cascada.primitives.blockcipher.Encryption
,cascada.bitvector.ssa.RoundBasedFunction
Encryption function.
- classmethod set_num_rounds(new_num_rounds)[source]
Set
RoundBasedFunction.num_rounds
and updateinput_widths
andoutput_widths
if necessary.
- class cascada.primitives.hight.HightCipher(plaintext, masterkey, **options)[source]
Bases:
cascada.primitives.blockcipher.Cipher
HIGHT cipher.
- key_schedule
- encryption
- classmethod set_num_rounds(new_num_rounds)[source]
Call
RoundBasedFunction.set_num_rounds
ofkey_schedule
andencryption
(if iterated).