Title: HTTP_CF_CONNECTING_IP
Last modified: July 13, 2021

---

# HTTP_CF_CONNECTING_IP

 *  Resolved [neoxyn](https://wordpress.org/support/users/neoxyn/)
 * (@neoxyn)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/http_cf_connecting_ip/)
 * Hey guys!
 * First of all thank you for this awesome plugin.
 * Recently I connected my website to cloudflare and today I recognised the “HTTP_CF_CONNECTING_IP”
   message.
 * I followed your guide and uploaded the htninja on my server. In the Dashboard
   I see that the plugin finds the file, however it still shows the HTTP_CF_CONNECTING_IP
   message.
 * So I m not sure, if everything is working fine… In the htninja file I just deleted
   the Incapsula CDN service coding. Do I have to do anything else?
 * Thank you in advance for your help.
 * Best Regards
    Neoxyn

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Author [nintechnet](https://wordpress.org/support/users/nintechnet/)
 * (@nintechnet)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/http_cf_connecting_ip/#post-14658686)
 * If the file appears to be loaded but it doesn’t work as expected, the code is
   likely wrong. This is what you should have in the .htninja when using cloudflare:
 *     ```
       <?php
       /*
        +===========================================================================================+
        | NinjaFirewall optional configuration file                                                 |
        |                                                                                           |
        | See: https://blog.nintechnet.com/ninjafirewall-wp-edition-the-htninja-configuration-file/ |
        +===========================================================================================+
       */
   
       // Users of Cloudflare CDN:
       if (! empty($_SERVER["HTTP_CF_CONNECTING_IP"]) &&
        filter_var($_SERVER["HTTP_CF_CONNECTING_IP"],FILTER_VALIDATE_IP)) {
          $_SERVER["REMOTE_ADDR"] = $_SERVER["HTTP_CF_CONNECTING_IP"];
       }
       ```
   
 *  Thread Starter [neoxyn](https://wordpress.org/support/users/neoxyn/)
 * (@neoxyn)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/http_cf_connecting_ip/#post-14659751)
 * Hey,
 * with the new code it works. Thank you very much!
 * Have a nice day!

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘HTTP_CF_CONNECTING_IP’ is closed to new replies.

 * ![](https://ps.w.org/ninjafirewall/assets/icon-256x256.png?rev=976137)
 * [NinjaFirewall (WP Edition) - Advanced Security Plugin and Firewall](https://wordpress.org/plugins/ninjafirewall/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/ninjafirewall/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/ninjafirewall/)
 * [Active Topics](https://wordpress.org/support/plugin/ninjafirewall/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/ninjafirewall/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/ninjafirewall/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [neoxyn](https://wordpress.org/support/users/neoxyn/)
 * Last activity: [4 years, 11 months ago](https://wordpress.org/support/topic/http_cf_connecting_ip/#post-14659751)
 * Status: resolved