Home Miscellaneous SMTP4DEV

SMTP4DEV

1060
0
Reading Time: 2 minutes

While working on a project recently i realised that i wanted to test the email notification reporting while on the go (I was travelling at the time). Using some Google-Fu search power i came across this really useful portable application for a quick SMTP server which requires no installation just double click and off you go! Perfect for testing or use in lab environments which done require a complete exchange or POP/IMAP setup.

Settings up SMTP4Dev

Firstly you will want to do go:
https://github.com/rnwood/smtp4dev and click on ‘Releases’ and download the latest build. (At time of blog post is was:
3.1.0-ci0552

Once the ZIP File has downloaded extract it to the root of C:\Smtp4Dev

Insider the Folder you want to find the application ‘Rnwood.Smtp4dev.exe‘ and double click to launch

Accept the Firewall Prompt (Please note this only runs locally on your computer/server and does not require any internet access)

Then open your favourite browser software and navigate to: http://localhost:5000

That’s the SMTP Server Configured and is now ready to receive mail.

Sending Email Using Microsoft PowerShell

Next we need to launch PoweShell ISE in Administrator Mode

Import-Module Microsoft.PowerShell.Utility
Send-MailMessage -SmtpServer '127.0.0.1' -From 'noreply@hypervlab.co.uk' -To 'simon@hypervlab.co.uk' -Subject 'Example SMTP Message'

Using the code above we can see that an email has been received by the SMTP Server.

You can check the messages from the browser on:
http://localhost:5000

Looking under the ‘Session’ Tab you can see the email message log file

LEAVE A REPLY

Please enter your comment!
Please enter your name here