Per Apache:
This module is used to treat the useragent which initiated the request as the originating useragent as identified by httpd for the purposes of authorization and logging, even where that useragent is behind a load balancer, front end server, or proxy server.
1. In MAMP Pro, enable remoteip_module in Apache.
2. Open httpd.conf template.
3. Update your LogFormat log replacing %h with %a. (this will show client IP address of the request in log files) Example:
Code: Select all
LogFormat "%a %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" combined
4. Configure your trust proxy addresses accordingly.
Code: Select all
RemoteIPHeader CF-Connecting-IP
RemoteIPTrustedProxy 192.0.2.1 (example IP address)
RemoteIPTrustedProxy 192.0.2.2 (example IP address)
5. Restart MAMP Pro (Apache).