RandomEmailSpamMachine

From XPUB & Lens-Based wiki
Revision as of 20:32, 23 September 2010 by Migratebot (talk | contribs) (Created page with "A variation of the Network Theory Spam that sends automatically generated emails to a randomly picked email address. The subject and the body of the email is generated using dada...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

A variation of the Network Theory Spam that sends automatically generated emails to a randomly picked email address. The subject and the body of the email is generated using dadadodo parsing a text (in this case, the screenplay for the movie Dog Day Afrenoon). The address is chosen from a list (the file "emails.dat") in each itteration of the loop.


#!/bin/bash

wget http://www.awesomefilm.com/script/dog_day_afternoon.txt #get the text file

for i in `seq 1 10`; do #everything between 'do' and 'done' is looped

RAND=`cat /proc/sys/kernel/random/uuid | cut -c1-4 | od -d | head -1 | cut -d' ' -f2`
LINES=`cat "emails.dat" | wc -l`
LINE=`expr $RAND % $LINES + 1`
ADDRESS=`cat emails.dat | head -$LINE | tail -1`

GOODSTUFF=`cat dog_day_afternoon.txt | dadadodo -c 3 -`
GOODSUBJECT=`cat dog_day_afternoon.txt | dadadodo -c 1 -`

sendmail -t <<EOF
From: 20minutes@today.org
To: $ADDRESS
Subject: $GOODSUBJECT

$GOODSTUFF

EOF

sleep 10 #prevents it from being blocked as an attack
echo "sent"

done