Skip to content
Open
Show file tree
Hide file tree
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
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

[![Version](https://img.shields.io/badge/Xerosploit-Version_1.0-brightgreen.svg?maxAge=259200)]()
[![PyPI](https://img.shields.io/badge/Python-2.7-blue.svg)]()
[![PyPI](https://img.shields.io/badge/Python-blue.svg)]()
[![Build](https://img.shields.io/badge/Supported_OS-linux-orange.svg)]()
[![AUR](https://img.shields.io/aur/license/yaourt.svg)]()

Expand Down
48 changes: 45 additions & 3 deletions install.py
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -42,22 +42,64 @@ def main():
1) Ubuntu / Kali linux / Others
2) Parrot OS
""")
system0 = input(">>> ")
system0 = raw_input(">>> ")

py_ver = ""

while py_ver == "":
print("""
Python Version You Want To Install On (like 3.6)
""")
py_ver = raw_input(">>> ")

if system0 == "1":
print("\033[1;34m\n[++] Installing Xerosploit ... \033[1;m")
install = os.system("apt-get update && apt-get install -y nmap hping3 build-essential python-pip ruby-dev git libpcap-dev libgmp3-dev && pip install tabulate terminaltables")
install = os.system("apt-get update && apt-get install -y nmap hping3 build-essential python-pip ruby-dev git libpcap-dev libgmp3-dev")

install1 = os.system("""cd tools/bettercap/ && gem build bettercap.* && sudo gem install xettercap-* && rm xettercap-* && cd ../../ && mkdir -p /opt/xerosploit && cp -R tools/ /opt/xerosploit/ && cp xerosploit.py /opt/xerosploit/xerosploit.py && cp banner.py /opt/xerosploit/banner.py && cp run.sh /usr/bin/xerosploit && chmod +x /usr/bin/xerosploit && tput setaf 34; echo "Xerosploit has been sucessfuly instaled. Execute 'xerosploit' in your terminal." """)

if py_ver[0] == "3":
os.system("sudo apt-get install 2to3")
os.system("sudo 2to3 -w xerosploit.py")

run_file = open("run.sh","r")
r_con = run_file.read()
run_file.close()

run_file = open("run.sh","w")
run_file.write(r_con.replace("python","python3"))
run_file.close()

os.system(f"sudo pip install -t /usr/lib/python{py_ver}/dist-packages/ pillow")
os.system(f"sudo pip install -t /usr/lib/python{py_ver}/dist-packages/ tabulate")
os.system(f"sudo pip install -t /usr/lib/python{py_ver}/dist-packages/ terminaltables")

elif system0 == "2":
print("\033[1;34m\n[++] Installing Xerosploit ... \033[1;m")

bet_un = os.system("apt-get remove bettercap") # Remove bettercap to avoid some problems . Installed by default with apt-get .
bet_re_ins = os.system("gem install bettercap") # Reinstall bettercap with gem.

install = os.system("apt-get update && apt-get install -y nmap hping3 ruby-dev git libpcap-dev libgmp3-dev python-tabulate python-terminaltables")

install1 = os.system("""cd tools/bettercap/ && gem build bettercap.* && sudo gem install xettercap-* && rm xettercap-* && cd ../../ && mkdir -p /opt/xerosploit && cp -R tools/ /opt/xerosploit/ && cp xerosploit.py /opt/xerosploit/xerosploit.py && cp banner.py /opt/xerosploit/banner.py && cp run.sh /usr/bin/xerosploit && chmod +x /usr/bin/xerosploit && tput setaf 34; echo "Xerosploit has been sucessfuly instaled. Execute 'xerosploit' in your terminal." """)

if py_ver[0] == "3":
os.system("sudo apt-get install 2to3")

os.system("sudo 2to3 -w xerosploit.py")

run_file = open("run.sh","r")
r_con = run_file.read()
run_file.close()

run_file = open("run.sh","w")
run_file.write(r_con.replace("python","python3"))
run_file.close()

os.system(f"sudo pip install -t /usr/lib/python{py_ver}/dist-packages/ pillow")
os.system(f"sudo pip install -t /usr/lib/python{py_ver}/dist-packages/ tabulate")
os.system(f"sudo pip install -t /usr/lib/python{py_ver}/dist-packages/ terminaltables")

else:
print("Please select the option 1 or 2")
Expand Down