cascada.primitives.lea module

LEA 128-bit cipher.

class cascada.primitives.lea.LEAKeySchedule(*args, **options)[source]

Bases: cascada.bitvector.ssa.RoundBasedFunction

Key schedule function.

classmethod set_num_rounds(new_num_rounds)[source]

Set RoundBasedFunction.num_rounds and update input_widths and output_widths if necessary.

classmethod eval(k0, k1, k2, k3)[source]

Evaluate the function (internal method).

class cascada.primitives.lea.LEAEncryption(*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 update input_widths and output_widths if necessary.

classmethod eval(p0, p1, p2, p3)[source]

Evaluate the function (internal method).

class cascada.primitives.lea.LEACipher(plaintext, masterkey, **options)[source]

Bases: cascada.primitives.blockcipher.Cipher

LEA-128 cipher.

key_schedule

alias of cascada.primitives.lea.LEAKeySchedule

encryption

alias of cascada.primitives.lea.LEAEncryption

classmethod set_num_rounds(new_num_rounds)[source]

Call RoundBasedFunction.set_num_rounds of key_schedule and encryption (if iterated).