Manual Firewall Installation

  • March 11, 2025
  • 0 Comments



  • Download the Firewall Plugin (no installer)
  • Unzip the waffirewall.zip to your desktop. You should get this content:
  1. .dome_1.php (file)
  2. /waffirewall (directory)

  • Edit the file .dome_1.php with your preferred editor. Around the line number 280, replace  YOUR_LICENSE_TOKEN  by your valid license string. DO NOT remove the apostrophe (')
  • Upload them to the main directory of your application or website. Usually "www" or "public_html". The root directory is where your index.html or index.php home page.
  • Use steps below to change your php.


Steps to change PHP Execution:


To automatically include .dome_1.php in every PHP request, you can use one of the following methods. We recommend starting with .htaccess as it takes effect instantly, unlike php.ini or .user.ini, which may take up to 5 minutes to apply. But if you do not know what is the type of your server and php handler, it's recommended to try php.ini or .user.ini




Method 1: Using .htaccess (Instant Effect)

Edit or create a .htaccess file in your website’s root directory and add the appropriate code block based on your server type:

  • For mod_php (Apache with PHP module):

    <IfModule mod_php.c>
    php_value auto_prepend_file "/full/path/to/.dome_1.php"
    </IfModule>
    <IfModule mod_php7.c>
    php_value auto_prepend_file "/full/path/to/.dome_1.php"
    </IfModule>
    <IfModule mod_php5.c>
    php_value auto_prepend_file "/full/path/to/.dome_1.php"
    </IfModule>

  • For LiteSpeed:

    <IfModule LiteSpeed>
    php_value auto_prepend_file "/full/path/to/.dome_1.php"
    </IfModule>
    <IfModule lsapi_module>
    php_value auto_prepend_file "/full/path/to/.dome_1.php"
    </IfModule>

  • For fcgid (FastCGI):

    <IfModule mod_fcgid.c>
    php_value auto_prepend_file "/full/path/to/.dome_1.php"
    </IfModule>
    <IfModule mod_fastcgi.c>
    php_value auto_prepend_file "/full/path/to/.dome_1.php"
    </IfModule>

  • For Other Servers:

    php_value auto_prepend_file "/full/path/to/.dome_1.php"
    
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteCond %{REQUEST_URI} \.php$
    RewriteRule .* - [E=PHP_VALUE:auto_prepend_file="/full/path/to/.dome_1.php"]
    </IfModule>

Replace /full/path/to/.dome_1.php with the actual absolute path to your file.

The effect is immediate. So if ever your website home page returns a 500 error code, you must just remove the code on your .htaccess to get your pages working. 



Method 2: Using php.ini (Delayed Effect)

  • Locate your php.ini file (check phpinfo() for its path).
  • Add the below line:

    auto_prepend_file = "<span>/full/path/to/.dome_1.php"</span>
  • Save the file and restart your web server (Apache/Nginx).



Method 3: Using .user.ini (Delayed Effect)

  • Create or edit a .user.ini file in your website’s root directory.

  • Add this line:

    auto_prepend_file = "<span>/full/path/to/.dome_1.php"</span>



To confirm that the prepend file is working, check your firewall dashboard or analytics section for:

  • A new user connection.
  • An incremented "hits" count.

This indicates that .dome_1.php is being executed as expected.

How helpful was this article to you?

Posting has been disabled.