Cod: Selectaţi tot
<?php
$ips = $_POST['ips'];
$users = $_POST['users'];
$password = $_POST['password'];
function rand_string( $length ) {
$chars = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789";
$size = strlen( $chars );
for( $i = 0; $i < $length; $i++ ) {
$str .= $chars[ rand( 0, $size - 1 ) ];
}
return $str;
}
$key = rand_string(8) . ".txt";
$fh = fopen($key, 'w') or die("can't open file");
$ips=explode("\n", $ips);
$users=explode("\n", $users);
foreach($ips as $ip){
foreach($users as $user){
$string= $ip . "@" . $user . ";" . $password ;
$string = preg_replace('/\s+/', '', $string);
fwrite($fh, $string);
fwrite($fh, " \r\n"); }}
$print = "Done! Poti sa descarci fisierul sursa si sa il adaugi in dubrute <a href=http://hiphopize.me"
. $key . " >Click</a>";
echo $print;
?>
html
Cod: Selectaţi tot
<html>
<head><title>RDP_SRCBuilder</title></head><center>
<body><form method="POST" action=create.php>Ips:<textarea id="ips" name="ips" cols="40"
rows="15"></textarea>Users:<textarea id="users" name="users" cols="40"
rows="15"></textarea>Password:<textarea id="password" name="password" cols="40"
rows="15"></textarea><br><input type="submit" value="Show them all!"></center><br>
</body></html>