What tools are available to generate bounce messages in order to test a bounce management tool? We want to test invalid addresses but we will like to test other error status codes.
It sounds to me like you want an SMTP server that generates such errors in a reliable fashion.
Lots of open-source SMTP servers exist and are available for modification. One option is Apache James, a modular open-source Java SMTP server.
A much more trivial test server could simply open port 25 for receiving mails, and deliver canned errors depending on configuration (or incoming email).
Related
I want to set up a ticketing system (osTicket) on a centOS server that generates tickets from incoming e-mails.
osTicket can query mailboxes, but it also provides an API / scripts for piping. Is there a recommended way to setup a (lightweight) mailserver to pipe incoming emails to the script? I do not need actual mailboxes for users.
It's been a while since I did any work on a mail server, but it seems to me that I would only need to set up an MTA for this, and no MDA, correct?
My fallback is to set up POP3/SMTP inboxes elsewhere and query from osTicket. Easy as that would be, the local MTA setup seems cleaner to me.
Consider using remote mailbox accessible via IMAP with IMAP IDLE command support.
It will allow you to get "near real time" delivery to pipe without burden of configuring properly your own SMTP server.
[AFAIR IMAP IDLE is supported e.g. by gmail]
You may use fetchmail with custom procmail script as mda (no need for local SMTP/MTA server).
Using procmail (as "man in the middle) is not strictly necessary but your it will allow you to easily run filtering before delivery to the ticket system (e.g. anti-spam + anti-virus).
I have created a hosting instance in GCP but unable to send or receive email from it. I have used Vesta-cp as control panel and Ubuntu 18.04 minimal as OS. I have opened all required ports in firewall rule and apply them to instance but still get nothing. Any one interested in this issue please answer. Thank You !
See this guide: https://cloud.google.com/compute/docs/tutorials/sending-mail/ Port 25 is always blocked and can't be used to send emails.
Having said that, you probably are better off using managed service for sending emails. Managing security and compliance for mail servers are increasingly getting difficult to manage. So you are better off using a managed service to send emails.
I do web development from my ubuntu server, ubuntu is running in virtualbox in my windows 7. What do I need to configure inside of ubuntu in order to send email to any public domain, gmail.com for example? I need this set up for testing email templates etc... Thanks, Jaro.
For testing email on the ubuntu machine, the best way is to create a local account and use email like account#localhost.
It is not a good test otherwise if you want to send mail directly from your system, as many ISPs are not allowing SMTP traffic over broadband DSL, e.g. my provider THREE in UK doesnt allow it, as well many big email companies will reject emails coming from broadband subnets.
Another way would be deploying the mail server, which is complex, also you can test your app at any free hosting provider too.
Basically testing email is nothing close to being simple and to test it properly, you need a production system with mail fully setup and working, whitelisted, not on DSL and so on.
I need to setup a file distribution system between different sites of a WAN. Files that are dropped into some input directories on the source machine should be distributed into a directory on each of the target machines at other sites. One of the requirements is that between certain sites the only allowed traffic is SMTP. There is already a daemon in place that covers the sending side by polling input directories and mailing all found files as attachments to configured addresses (was thought for human recipients originally).
How would you design the receiving side?
One could write a stripped down SMTP server that handles only this one case, strips attachments from incoming mails, and puts them into a local directory.
One could setup a full mail server with local delivery, poll the user’s inbox and try to extract files from there.
One could setup a full mail server with a configuration or procmail to directly extract attachments into a directory.
I don’t really like any of these proposals because they are all more involved than setting up a SSH or FTP server. Also I don’t have experience with setting up and administrating mail servers.
Do you have suggestions or experiences to share?
The target system is Linux/Unix, but if you know something platform independent I’d like to hear, too.
The most suitable way is to set up an ESB with SMTP support, like ServiceMix or Mule. Mule is more straight-forward to get started with.
I want to write some email scanning software and don't understand how to setup my server. I have a hosted web server running Windows 2003 Server. It is running the Default SMTP Virtual Server with a fully-qualified domain name of abcdef.com (example). DNS is pointing abcdef.com to my server. If I spoof an email from my desktop pc so that it appears to come from info#abcdef.com, and I send the email to a 'non-existant' email address then the bounceback does arrive on my web server and is stored in C:\inetpub\mailroot\Queue on the server - great! (I can scan it and handle the bounceback). However, if I simply send an email straight to info#abcdef.com then it does not seem to get placed anywhere on the server. I don't understand why bouncebacks get stored but other incoming email doesn't. I'm keen to avoid having to install any 'email server software' on the server, as I want to keep things as clean as possible. All I really want is some way of telling the server to accept all incoming messages to abcdef.com so that I can process them myself, and to place the .eml files in a known directory that I can scan. I'll then write an eml file parser to process the files.
Thanks very much.
A possible reason for the lack of delivery is that your domain has a DNS A record, but no DNS MX record. MX records are used for delivery of mail. Historically, if no MX record was present for a domain, mail servers were supposed to fall back to looking for a domain's A record.
In your case, I'd guess that your local mail-sending software is looking for an MX record and then stopping if it doesn't find one, whereas the remote system sending you the bounce is looking for the MX record and then looking for an A record when it can't find one.
The Wikipedia article on MX records has more details.
SMTP is a message transfer agent (MTA), responsible only for handling the transfer of mail from one point (the client, perhaps) to another (the mailbox server, such as a POP or IMAP server). SMTP servers aren't the right tool for ultimately handling mail coming INTO a domain -- they only handle transferring the mail coming into a domain to another app, such as the aforementioned POP or IMAP server, which then know how to sort and store that mail.
In short, the Default SMTP Virtual Server isn't the tool you're looking for for your project.
From this other StackOverflow question, it looks like there are a few SMTP servers which are intended for development use but which might serve the purpose you seek -- they accept incoming messages and then write them to files (in some manner, and with some tweaking).
Ok, working now. Issues were as follows:
There was no MX record, so external email wasn't being directed to the server. The .EML file that existed on the server was indeed placed there by an outbound email process.
The firewall was blocking port 25 - now opened.
It is necessary to have some sort of inbound email service running on the server. Windows Server has a lightweight POP3 service which you can configure to place all incoming email into a single 'catch-all' mailbox. This fills with .EML files, which can then be scanned by our custom service.
Many thanks to delfuego & Jon.