Sender address rewrite from internal to external domains (Zimbra 8.7)

Discuss your pilot or production implementation with other Zimbra admins or our engineers.
User avatar
opsystem
Posts: 22
Joined: Mon Nov 20, 2017 6:32 pm

Sender address rewrite from internal to external domains (Zimbra 8.7)

Postby opsystem » Fri Dec 08, 2017 1:04 am

Hi all,

I’ve one of those situations where mailboxes are @localdomain and users should be able to send messages outside via external relay as, let’s say, externaluser@realdomain.com.

So the goal here is:
sender user@localdomain -> *anyuser*@localdomain ----> no rewrite
sender user@localdomain -> rest of the world ----> sender rewrite as externaluser@realdomain.com -> external relay

Postfix has a parameter for this: smtp_generic_maps (zimbraMtaSmtpGenericMaps), this works but problem is that senders are rewritten when recipients are internal too – and that's quite strange (as Postfix guide says "It does not happen when you send mail between addresses on the local machine").
Any suggestions?
Thanks

P.S. I'm already using Personas as external accounts, the issue here is when using internal accounts only.


AcidVenom
Posts: 1
Joined: Thu Mar 15, 2018 5:30 am

Re: Sender address rewrite from internal to external domains (Zimbra 8.7)

Postby AcidVenom » Thu Mar 15, 2018 5:32 am

Same situation. I think need a feature request.
User avatar
oetiker
Advanced member
Advanced member
Posts: 138
Joined: Fri Mar 07, 2014 1:05 pm
Location: Switzerland
Contact:

Re: Sender address rewrite from internal to external domains (Zimbra 8.7)

Postby oetiker » Fri Jun 15, 2018 2:45 pm

hi

does this not work with a sender_canonical map. I could not found a who to about that but since zimbra is using postfix it should
be done by a sender_canonical_map

somthing like this https://wiki.zimbra.com/wiki/How_to_redirect_mails_from_specific_email_to_one_user example just with an other map
on that page https://wiki.zimbra.com/wiki/Postconf_keys I found the key zimbraMtaSenderCanonicalMaps

Code: Select all

zmprov mcf zimbraMtaSenderCanonicalMaps 'pcre:/opt/zimbra/conf/postfix_sender_canonical'

cat /opt/zimbra/conf/postfix_sender_canonical

Code: Select all

@localdomain    @realdomain.com

has anybody done this?

cheers Manuel
gek
Posts: 3
Joined: Wed May 11, 2016 1:47 pm

Re: Sender address rewrite from internal to external domains (Zimbra 8.7)

Postby gek » Sat Jun 16, 2018 12:42 pm

opsystem wrote:Hi all,

I’ve one of those situations where mailboxes are @localdomain and users should be able to send messages outside via external relay as, let’s say, externaluser@realdomain.com.

So the goal here is:
sender user@localdomain -> *anyuser*@localdomain ----> no rewrite
sender user@localdomain -> rest of the world ----> sender rewrite as externaluser@realdomain.com -> external relay

Postfix has a parameter for this: smtp_generic_maps (zimbraMtaSmtpGenericMaps), this works but problem is that senders are rewritten when recipients are internal too – and that's quite strange (as Postfix guide says "It does not happen when you send mail between addresses on the local machine").
Any suggestions?
Thanks

P.S. I'm already using Personas as external accounts, the issue here is when using internal accounts only.


Hello! Could you explain, before adding persona's external email, did you created domain alias for that external mail?
By your example:
you have user@localdomain mailbox -> but you need to send a message from user@realdomain -> do you create @realdomain alias to @localdomain ? Or just create a persona and allow user's persona send mail from user@realdomain in
"admin console-> edit the account (or COS)-> select the 'Preferences' tab -> Allow sending mail only from these addresses: " ?

OH, +1 to the topic question!

upd. i've found that solution. I think it's very similar to.

Return to “Administrators”

Who is online

Users browsing this forum: No registered users and 23 guests