#!/bin/bash
#head -n -2 /etc/adm-lite/cabecalho > headuser.sh && chmod 777 headuser.sh && source headuser.sh
source cabecalho
msg -bar 
echo -e "${cor[2]} ⌐╦╦═─ ${cor[5]} MENÚ HERRAMIENTAS By $(cat /etc/adm-lite/menu_credito)"
msg -bar 
echo -e "\033[0;35m [\033[0;36m1\033[0;35m]\033[0;31m ➮${cor[3]} Bloqueo Torrent y Palabras Claves \033[0;33m( #BETA )"
echo -e "\033[0;35m [\033[0;36m2\033[0;35m]\033[0;31m ➮${cor[3]} FIX PassWD Vultr"
echo -e "\033[0;35m [\033[0;36m3\033[0;35m]\033[0;31m ➮${cor[3]} Bad-VPN (Juegos Online/VideoCalls) $_badvpn"
echo -e "\033[0;35m [\033[0;36m5\033[0;35m]\033[0;31m ➮${cor[3]} TCP SPEED ( BBR ) $_tcpspeed"
echo -e "\033[0;35m [\033[0;36m6\033[0;35m]\033[0;31m ➮${cor[3]} FAILBAN\033[0;32m ( Secure IP ) $fail_b"
echo -e "\033[0;35m [\033[0;36m8\033[0;35m]\033[0;31m ➮${cor[3]} COMPARTIR ARCHIVO ONLINE "
echo -e "\033[0;35m [\033[0;36m9\033[0;35m]\033[0;31m ➮${cor[3]} TEST DE VELOCIDAD DEL SERVIDOR"
echo -e "\033[0;35m [\033[0;36m10\033[0;35m]\033[0;31m ➮${cor[3]} DETALLES DEL VPS"
echo -e "\033[0;35m [\033[0;36m12\033[0;35m]\033[0;31m ➮${cor[3]} GENERADOR DE PAYLOAD"
echo -e "\033[0;35m [\033[0;36m14\033[0;35m]\033[0;31m ➮${cor[3]} ULTRA HOST (SCANNER DE SUBDOMINIOS)"
echo -e "\033[0;35m [\033[0;36m15\033[0;35m]\033[0;31m ➮${cor[3]} I/O SCANNER SUBDOMINIOS \033[0;33m( #ToolMaster )"
echo -e "\033[0;35m [\033[0;36m17\033[0;35m]\033[0;31m ➮${cor[3]} APLICAR BLOQUEO TORRENT \033[0;33m ${txt[342]} "
echo -e "\033[0;35m [\033[0;36m19\033[0;35m]\033[0;31m ➮${cor[3]} REINICIAR VPS (REBOOT)"
msg -bar 
echo -e " \033[0;35m[\033[0;36m0\033[0;35m]\033[0;31m ➮ $(msg -bra "\033[1;41m[ Regresar ]\e[0m")"
msg -bar

#FUNCION DE SELECCION
selection_fun () {
local selection="null"
local range
for((i=0; i<=$1; i++)); do range[$i]="$i "; done
while [[ ! $(echo ${range[*]}|grep -w "$selection") ]]; do
echo -ne "\033[1;37m ESCOJE : " >&2
read selection
tput cuu1 >&2 && tput dl1 >&2
done
echo $selection
}



echo -ne "${cor[6]}"
#FUNCIONES

selection=$(selection_fun 19)
case ${selection} in
0)
source menu
exit
;;
1)
source ferramentascodes 1
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
2)
source ferramentascodes 2
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
3)
source ferramentascodes 3
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
4)
source ferramentascodes 4
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
5)
source ferramentascodes 5
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
6)
source ferramentascodes 6
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
7)
source ferramentascodes 7
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
8)
source ferramentascodes 8
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
9)
source ferramentascodes 9
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
10)
source ferramentascodes 10
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
11)
source ferramentascodes 11
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
12)
source ferramentascodes 12
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
13)
minhas_portas
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
14)
echo -e "${cor[1]} =================================== ${cor[0]}"
echo -ne "\033[1;33m ${txt[306]}: \033[1;37m"; read hostcaptura
echo -ne "\033[1;33m ${txt[307]}: \033[1;37m"; read limitecaptura
chmod 777 ./ultrahost
./ultrahost "${hostcaptura}" "${limitecaptura}"
read -p " ¡Enter, para volver!"
source ferramentas
exit
;;
15)
source ferramentascodes 13
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
16)
source ferramentascodes 14
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
17)
source ferramentascodes 15
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
18)
source ferramentascodes 16
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
19)
source ferramentascodes 17
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
20)
source ferramentascodes 20
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
21)
source ferramentascodes 21
echo -ne "${cor[5]}"
read -p " ¡Enter, para volver!"
cd /etc/adm-lite
source ferramentas
exit
;;
*)
cd /etc/adm-lite
source ferramentas
rm -f headuser.sh
exit
;;
esac
