diff --git a/main.py b/main.py index 8c34d3e2a9da52852dacc58da9c896ab68054491..994ec918b4e97f0c0934dabb8c8b68daf7b3eb0f 100644 --- a/main.py +++ b/main.py @@ -5,7 +5,54 @@ Date : 2022 """ +def add_mod(a, b): + pass + + +def mul_mod(a, b): + pass + + +def xor(a, b): + pass + + +def modulo(a, b): + # euclide + pass + + +def create_key_tables(): + pass + + +def round(): + # 1. Multiply X1 and the first subkey Z1 + # 2. Add X2 and the second subkey Z2 + # 3. Add X3 and the third subkey Z3 + # 4. Multiply X4 and the fourth subkey Z4 + + # Don't do the next steps if this is the final round + + # 5. Bitwise XOR the results of steps 1 and 3 + # 6. Bitwise XOR the results of steps 2 and 4 + # 7. Multiply the result of step 5 and the fifth subkey Z5 + # 8. Add the results of step 6 and 7 + # 9. Multiply the result of step 8 and the sisth subkey Z6 + # 10. Add the results of steps 7 and 9 + # 11. Bitwise XOR the results of steps 1 and 9 + # 12. Bitwise XOR the results of steps 3 and 9 + # 13. Bitwise XOR the results of steps 2 and 10 + # 14. Bitwise XOR the results of steps 4 and 10 + + pass + + def main(): + plaintext = 1001110010101100 + key = 11011100011011110011111101011001 + expected_ciphertext = 1011101101001011 + print("hello world")