|
写了个小教本来练习一下,但是执行后发现教本生成的PTH文件居然是二进制的,大家看看是怎么回事?
#now the version is 0.1
#let't do it best!!
#!/bin/bash
rm /root/.sec/PTH
dialog --backtitle "WELCOME TO DDOS" --title "WELCOME TO DDOS" --msgbox \
"BASE ON ARCH LINUX 0.71" 10 20
dialog --title "SELECT THE IMAGE" --menu "SELECT A IMAGE" 11 70 5 \
"/root/produce/1.FLASH" "" \
"/root/produce/2.FLASH" "" \
"/root/produce/3.FLASH" "" \
"/root/produce/4.FLASH" "" \
"/root/produce/5.FLASH" "" &>/root/.sec/PTH
if ( test $? -eq 0 );then
dialog --clear
echo "please wait..............................................................................................................................................."
cat /root/.sec/PTH | dd of=/dev/hdb bs=65536 &>/root/.sec/info;
dialog --msgbox "DONE" 10 10 ;
#halt -p;
else
dialog --yesno "SHUT OR GOBACK" 10 20
if ( test $? -eq 0 );then
halt -p
echo "THE SYSTEM WILL SHUTDOWN.................................................................................................................................."
else
/root/.sec/ddos.sh
fi
fi
为什么生成的PTH文件会是2进制的呢?本来应该生成的是文本文件啊? |
|