-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.py
79 lines (63 loc) · 2.36 KB
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
from colorama import Fore
import colorama
import getpass
import os
import shutil
import sys
import pyfiglet
from time import sleep
import subprocess
from itertools import cycle
import numpy as np
from operations_AND_algorithms import *
import numpy as np
from PIL import Image
def menu():
subprocess.run('cls', shell=True)
ascii_art = pyfiglet.figlet_format("! I C R Y P T !")
print(ascii_art)
colorama.init(autoreset=True)
print(Fore.LIGHTCYAN_EX + "[1] RAIL Cipher Encryption/Decryption")
print(Fore.LIGHTCYAN_EX + "[2] To Text Encryption/Decryption")
print(Fore.LIGHTCYAN_EX + "[3] Rail Cipher + To Text Encryption/Decryption")
print(Fore.LIGHTCYAN_EX + "[0] Exit The Program")
print("")
while True:
option = int(input("Enter your option:"))
if option == 1:
subprocess.run('cls', shell=True)
print(Fore.CYAN + pyfiglet.figlet_format("! RAIL Cipher !"))
os.system("python rail_fence_cipher.py")
elif option == 2:
subprocess.run('cls', shell=True)
print(Fore.GREEN + pyfiglet.figlet_format("! Te x t !"))
os.system("python image2text.py")
elif option == 3:
subprocess.run('cls', shell=True)
print(Fore.LIGHTMAGENTA_EX + pyfiglet.figlet_format("! RAIL & Text !"))
os.system("python both.py")
elif option == 0:
colorama.init(autoreset=True)
subprocess.run('cls', shell=True)
print(pyfiglet.figlet_format("! I C R Y P T !"))
print(pyfiglet.figlet_format("By Group 6"))
sleep(0.7)
print("--CREATED BY:")
print(Fore.YELLOW + "[*] Juri Alaqeel")
sleep(0.7)
print(Fore.YELLOW + "[*] Lulwah Alduwaihi")
sleep(0.7)
print(Fore.YELLOW + "[*] Maryam Tariq AlBugaey")
sleep(0.7)
print(Fore.YELLOW + "[*] Fatima Husain Abujaid")
sleep(0.7)
print(Fore.YELLOW + "[*] Sara Nasser AlSubaie")
print("\n")
sleep(0.7)
print(Fore.YELLOW + "--> Instructor: Mr. Hussain Alattas")
exit()
else:
print("invalid option")
menu()
option = int(input("Enter your option:"))
menu()