Attaining Client IP Address failing

I’m really attempting to be self-sufficient and not request support from Invision Power Services (software) or Hostgator (Host). Since moving to Cloudflare, I am receiving all Cloudflare IP addresses for my visitors which is a huge problem for my site. I understand why this is so, AND I have attempted multiple fixes that I have found. However, none of them have succeeded.

For the moment, I have turned off proxy on the www record so I get the proper address. But, I certainly don’t wish to leave it that way. I’ve tried mod_cloudflare on EasyApache 4, no go. Script runs to the end (very fast) and accomplishes nothing. I am doing this from terminal under the CPanel login, not root, as that is where the directories that the script is looking for are located.

I have searched for the RPM on Hostgator, think perhaps they had mod_cloudflare or a similar remoteip function available. No go.

I’m at a loss. Anyone experience the same or have any helpful hints?

Thank you

You have two choices:

  1. Install something as root on the server (mod_remoteip, etc).
  2. Configure your site software to pull the Visitor IP address from the headers (X-Forwarded-For or CF-Connecting-IP)

I remember IPS had an option to trust the ip given on the headers instead of the connecting IP, should be somewhere in the admin panel.
Unfortunately Its been a while since I used IPS so I can’t give you further help. I’m guessing the admin panel has changed a bit since then.

1 Like

Yes, you are correct… They do have a proxy setting that addresses this. Tested it and it worked.

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.