public_key_cryptography course - challenge 6 - hash and sign using RSA

This commit is contained in:
boyreau 2026-11-14 12:41:40 +01:00
commit a38934684d
2 changed files with 15 additions and 0 deletions

View file

@ -14,6 +14,7 @@ from public_key_cryptography import (
Euler_totient,
private_key,
decode,
hash_and_encrypt,
)
if __name__ == "__main__":
@ -39,4 +40,5 @@ if __name__ == "__main__":
print(Euler_totient(857504083339712752489993810777, 1029224947942998075080348647219))
print(private_key(857504083339712752489993810777, 1029224947942998075080348647219, 0x10001))
print(decode(857504083339712752489993810777, 1029224947942998075080348647219, 0x10001, 77578995801157823671636298847186723593814843845525223303932))
print(hash_and_encrypt("crypto{Immut4ble_m3ssag1ng}"))
# fmt: on