Title: Falcon enable within Apache
Last modified: August 22, 2016

---

# Falcon enable within Apache

 *  [jagjassel](https://wordpress.org/support/users/jagjassel/)
 * (@jagjassel)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/falcon-enable-within-apache/)
 * Hi there,
 * I am using Apache webserver and unable to find any documentation on How to enable
   Falcon for Apache web Server.
 * When I click to enable Falcon, I have been asked to update nginx.conf file and
   it directed me to a link which is talking about Nginx web server.
 * Do you have instructions for Apache?
 * [https://wordpress.org/plugins/wordfence/](https://wordpress.org/plugins/wordfence/)

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

 *  [WFSupport](https://wordpress.org/support/users/wfsupport/)
 * (@wfsupport)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/falcon-enable-within-apache/#post-5877313)
 * Enabling Falcon is usually just clicking the button to enable it. The most you
   have to do is manually edit your htaccess file if its not writable. We detect
   if your server is running nginx and tell you about it if we find it is. Please
   confirm with your webhost of you are or not. Let me know what they say.
 * tim
 *  [aurimas_m](https://wordpress.org/support/users/aurimas_m/)
 * (@aurimas_m)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/falcon-enable-within-apache/#post-5877331)
 * Hi,
 * actually I was just dealing with the same issue. Falcon is definitely great now
   that I was finally able to enable it by changing the code a bit (actually, 16
   bits ;).
 * The problem is that WF assumes that it’s enough to have $sapi == ‘fpm-fcgi’ to
   consider server running nginx. Which is a wrong assumption, because you can run
   fpm-fcgi with apache just as well. And that’s exactly what I’m running. It could
   be also a bug in the code (hence, the assumption, because it also checks $_SERVER[‘
   SERVER_SOFTWARE’] as an extra test).
 * So here’s what you need to do to fix it:
 * 1. Open wp-content/plugins/wordfence/lib/wfUtils.php
    2. Go to line 615 3. Replace“
   ||” with “&&”
 * Here’s the code that you are going to be altering for the reference:
 *     ```
       public static function isNginx(){
                       $sapi = php_sapi_name();
                       $serverSoft = $_SERVER['SERVER_SOFTWARE'];
                       if($sapi == 'fpm-fcgi' || stripos($serverSoft, 'nginx') !== false){
                               return true;
                       }
       ```
   
 * What you’re doing is changing the test so that it requires that both sapi equals
   fpm-fcgi and server software says nginx.
 *  [WFSupport](https://wordpress.org/support/users/wfsupport/)
 * (@wfsupport)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/falcon-enable-within-apache/#post-5877332)
 * Interesting. Let me get the dev team to take a look.
 * tim
    (ref FB683)
 *  [aurimas_m](https://wordpress.org/support/users/aurimas_m/)
 * (@aurimas_m)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/falcon-enable-within-apache/#post-5877341)
 * Thanks! Keep us posted.
 *  Thread Starter [jagjassel](https://wordpress.org/support/users/jagjassel/)
 * (@jagjassel)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/falcon-enable-within-apache/#post-5877388)
 * thanks, let me know.
 * I am certainly using Apache Web Server hosted on AWS virtual server.
 *  Thread Starter [jagjassel](https://wordpress.org/support/users/jagjassel/)
 * (@jagjassel)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/falcon-enable-within-apache/#post-5877462)
 * Did you get any update from development team?
 *  Thread Starter [jagjassel](https://wordpress.org/support/users/jagjassel/)
 * (@jagjassel)
 * [11 years, 2 months ago](https://wordpress.org/support/topic/falcon-enable-within-apache/#post-5877487)
 * I have made the changes as described by aurimas_m and I am pass one huddle but
   still the Falcon is not getting enabled (it is enabled from the plugin but not
   showing any performance improvements)
 * Any assistance would be appreciated. I have tried few different ways as described
   in different forums but no success.

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

The topic ‘Falcon enable within Apache’ is closed to new replies.

 * ![](https://ps.w.org/wordfence/assets/icon.svg?rev=2070865)
 * [Wordfence Security - Firewall, Malware Scan, and Login Security](https://wordpress.org/plugins/wordfence/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wordfence/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wordfence/)
 * [Active Topics](https://wordpress.org/support/plugin/wordfence/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wordfence/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wordfence/reviews/)

## Tags

 * [apache](https://wordpress.org/support/topic-tag/apache/)

 * 7 replies
 * 3 participants
 * Last reply from: [jagjassel](https://wordpress.org/support/users/jagjassel/)
 * Last activity: [11 years, 2 months ago](https://wordpress.org/support/topic/falcon-enable-within-apache/#post-5877487)
 * Status: not resolved