First commit

This commit is contained in:
2026-01-11 09:19:22 +01:00
commit 50f7b1159e
108 changed files with 11791 additions and 0 deletions
+22
View File
@@ -0,0 +1,22 @@
#!/usr/bin/env python3
from Cryptotools.Encryptions.RSA import RSA
rsa = RSA()
rsa.generateKeys(size=512)
e = rsa.e
d = rsa.d
n = rsa.n
s = "I am encrypted with RSA"
print(f"plaintext: {s}")
encrypted = rsa.encrypt(s)
# Encrypt data
# print(f"ciphertext: {encrypted}")
# We decrypt
plaintext = rsa.decrypt(encrypted)
print(f"Plaintext: {plaintext}")