GithubHelp home page GithubHelp logo

mikechabot / smtp-email-spoofer-py Goto Github PK

View Code? Open in Web Editor NEW
216.0 11.0 51.0 51 KB

Python 3.x based email spoofer

License: GNU General Public License v3.0

Python 99.00% HTML 1.00%
python email-spoofer smtp email-sender

smtp-email-spoofer-py's Introduction

smtp-email-spoofer-py

Python 3.x based email spoofer

For educational purposes only. Do not send to or from addresses that you do not own.

Email spoofing is often used for spam campaigns and phishing attacks. If you use this tool inappropriately, you could violate of the CAN-SPAM Act of 2003 and/or the Computer Fraud and Abuse Act. You'd also be committing wire fraud. Use your head.


Table of Contents

  1. $ git clone https://github.com/mikechabot/smtp-email-spoofer-py.git
  2. Activate virtualenv
  3. $ pip install -r requirements.txt
  4. $ python spoof.py

Instructions on creating and activating virtualenv can be found here: https://packaging.python.org/guides/installing-using-pip-and-virtual-environments/

smtp-email-spoofer-py offers two global commands: wizard and cli:

$ py spoof.py -h
usage: spoof.py [-h] {wizard,cli} ...

Python 3.x based email spoofer

optional arguments:
  -h, --help    show this help message and exit

commands:
  {wizard,cli}  Allowed commands
    wizard      Use the step-by-step wizard
    cli         Pass arguments directly

Issue the wizard command to use the step-by-step wizard:

$ py spoof.py wizard
  1. Enter the SMTP server information to establish a connection over TLS:

logo

  1. Optionally provide credentials to login to the SMTP server:

logo

  1. Compose the forged message:

Load the HTML message body from a file, or compose it within the shell

logo

  1. Send the message:

logo


Issue the cli -h command to view the help:

$ py spoof.py cli -h
usage: spoof.py cli [-h] (--noauth | --username USERNAME)
                    [--password PASSWORD] --host HOST --port PORT --sender
                    SENDER --name NAME --recipients RECIPIENTS
                    [RECIPIENTS ...] --subject SUBJECT --filename FILENAME

optional arguments:
  -h, --help            show this help message and exit
  --noauth              Disable authentication check
  --username USERNAME   SMTP username
  --password PASSWORD   SMTP password (required with --username)

required arguments:
  --host HOST           SMTP hostname
  --port PORT           SMTP port number
  --sender SENDER       Sender address (e.g. [email protected])
  --name NAME           Sender name (e.g. John Smith)
  --recipients RECIPIENTS [RECIPIENTS ...]
                        Recipient addresses (e.g. [email protected] ...)
  --subject SUBJECT     Subject line
  --filename FILENAME   Message body filename (e.g. example.html)
  1. Issue the cli command along with the appropriate arguments:

If --noauth is not specified, --username and --password are required.

logo


Result

logo

smtp-email-spoofer-py's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

smtp-email-spoofer-py's Issues

cannot add additional recipients

Adding additional recipient address throws of some errors.

File "spoof.py", line 8, in
sys.exit(main())
File "spoof.py", line 6, in main
args.func(args)
File "/home/....wizard.py", line 42, in run
while recipient:
UnboundLocalError: local variable 'recipient' referenced before assignment.

How to add "reply-to" option ?

Hello devs,
I tried to include some code to implement reply-to in the code . Every thing is okay . But the mail not sent .
It shows below error :
Traceback (most recent call last):
File "/root/tools/smtp-email-spoofer-py/spoofer/models/smtpconnection.py", line 100, in send_mail
self.server.sendmail(self.sender, self.recipients, self.reply, message.as_string())
File "/usr/lib/python3.9/smtplib.py", line 871, in sendmail
raise SMTPSenderRefused(code, resp, from_addr)
smtplib.SMTPSenderRefused: (501, b'[email protected] size=20 M I M E - V e r s i o n : 1 . 0: malformed address: size=20 M I M E - V e r s i o n may not follow [email protected]', '[email protected]')

I don't have any idea about this error . Could any one help me to solve this ?

email list

i just wanted to ask if this tool can take an email list for mass mailing

error on sending message

Unable to send message. Check sender, recipients and message body
Traceback (most recent call last):
File "/Users/bryanbuckus/Desktop/smtp-email-spoofer-py/spoofer/models/smtpconnection.py", line 97, in send_mail
self.server.sendmail(self.sender, self.recipients, message.as_string())
File "/usr/local/Cellar/[email protected]/3.9.0_2/Frameworks/Python.framework/Versions/3.9/lib/python3.9/smtplib.py", line 885, in sendmail
raise SMTPRecipientsRefused(senderrs)
smtplib.SMTPRecipientsRefused: {'[email protected]': (550, b'relay access denied - please authenticate')}

Step 3 error: pip install -r requirements.txt

Dear Mikechabot,
When installing requirements.txt with the command:
$ pip3 install -r https://github.com/mikechabot/smtp-email-spoofer-py/blob/master/requirements.txt
I have a result error:


[root@TestEmailSending ~]# pip3 install -r https://github.com/mikechabot/smtp-email-spoofer-py/blob/master/requirements.txt
WARNING: Running pip install with root privileges is generally not a good idea. Try `pip3 install --user` instead.
Invalid requirement: '<!DOCTYPE html>'
Traceback (most recent call last):
  File "/usr/lib/python3.6/site-packages/pip/_vendor/packaging/requirements.py", line 92, in __init__
    req = REQUIREMENT.parseString(requirement_string)
  File "/usr/lib/python3.6/site-packages/pip/_vendor/pyparsing.py", line 1617, in parseString
    raise exc
  File "/usr/lib/python3.6/site-packages/pip/_vendor/pyparsing.py", line 1607, in parseString
    loc, tokens = self._parse( instring, 0 )
  File "/usr/lib/python3.6/site-packages/pip/_vendor/pyparsing.py", line 1379, in _parseNoCache
    loc,tokens = self.parseImpl( instring, preloc, doActions )
  File "/usr/lib/python3.6/site-packages/pip/_vendor/pyparsing.py", line 3376, in parseImpl
    loc, exprtokens = e._parse( instring, loc, doActions )
  File "/usr/lib/python3.6/site-packages/pip/_vendor/pyparsing.py", line 1379, in _parseNoCache
    loc,tokens = self.parseImpl( instring, preloc, doActions )
  File "/usr/lib/python3.6/site-packages/pip/_vendor/pyparsing.py", line 3698, in parseImpl
    return self.expr._parse( instring, loc, doActions, callPreParse=False )
  File "/usr/lib/python3.6/site-packages/pip/_vendor/pyparsing.py", line 1379, in _parseNoCache
    loc,tokens = self.parseImpl( instring, preloc, doActions )
  File "/usr/lib/python3.6/site-packages/pip/_vendor/pyparsing.py", line 3359, in parseImpl
    loc, resultlist = self.exprs[0]._parse( instring, loc, doActions, callPreParse=False )
  File "/usr/lib/python3.6/site-packages/pip/_vendor/pyparsing.py", line 1383, in _parseNoCache
    loc,tokens = self.parseImpl( instring, preloc, doActions )
  File "/usr/lib/python3.6/site-packages/pip/_vendor/pyparsing.py", line 2670, in parseImpl
    raise ParseException(instring, loc, self.errmsg, self)
pip._vendor.pyparsing.ParseException: Expected W:(abcd...) (at char 0), (line:1, col:1)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3.6/site-packages/pip/req/req_install.py", line 82, in __init__
    req = Requirement(req)
  File "/usr/lib/python3.6/site-packages/pip/_vendor/packaging/requirements.py", line 96, in __init__
    requirement_string[e.loc:e.loc + 8]))
pip._vendor.packaging.requirements.InvalidRequirement: Invalid requirement, parse error at "'<!DOCTYP'"

What should i do now ?

No module named spoofer

Can't launch spoof.py because I get an error on startup.
Already installed requirements, any help?

Traceback (most recent call last): File ".\spoof.py", line 2, in <module> from spoofer import conf

when trying to run always get these traceback errors...is something broken? how do you fix this?

Traceback (most recent call last):
File ".\spoof.py", line 2, in
from spoofer import conf

\smtp-email-spoofer-py-master\spoofer\conf.py", line 8, in
subparsers = parser.add_subparsers(title='commands', dest='command', help='Allowed commands', required=True)

in add_subparsers
action = parsers_class(option_strings=[], **kwargs)
TypeError: init() got an unexpected keyword argument 'required'

Email not Spoofing

The "Spoofed" email doesn't work. It would change the name but the email id shown in the "from" won't be spoofed.

For the owner

Well actually gmail uses an authentication code that changes every 15 minutes and it is obligatory to login with the username and password on a new device which makes the tool unable to work properly
Please make a solution

Commands to get the tool started

I have cloned smtp-email-spoofer-py and I have open Virtualenv,but I don't know how to open the tool and use it ,I have try this command
cd smtp-email-spoofer-py
spoofer.py
But it's still not working

Emails do not reach gmail recipients

Using the spoofer, emails will reach my own email domains but end up in the spam folder, but for gmail recipients the emails do not even reach the spam folder. Is there a solution for this at all?

Unable to send message. Check sender, recipients and message body error

Hello, I've using this app for about 2 years now but have recently been getting this "Unable to send message. Check sender, recipients and message body" error message while using the wizard.

SMTP host: mail.smtp2go.com
SMTP port: 2525                                                                                                                                                             
Connecting to SMTP socket (mail.smtp2go.com:2525)...                                                                                                                        
Starting TLS session...
Disable authentication (Y/N)?: N
Username: *******                                                                                                                                          
Password:  *******                                                                                                                                                                                                                                                                                                                             
Authentication successful                                                                                                                                                   
Sender address: [email protected]
Sender name: TEst                                                                                                                                                           
Recipient address: [email protected]                                                                                                                                
Enter additional recipients (Y/N)?: N                                                                                                                                       
Subject line: TEst                                                                                                                                                          
Load message body from file (Y/N)?: Y                                                                                                                                       
Filename: example.html                                                                                                                                                      
Send message (Y/N)?: Y                                                                                                                                                      
Sending spoofed message...                                                                                                                                                  
Unable to send message. Check sender, recipients and message body

Get the same error when loading email content directly too.
Does your app still work with smtp2go ?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.