Support Forum
The Forums are a place to find answers on a range of Fortinet products from peers and product experts.
gibux
New Contributor

mail.domain.com: How to reroute imap, pop3 and smtp traffic

Hi guys
I use Dovecot and Exim as mail servers.
In our architecture there are 2 servers with Dovecot Proxy Director installed and two other servers with Dovecot Backend with Exim.
The Proxy Director is used to orchestrate IMAP and POP3 traffic (ports 993 and 995) on the Backend servers.
On the Backends, Dovecot is active for mailbox management (ports 993 and 995) and Exim for outgoing mail (ports 465 and 587).
It is clear that when configuring a mail client, it is defined as incoming server imap.domain.com:993 or pop3.domain.com:995 (depending on the type of protocol chosen) and as outgoing server smtp.domain.com:465.
The imap and pop service is redirected to Dovecot Proxy Director servers and the smtp service to Dovecot backends.
The problem arises with some mail clients that require a single name (for both inbound and outbound servers). For example: mail.domain.com
How can I redirect mail.domain.com:993 (or 995) traffic to Proxy Director servers and mail.domain.com:465 (or 587) traffic to Backend servers?
Should I use a virtual server?
Thanks in advance for any help!

3 REPLIES 3
AEK
SuperUser
SuperUser

Hello

If I understand well your concern, the solution is to create 3 VIPs with port forwarding, as follows:

  • VIP1:  mail.domain.com : 993  ->  Dovecot Proxy Director : 993
  • VIP2:  mail.domain.com : 995  ->  Dovecot Proxy Director : 995
  • VIP3:  mail.domain.com : 465  ->  Dovecot backend : 465

Ref:  https://community.fortinet.com/t5/FortiGate/Technical-Tip-Virtual-IP-VIP-port-forwarding-configurati...

AEK
AEK
gibux
New Contributor

Hi AEK
Do you think of a similar configuration??

 

all.png

vip1.png

 

 

vip2.png

 

vip3.png

 

 

AEK

Hi @gibux 

Personally I have more experience with VIP than VS, however your config looks fine. So you may need to test it and tune it if required.

AEK
AEK
Announcements

Select Forum Responses to become Knowledge Articles!

Select the “Nominate to Knowledge Base” button to recommend a forum post to become a knowledge article.

Labels
Top Kudoed Authors