-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.py
executable file
·40 lines (34 loc) · 1.12 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
#!/bin/python3
from ftplib import FTP, error_perm
import os, sys, time
from src.color import color
from src.argmuents import arguments
from src.FTPScan import scan
from src.getHelp import getHelp
from src.checkVersion import checkVersion
from src.logsCreation import log
# --- BANNER ---
banner = r"""______ ___________ ___
| ___|_ _| ___ \/ _ \
| |_ | | | |_/ / /_\ \_ __ ___ _ __
| _| | | | __/| _ | '_ \ / _ \| '_ \
| | | | | | | | | | | | | (_) | | | |
\_| \_/ \_| \_| |_/_| |_|\___/|_| |_|
--- SIMILAR TO THE FTP-ANON.NSE ---"""
# --- RUN ---
def main():
global LOG
print(color.purple , banner, color.reset)
IP, PORT, PATH = arguments()
LOG = log(PATH, banner)
checkVersion()
isFinish = scan(IP, PORT, LOG)
if isFinish == 0 or isFinish == 1:
LOG.writelines(f"\n[{time.strftime('%d/%m/%Y')}] Scan succesfully done")
sys.exit(0)
else:
LOG.writelines(f"\n[{time.strftime('%d/%m/%Y')}] ERROR")
print("[!] Wwhoops, somethings goes wrong")
sys.exit(0)
if __name__ == "__main__":
main()