Title: Optimizing Firewall Issue
Last modified: November 29, 2019

---

# Optimizing Firewall Issue

 *  Resolved [KoolKatDesign](https://wordpress.org/support/users/koolkatdesign/)
 * (@koolkatdesign)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/optimizing-firewall-issue/)
 * I was not able to complete the optimization setup process within the WP dashboard
   so I followed the manual configuration instructions provided. However, a PHP 
   variables icon is not visible in my Cpanel. My hosting support told me to use
   the file manager to edit the php.ini file and insert the code provided in your
   documentation: auto_prepend_file = ‘/home1/amwsorg/public_html/wordfence-waf.
   php’
 * I did this and it is showing up in my php info now but the optimization warning
   is still appearing in the WP dashboard. Hosting confirmed that we only have 1
   website in our single hosting account so that is not causing this issue.
 * Please advise on what I did wrong or why the optimization warning is still appearing
   in WP?
 * Thanks.
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Foptimizing-firewall-issue%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

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

 *  Plugin Support [wfscott](https://wordpress.org/support/users/wfscott/)
 * (@wfscott)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/optimizing-firewall-issue/#post-12206163)
 * [@koolkatdesign](https://wordpress.org/support/users/koolkatdesign/)
 * Thanks for writing in and sorry for the delay.
 * Which hosting provider are you with? Is it SiteGround?
 * Thanks,
    Scott
 *  Thread Starter [KoolKatDesign](https://wordpress.org/support/users/koolkatdesign/)
 * (@koolkatdesign)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/optimizing-firewall-issue/#post-12206198)
 * HostMonster
 *  Plugin Support [wfscott](https://wordpress.org/support/users/wfscott/)
 * (@wfscott)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/optimizing-firewall-issue/#post-12206218)
 * [@koolkatdesign](https://wordpress.org/support/users/koolkatdesign/)
 * Can you please send me over diagnostics to wftest @ wordfence dot com via Wordfence
   > Tools > Diagnostics > Send Report by Mail — please put your username in the
   second field there and let me know here when they are sent.
 * Thanks,
 * Scott
 *  Thread Starter [KoolKatDesign](https://wordpress.org/support/users/koolkatdesign/)
 * (@koolkatdesign)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/optimizing-firewall-issue/#post-12206245)
 * just sent it as requested
 *  Plugin Support [wfscott](https://wordpress.org/support/users/wfscott/)
 * (@wfscott)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/optimizing-firewall-issue/#post-12206298)
 * I haven’t seent that email come over. Can you confirm — [wftest@wordfence.com](https://wordpress.org/support/topic/optimizing-firewall-issue/wftest@wordfence.com?output_format=md)
 *  Thread Starter [KoolKatDesign](https://wordpress.org/support/users/koolkatdesign/)
 * (@koolkatdesign)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/optimizing-firewall-issue/#post-12206741)
 * I sent it 2 or 3 times following your instructions. Did you get it yet?
 *  Plugin Support [wfscott](https://wordpress.org/support/users/wfscott/)
 * (@wfscott)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/optimizing-firewall-issue/#post-12210384)
 * Sorry, [@koolkatdesign](https://wordpress.org/support/users/koolkatdesign/), 
   I have not. Try sending them to your own email address and let me know if you
   receive them there.
 * Is the site set up in the root/public_html, htdocs, or is it in a sub folder?
 * Thanks,
    Scott
 *  Thread Starter [KoolKatDesign](https://wordpress.org/support/users/koolkatdesign/)
 * (@koolkatdesign)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/optimizing-firewall-issue/#post-12210400)
 * [@wfscott](https://wordpress.org/support/users/wfscott/) I just did and it came
   through to my email immediately and without issue. I just forwarded it directly
   from my email inbox to [wftest@wordfence.com](https://wordpress.org/support/topic/optimizing-firewall-issue/wftest@wordfence.com?output_format=md)
 * Did it come through this way? Could it be getting caught in your spam folder?
 * This is the path (/home1/amwsorg/public_html/php.ini) to the php.ini file that
   I updated with this code at the end: auto_prepend_file = ‘/home1/amwsorg/public_html/
   wordfence-waf.php’
 * I just confirmed that the wordfence-waf.php file is also in the correct directory.
 * This link confirms that the auto_prepend_file variable is configured correctly:
   [https://www.amws.org/info.php](https://www.amws.org/info.php)
    -  This reply was modified 6 years, 4 months ago by [KoolKatDesign](https://wordpress.org/support/users/koolkatdesign/).
    -  This reply was modified 6 years, 4 months ago by [KoolKatDesign](https://wordpress.org/support/users/koolkatdesign/).
    -  This reply was modified 6 years, 4 months ago by [KoolKatDesign](https://wordpress.org/support/users/koolkatdesign/).
    -  This reply was modified 6 years, 4 months ago by [KoolKatDesign](https://wordpress.org/support/users/koolkatdesign/).
 *  Plugin Support [wfscott](https://wordpress.org/support/users/wfscott/)
 * (@wfscott)
 * [6 years, 3 months ago](https://wordpress.org/support/topic/optimizing-firewall-issue/#post-12224736)
 * [@koolkatdesign](https://wordpress.org/support/users/koolkatdesign/)
 * Thanks for the update. Are you putting koolkatdesign in the second field after
   the email? We have many diagnostics in our email so I am primarily looking for
   that. Is it another name there by chance?
 * Check your system configuration (at the bottom of your diagnostics page there
   is a link to view your configuration in a new window) and look to see if auto_prepend_file
   has a local value. If it does not, the setting in the php.ini is not being used
   and would be the issue.
 * Scott
 *  Thread Starter [KoolKatDesign](https://wordpress.org/support/users/koolkatdesign/)
 * (@koolkatdesign)
 * [6 years, 3 months ago](https://wordpress.org/support/topic/optimizing-firewall-issue/#post-12224807)
 * [@wfscott](https://wordpress.org/support/users/wfscott/)
 * I used the Ticket Number/Forum Username: [@koolkatdesign](https://wordpress.org/support/users/koolkatdesign/)
   and koolkatdesign in all diagnostic emails sent to you [wftest@wordfence.com](https://wordpress.org/support/topic/optimizing-firewall-issue/wftest@wordfence.com?output_format=md).
   I also emailed you from [kathleen@koolkatdesign.com](https://wordpress.org/support/topic/optimizing-firewall-issue/kathleen@koolkatdesign.com?output_format=md)
   on 12/5 at 6:15pm.
 * As per my note above clicking here [https://www.amws.org/info.php](https://www.amws.org/info.php)
   confirms that auto_prepend_file has a local value. This is how my hosting company’s
   support tech confirmed that it is being used and not an issue on their side.
 *  Plugin Support [wfscott](https://wordpress.org/support/users/wfscott/)
 * (@wfscott)
 * [6 years, 3 months ago](https://wordpress.org/support/topic/optimizing-firewall-issue/#post-12225008)
 * We see auto_prepend_file appears to be set correctly in that phpinfo file — if
   it doesn’t show that the WAF is optimized when you view the Firewall page in 
   Wordfence’s dashboard, the auto_prepend might not be applied to subdirectories.
 * One thing to try is setting the PHPRC in the .htaccess file in public_html, like
   so:
 * SetEnv PHPRC /home1/amwsorg/public_html/php.ini
 * Thanks,
    Scott
 *  Thread Starter [KoolKatDesign](https://wordpress.org/support/users/koolkatdesign/)
 * (@koolkatdesign)
 * [6 years, 3 months ago](https://wordpress.org/support/topic/optimizing-firewall-issue/#post-12225123)
 * I just added that code at the end of the .htaccess file in public_html and saved
   then went back to Wordfence’s dashboard and refreshed but the WAF is still showing
   as not optimized? Do I just abandon this issue by clicking dismiss? Or is it 
   worth the time to pursue?
 *  Plugin Support [wfscott](https://wordpress.org/support/users/wfscott/)
 * (@wfscott)
 * [6 years, 3 months ago](https://wordpress.org/support/topic/optimizing-firewall-issue/#post-12231988)
 * [@koolkatdesign](https://wordpress.org/support/users/koolkatdesign/)
 * A colleague of mine suggested changing the php.ini file name to .user.ini. That
   is the one in public_html.
 * Please let me know if the firewall shows 100% after that.
 * Also, it is recommended to remove the PHP Info file that you created from the
   site whenever you’re able.
 * Scott
 *  [WFGerroald](https://wordpress.org/support/users/wfgerald/)
 * (@wfgerald)
 * [6 years, 3 months ago](https://wordpress.org/support/topic/optimizing-firewall-issue/#post-12286803)
 * Hey [@koolkatdesign](https://wordpress.org/support/users/koolkatdesign/),
 * We haven’t heard back from you in a while, so I’ve gone ahead and marked this
   thread as resolved.
 * Please feel free to open another thread if you’re still having issues with Wordfence.
 * Thanks,
 * Gerroald
 *  Thread Starter [KoolKatDesign](https://wordpress.org/support/users/koolkatdesign/)
 * (@koolkatdesign)
 * [6 years, 3 months ago](https://wordpress.org/support/topic/optimizing-firewall-issue/#post-12286875)
 * [@wfgerald](https://wordpress.org/support/users/wfgerald/) None of the suggestions
   worked so I just hit the dismiss button and had to move on.

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

The topic ‘Optimizing Firewall Issue’ 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/)

 * 15 replies
 * 3 participants
 * Last reply from: [KoolKatDesign](https://wordpress.org/support/users/koolkatdesign/)
 * Last activity: [6 years, 3 months ago](https://wordpress.org/support/topic/optimizing-firewall-issue/#post-12286875)
 * Status: resolved