Ok, your router does not know how to get to 172.16.0.2 directly but to the WAN IP of IPFire. You must create a “DMZ Host” in the router to redirect all requests to your Public IP to the IPFire WAN interface. I, for example, have it configured like this on my router:
In “Source” you can put “Standard networks: ANY” or if you want only from one country, the one you want (as I have it) or you can also create a group of countries.
Obviously you will have to activate it (I don’t use it and that’s why I have it deactivated). The Log is optional.
Thanks for your reply. It forced me to take a closer look at my firewall rules, and I realized that I had set the Source to Red instead of Any. After fixing that, I can now access my IMAP server using my external IP address from both inside and outside of my network. Problem solved!