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.RoundBasedFunctionKey schedule function.
- classmethod set_num_rounds(new_num_rounds)[source]
Set
RoundBasedFunction.num_roundsand updateinput_widthsandoutput_widthsif necessary.
- class cascada.primitives.hight.HightEncryption(*args, **options)[source]
Bases:
cascada.primitives.blockcipher.Encryption,cascada.bitvector.ssa.RoundBasedFunctionEncryption function.
- classmethod set_num_rounds(new_num_rounds)[source]
Set
RoundBasedFunction.num_roundsand updateinput_widthsandoutput_widthsif necessary.
- class cascada.primitives.hight.HightCipher(plaintext, masterkey, **options)[source]
Bases:
cascada.primitives.blockcipher.CipherHIGHT cipher.
- key_schedule
- encryption
- classmethod set_num_rounds(new_num_rounds)[source]
Call
RoundBasedFunction.set_num_roundsofkey_scheduleandencryption(if iterated).