Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed script to add UTF-8 encoding #88

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions xerosploit.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ def home():
table = [["IP Address","MAC Address","Gateway","Iface","Hostname"],
["","","","",""],
[n_ip,n_mac.upper(),gateway,up_interface,n_host]]
print (tabulate(table, stralign="center",tablefmt="fancy_grid",headers="firstrow"))
print (tabulate(table, stralign="center",tablefmt="fancy_grid",headers="firstrow")).encode('utf-8')
print ("")


Expand All @@ -96,7 +96,7 @@ def home():
['\033[1;36m\nInformation\n', 'XeroSploit is a penetration testing toolkit whose goal is to \nperform man in the middle attacks for testing purposes. \nIt brings various modules that allow to realise efficient attacks.\nThis tool is Powered by Bettercap and Nmap.\033[1;m']
]
table = DoubleTable(table_datas)
print(table.table)
print(table.table).encode('utf-8')


# Get a list of all currently connected devices , using Nmap.
Expand Down Expand Up @@ -125,7 +125,7 @@ def scan():

# Show devices found on your network
print("\033[1;36m[+]═══════════[ Devices found on your network ]═══════════[+]\n\033[1;m")
print(table.table)
print(table.table).encode('utf-8')
target_ip()


Expand Down Expand Up @@ -212,7 +212,7 @@ def pscan():
]
table = DoubleTable(table_data)
print("\033[1;36m\n[+]═════════[ Port scan result for " + target_ips +" ]═════════[+]\n\033[1;m")
print(table.table)
print(table.table).encode('utf-8')
pscan()

else:
Expand Down Expand Up @@ -310,7 +310,7 @@ def ping():
]
table = DoubleTable(table_data)
print("\033[1;36m\n[+]═════════[ " + target_ips +" ping statistics ]═════════[+]\n\033[1;m")
print(table.table)
print(table.table).encode('utf-8')
ping()
else:
print("\033[1;91m\n[!] Error : Command not found.\033[1;m")
Expand Down Expand Up @@ -821,7 +821,7 @@ def deface():
deface : Overwrite all web pages with your HTML code\n\033[1;m"""]
]
table = DoubleTable(table_datas)
print(table.table)
print(table.table).encode('utf-8')
option()
else:
print("\033[1;91m\n[!] Error : Module not found . Type 'help' to view the modules list. \033[1;m")
Expand All @@ -841,7 +841,7 @@ def deface():
["\033[1;36m\nInformation\n", "\nInsert your target IP address.\nMultiple targets : ip1,ip2,ip3,... \nThe 'all' command will target all your network.\n\n\033[1;m"]
]
table = DoubleTable(table_datas)
print(table.table)
print(table.table).encode('utf-8')
target_ip()
# if target = all the network
elif target_ips == "all":
Expand Down Expand Up @@ -876,7 +876,7 @@ def gateway():
["\033[1;36m\nInformation\n", "\nManually set your gateway.\nInsert '0' if you want to choose your default network gateway.\n\033[1;m"]
]
table = DoubleTable(table_datas)
print(table.table)
print(table.table).encode('utf-8')

print("\033[1;32m\n[+] Enter your network gateway.\n\033[1;m")
n_gateway = raw_input("\033[1;36m\033[4mXero\033[0m»\033[1;36m\033[4mgateway\033[0m\033[1;36m ➮ \033[1;m").strip()
Expand All @@ -903,7 +903,7 @@ def iface():
["\033[1;36m\nInformation\n", "\nManually set your network interface.\nInsert '0' if you want to choose your default network interface.\n\033[1;m"]
]
table = DoubleTable(table_datas)
print(table.table)
print(table.table).encode('utf-8')

print("\033[1;32m\n[+] Enter your network interface.\n\033[1;m")
n_up_interface = raw_input("\033[1;36m\033[4mXero\033[0m»\033[1;36m\033[4miface\033[0m\033[1;36m ➮ \033[1;m").strip()
Expand Down Expand Up @@ -970,7 +970,7 @@ def rm_log():
exit : Close Xerosploit.\n\033[1;m"""]
]
table = DoubleTable(table_datas)
print(table.table)
print(table.table).encode('utf-8')


else:
Expand Down