Wordfence Security
[resolved] Error on IP detection (6 posts)

  1. punkstar69
    Posted 3 years ago #

    Wordfence can't get the IP of clients and therefore can't operate. We received IP: . X-Forwarded-For was: REMOTE_ADDR was:

    I recieve this error, no matter which way of IP detection i choose.
    Im behind nginx and Varnish.

    Can you help me on whats wrong please? Can i force the REMOTE_ADDR by messing with plugin's code?

    Thanks in advance.


  2. WCat
    Posted 3 years ago #

    I would remove varnish. and use apc and memcached, also http://wordpress.org/extend/plugins/hyper-cache/. it looks to me like varnish is serving its own ip. Varnish adds a layer of complexity that imo isnt worth the headache by the time your done futzin with the vcl file to handle cookies and find that your site isnt any faster. apc is easy enough and installing memcached is a 3 step ordeal with no config neccesary.

    see http://rtcamp.com/tutorials/why-we-never-use-varnish-with-nginx/
    they also have a great tutorial for installing APC

  3. punkstar69
    Posted 3 years ago #

    Thanks for the response WCat!

    At this moment, we are behind a managed server in which he had no access to the setup of the box, so we cant do such a thing.

    Is there an alternative way for Wordfence to bypass this problem?

  4. drijen
    Posted 3 years ago #

    We are having the same issue with Varnish and Wordfence.

    At one point, the admins were actually blocked as the plugin through we were fake googlebots.

    We are using Apache and varnish. Does anyone know which option to select for 'how does Wordfence get IP addresses'? The issue happened after we selected 'Get X-Forwarded-For HTTP Header'.

    Varnish has certainly improved the speed of the site more than just Supercache and W3TC, so we would ideally like to get it working with Wordfence.

  5. Wordfence
    Plugin Author

    Posted 3 years ago #

    Hi Guys,

    Can you tell me which HTTP header Varnish uses to send the real IP of clients to the web server?



  6. punkstar69
    Posted 3 years ago #

    Hello and thanks for your answer mmaunder!

    The header sent is:


Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Wordfence Security
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic


No tags yet.