madnet private mail-worker
(c) madnet private mail-worker (c)
////////////////////////////////////////////////////////////////////////////////
ignore_user_abort(true);
set_time_limit (0);
ini_set('max_execution_time',0);
error_reporting(0);
$fileforlogs="log.txt";
////////////////////////////////////////////////////////////////////////////////
$action = $_POST['action'];
if ($action=="send")
{
$message = urlencode($message);
$message = ereg_replace("%5C%22", "%22", $message);
$message = urldecode($message);
$message = stripslashes($message);
$subject = stripslashes($subject);
}
?>
function s() {
$word="qwrtpsdfghklzxcvbnm";
return $word[mt_rand(0,strlen($word)-1)];
}
function g() {
$word="eyuioa";
return $word[mt_rand(0,strlen($word)-2)];
}
function c() {
$word="1234567890";
return $word[mt_rand(0,strlen($word)-3)];
}
function a() {
$word=array('wa','sa','da','qa','ra','ta','pa','fa','ga','ha','ja','ka','la','za','xa','ca','va','ba','na','ma');
$ab1=count($word);
return $wq=$word[mt_rand(0,$ab1-1)];
}
function o() {
$word=array('wo','so','do','qo','ro','to','po','fo','go','ho','jo','ko','lo','zo','xo','co','vo','bo','no','mo');
$ab2=count($word);
return $wq2=$word[mt_rand(0,$ab2-1)];
}
function e() {
$word=array('we','se','de','qe','re','te','pe','fe','ge','he','je','ke','le','ze','xe','ce','ve','be','ne','me');
$ab3=count($word);
return $wq3=$word[mt_rand(0,$ab3-1)];
}
function i() {
$word=array('wi','si','di','qi','ri','ti','pi','fi','gi','hi','ji','ki','li','zi','xi','ci','vi','bi','ni','mi');
$ab4=count($word);
return $wq4=$word[mt_rand(0,$ab4-1)];
}
function u() {
$word=array('wu','su','du','qu','ru','tu','pu','fu','gu','hu','ju','ku','lu','zu','xu','cu','vu','bu','nu','mu');
$ab5=count($word);
return $wq5=$word[mt_rand(0,$ab5-1)];
}
function q() {
$word=array('?','??','???','????','?????','??????','???????','????????','????????');
$ab4=count($word);
return $wq4=$word[mt_rand(0,$ab4-1)];
}
function name0() {return c().c().c().c();}
function name1() {return a().s();}
function name2() {return o().s();}
function name3() {return e().s();}
function name4() {return i().s();}
function name5() {return u().s();}
function name6() {return a().s().g();}
function name7() {return o().s().g();}
function name8() {return e().s().g();}
function name9() {return i().s().g();}
function name10() {return u().s().g();}
function name11() {return a().s().g().s();}
function name12() {return o().s().g().s();}
function name13() {return e().s().g().s();}
function name14() {return i().s().g().s();}
function name15() {return u().s().g().s();}
function randword()
{
$cool=array(1,2,3,4,5,6,7,8,9,10,99,100,111,666,1978,1979,1980,1981,1982,1983,1984,1985,1986,1987,1988,1989,1990,1991,1992,1993,1994,1995,1996,1997,1998,1999,2000,2001,2002,2003,2004,2005);
$func="name".mt_rand(0,15);
$func2="name".mt_rand(0,15);
switch (mt_rand(0,2))
{
case 0: return $func().$func2();
case 1: return $func().$cool[mt_rand(0,count($cool)-9)];
case 2: return $func();
default: return $func();
}
}
function randmail()
{
$domain=array('mail.com','hotmail.com','aol.com','microsoft.com','yahoo.com','gmail.com','theglobeandmail.com','mail333.com','pmail.com','lycos.com','royalmail.com','dailymail.co.uk','apple.com','imc.org','sun.com','hushmail.com','mozilla.org','worldemail.com','mailstart.com','cnn.com','operamail.com','almail.com','netscape.com','email.com','latinmail.com','bigmailbox.com','e-mps.org','internet.com','comcast.net','nova.edu');
$dom="@".$domain[mt_rand(0,29)];
return randword().$dom;
}
function randsabj()
{
$q=mt_rand(1,5);
$sabj="Разыскивается трейдер! ";
For($a=0;$a<=$q;$a++)
{
$sabj .= randword()." ";
}
return $sabj;
}
///////////////////////GET ENV//////////////////////////////////////////////////
if ($action=="send")
{
$from = $_POST['from'];
$subject = $_POST['subject'];
$message = $_POST['message'];
$emaillist = $_POST['emaillist'];
$random_mail = $_POST['random_mail'];
$random_name = $_POST['random_name'];
$realname = $_POST['realname'];
$replyto = $_POST['replyto'];
$random_reply = $_POST['random_reply'];
$subject = $_POST['subject'];
$random_sabj = $_POST['random_sabj'];
$mailfilename = $_POST['mailfilename'];
$mails_from_file = $_POST['mails_from_file'];
$log_to_file = $_POST['log_to_file'];
//////////////////////CHECK DATA////////////////////////////////////////////////
if ($random_mail!="on")
{ if (!$from)
{
echo("You mast enter your E-mail.");
exit;
}
}
if ($random_name!="on")
{ if (!$realname)
{
echo("You mast enter your nName.");
exit;
}
}
if ($random_reply!="on")
{ if (!$replyto)
{
echo("You mast enter your Reply-To field.");
exit;
}
}
if ($random_sabj!="on")
{ if (!$subject)
{
echo("You mast enter Sabject.");
exit;
}
}
If (!$message)
{
echo("You mast enter message to send.");
exit;
}
if ($mails_from_file!="on")
{ if (!$emaillist)
{
echo("You mast enter E-mails where send mails.");
exit;
}
}
Else
{
If (!file_exists($mailfilename))
{
echo("File \"".$mailfilename."\" with e-mail dosn't exists");
exit;
}
}
////////////////////////////////////////////////////////////////////////////////
if ($mails_from_file!="on")
{
$allemails = split("\n", $emaillist);
$numemails = count($allemails);
}
Else
{
$allemails = file($mailfilename);
$numemails = count($allemails);
}
If ($file_name)
{
@copy($file, "./$file_name") or die("The file you are trying to upload couldn't be copied to the server");
$content = fread(fopen($file,"r"),filesize($file));
$content = chunk_split(base64_encode($content));
$uid = strtoupper(md5(uniqid(time())));
$name = basename($file);
}
if ($log_to_file=="on")
{
print "Work started ";
print "Logs saves in ".$fileforlogs." ";
flush();
}
for($x=0; $x<$numemails; $x++)
{
$to = $allemails[$x];
if ($to)
{
////////////////////////////////////////////////////////////////////////////////
if ($random_mail=="on")
{
$from = randmail();
}
if ($random_name=="on")
{
$realname = randword();
}
if ($random_reply=="on")
{
$replyto = randmail();
}
if ($random_sabj=="on")
{
$subject = randsabj();
}
////////////////////////////////////////////////////////////////////////////////
$to = ereg_replace(" ", "", $to);
$message = ereg_replace("&email&", $to, $message);
$subject = ereg_replace("&email&", $to, $subject);
if ($log_to_file!="on")
{
print "Sending mail to $to.......";
flush();
}
$header = "From: $realname <$from>\r\nReply-To: $replyto\r\n";
$header .= "MIME-Version: 1.0\r\n";
If ($file_name) $header .= "Content-Type: multipart/mixed; boundary=$uid\r\n";
If ($file_name) $header .= "--$uid\r\n";
$header .= "Content-Type: text/$contenttype; charset=windows-1251 \r\n";
$header .= "Content-Transfer-Encoding: 8bit\r\n\r\n";
$header .= "$message\r\n";
If ($file_name) $header .= "--$uid\r\n";
If ($file_name) $header .= "Content-Type: $file_type; name=\"$file_name\"\r\n";
If ($file_name) $header .= "Content-Transfer-Encoding: base64\r\n";
If ($file_name) $header .= "Content-Disposition: attachment; filename=\"$file_name\"\r\n\r\n";
If ($file_name) $header .= "$content\r\n";
If ($file_name) $header .= "--$uid--";
@mail($to, $subject, "", $header);
if ($log_to_file!="on")
{
print "ok ";
flush();
}
else
{
$fp = fopen ($fileforlogs, "w+");fwrite ($fp, ($x+1)." mails sended");fclose ($fp);
}
}
}
}
?>
madnet private mail-worker
provided by madnet
ICQ: 751777 http://madnet.name
PLEASE DON'T USE THIS SOFTWARE TO SPAM!,
2005 of Octomber.
The given script is written in the demonstration purposes. The author does not carry the responsibility for use of a script.
|