Receipient verification

Questions and answers about how to do stuff
Post Reply
GJurriens
Posts: 10
Joined: 28 Mar 2016 10:29

Receipient verification

Post by GJurriens »

Hello all,

I'm trying to get receipient verification working as there is quite some mail being sent to my domain without a valid receipient.
I currently have things setup like this:

Internet (mail targetted at mydomain.com) -> EFA Project -> Exchange 2016
Internet (mail targetted at sub.mydomain.com) -> EFA Project -> SMTP host (forwards *@sub.mydomain.com to me@mydomain.com) -> Exchange 2016

Both routes are correct.
For mydomain.com I need to have receipient verification on and for sub.mydomain.com I do not need receipient verification (as it is an applicance to have wildcard mail forwarded to a mail receipient in mydomain.com).

Can anyone help me out with the right config? I have no clue on how to get this working.

Thanks in advance.
Guido

P.S. I do use the wildcard@sub.mydomain.com to subscribe to sites (so I can also immediately see if one of the services leaked my mail, just like dropbox did a while back).
stusmith
Posts: 63
Joined: 27 Jan 2017 15:24

Re: Receipient verification

Post by stusmith »

http://www.postfix.org/ADDRESS_VERIFICATION_README.html

This is a good place to start. Are you trying to verify the "From:" addresses for e-mail sent to your domains or the "To:" addresses?
GJurriens
Posts: 10
Joined: 28 Mar 2016 10:29

Re: Receipient verification

Post by GJurriens »

stusmith wrote: 08 Mar 2017 18:57 http://www.postfix.org/ADDRESS_VERIFICATION_README.html

This is a good place to start. Are you trying to verify the "From:" addresses for e-mail sent to your domains or the "To:" addresses?
Thank you for your reply.
I already found that link, but it didn't make to much sense for me.

I'm trying to verify the mail adresses on my own domains (so that would be the To: address).
stusmith
Posts: 63
Joined: 27 Jan 2017 15:24

Re: Receipient verification

Post by stusmith »

Okay, since you listed Exchange in your first post, I would look at the post here, which has a number of good instructions to follow viewtopic.php?f=14&t=1484

/etc/postfix/main.cf

Code: Select all

relay_recipient_maps = ldap:/etc/postfix/ldap_relay_recipient_maps.cf,
                                    hash:/etc/postifx/local_relay_recipient_maps.cf

relay_domains = hash:/etc/postfix/transport
/etc/postfix/local_relay_recipient_maps.cf
NO SPACES, ONLY TAB CHARACTERS

Code: Select all

@your.subdomain.com     OK
After creating the file, you'll need to run:

Code: Select all

sudo postmap /etc/postfix/local_relay_recipient_maps.cf
/etc/postfix/transport

Code: Select all

yourdomain.com	smtp:[<FQDN or IP address here>]
your.subdomain.com	smtp:[<FQDN or IP address here>]


Once you get the LDAP lookup to your Active Directory set up, you'll be able to reject addresses that are not listed in Active Directory. Then, adding the local_relay_recipient_maps.cf will map a wildcard to your subdomain. Reload/restart postfix once you're done and you should be good to go.
GJurriens
Posts: 10
Joined: 28 Mar 2016 10:29

Re: Receipient verification

Post by GJurriens »

Thank you for your reply.
I did have the AD check in place at some time (working), but removed it because of the wildcard domain.
I'm shure I'll get it working with the instructions below.

Thanks again.
Post Reply