SpartaSystems / holdmail

HoldMail is a Java Application for proxying SMTP mail, providing a browsable viewer for captured emails.
Apache License 2.0
32 stars 15 forks source link

HoldMail as proxy smtp server #29

Open masikbelka opened 7 years ago

masikbelka commented 7 years ago
Question

Hello guys, could we have some property(for example: holdmail.smtp.as.proxy=true), which will sends all recieved emails to holdmail.outgoing.smtp.server ?? The purpose of this is that on DEV env our test team check emails in theirs emails(from smtp server without REST), but for ui automation(that runs against DEV env) we should check email in automated mode

Expected Behavior

All emails that HoldMail are recieved forwarded to holdmail.outgoing.smtp.server if property holdmail.smtp.as.proxy enabled

I can push such changes if you dont mind

barryoneill commented 7 years ago

Hey - thanks for the feature suggestion! I like your suggested configuration too.

One concern I have is - If the upstream SMTP server (holdmail.outgoing.smtp.server) has been configured to 'trust' SMTP traffic from a particular holdmail install, then this feature would essentially turn holdmail into an open relay (technically this concern exists now, but you at least have to manually hit an endpoint to manually release the mail to the upstream smtp server). That said, if a network admin is allowing holdmail to release mails to the world, that's on them. :) @johnament, @kblief - what do you think?

Just as an alternate suggestion, you might be able to put an SMTP server in front of holdmail that'll do the same work (e.g. send a copy of your mail to the outgoing host directly, and another to holdmail). A quick search shows this isn't something commonly done, but perhaps this might be a way to achieve what you want without a code change? - https://serverfault.com/a/191065

Unless anyone disagrees, and you still want this feature, yes - please - we'd love you to get involved - please check the contributing guide. Thanks!