Info BackTrack

Linux & Security Tutorial

Spam Code


<?php 
 
 $num = 1;
 $email = $_POST['email'];
 $spam = $_POST['spam'];
 $subject = $_POST['subject'];
 $message = $_POST['message'];
 $from = $_POST['from'];
 $send = $_POST['send'];
 
 if($spam!='' && $email=='')
 {
 die('Please enter an email');
 }
 
 if(51<=$spam)
 {
 die('Error: Number to spam to large. Max is 50 (for security reasons)');
 }
 
 if($email != '')
 {
 while($num<=$spam)
 {
 mail ($email, $subject, $message, "From: " . $from);
 echo $num . "<br>";
 $num++;
 } 
 }
?>
 
<html>
<body>
 
 <form action="email.php" method="post"><br>
 Email: <input type="text" name="email" /><br>
 How many times to spam: <input type="text" name="spam" /><br>
 Subject: <input type="text" name="subject" /><br>
 Message: <TEXTAREA NAME="message" ROWS=6 COLS=40></TEXTAREA><br>
 From: <input type="text" name="from" /><br>
 <input type="submit" value="send" /><input type="reset" />
 </form>
</body>
</html></pre>
<pre>

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: