Sending remote IP address to Dovecot IMAP
In version 9.7.7, we've added a feature that allows Aurora Corporate to send actual user's IP address to Dovecot IMAP server, rather than IP addres of Aurora Corporate installation. Technically that means sending the following command to the server:
ID ("x-originating-ip" "y.y.y.y")
To enable this feature, set ImapSendOriginatingIP to true in data/settings/modules/Mail.config.json file.
You'll also need to add Aurora Corporate installation's IP to login_trusted_networks configuration option of Dovecot. For example in case of Dovecot 2.3:
# Example; replace with Aurora Corporate server IP address
login_trusted_networks = 192.0.2.10
Only specific Aurora Corporate server should be trusted, even 127.0.0.1 address should be explicitly added if Dovecot and Aurora Corporate are on the same system.
After these changes, debug logs of Aurora Corporate should now have ID command, and Dovecot logs would contain user's IP address in rip.