Powershell Spamming Machine

Another scripting day…I'm now a spammer! 
$MyReader = new-object 
$message = $MyReader.ReadToEnd();
#$message = Get-Content -encoding UTF8 -path C:email.txt
   foreach ($user in Get-Content C:names.txt) {
      $smtp = new-object 
      $smtp.Send("Me <me@email.com>",
         "$user", "Subject", $message)
The script reads in a text file that contains the e-mail message, then it emails everybody listed (one per line) in another file. Pretty simple, but it took me a while to figure it out (about 45 minutes). Boom. Instant spamming machine.

Leave a Reply

Your email address will not be published.