One Hat Cyber Team
Your IP :
3.23.94.64
Server IP :
192.145.235.60
Server :
Linux ngx365.inmotionhosting.com 5.14.0-427.33.1.el9_4.x86_64 #1 SMP PREEMPT_DYNAMIC Fri Aug 30 09:45:56 EDT 2024 x86_64
Server Software :
Apache
PHP Version :
8.2.27
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
opt
/
sharedrads
/
extras
/
Edit File:
replaceindex
#!/usr/bin/bash # Used to replace IMH holder index pages # Vanessa V. 7/13/10 RADS REPO=http://repo.imhadmin.net/open/imh/ BKDIR=/root/replaced SKEL=/root/cpanel3-skel/public_html LOG=$BKDIR/log DATE=$(date +%D_%T) if [ ! -d $BKDIR ]; then mkdir $BKDIR fi touch $LOG # Replace skel files cd /root ; wget -q $REPO/default.htm if [ ! -s /root/default.htm ]; then echo "Error downloading index file...quitting" exit 1 else rm -f $SKEL/index.htm rm -f $SKEL/index.html rm -f $SKEL/default.htm mv -f /root/default.htm $SKEL fi STRING="If you own this site, your new web hosting account is now activated" STRING2="If you are visiting this site, please check back soon" # Loop through and find index pages for user in `/bin/ls -A /var/cpanel/users` ; do USERPATH=/home/$user/public_html array=($USERPATH/index.htm $USERPATH/index.html $USERPATH/default.htm) for index in ${array[*]} do if [ -f $index ]; then if grep "$STRING" $index >/dev/null && grep "$STRING2" $index >/dev/null ; then PAGEPATH=$(ls $index | cut -d/ -f1,2,3,4) PAGENAME=$(ls $index | cut -d/ -f5) # Replace index pages mv -f $index $BKDIR/$user-$PAGENAME cp -f $SKEL/default.htm $index chown $user:$user $index MSG="Replaced $PAGENAME in $PAGEPATH" echo "$DATE : $MSG" >> $LOG echo $MSG fi fi done done
Simpan