• Resolved laimermic

    (@laimermic)


    I have a Problem with my Wordfence installation.

    Always when i try to change a setting or get the report it doesn’t work. In the Networktraffic i see that there was a requst to admin-ajax.php which returned a Bad Reuqest error and a 0. Uninstall and reinstall didn’t help. I can’t change any settings.

    Edit: I found this line in the admin-ajax.php file.

    if ( empty( $_REQUEST['action'] ) ) {
    	wp_die( '0', 400 );
    }

    But why is the request empty?

    • This topic was modified 3 years, 7 months ago by laimermic.
Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Support wfpeter

    (@wfpeter)

    Hi @laimermic, thanks for reaching out to us.

    I’m wondering if there’s a plugin conflict here seeing that a reinstall didn’t seem to change anything. Could you please try disabling all plugins except for Wordfence and default the site back to a default theme such as Twenty Twenty-One? Are you able to save any settings or view Wordfence reports under these circumstances? If so, reenable your plugins one-by-one until the problem reoccurs, and finally reenable your theme. You can install a maintenance mode plugin during this process to prevent visitors from encountering issues.

    If you’re unable to find another plugin or theme’s involvement in why the requests are empty, can you send a diagnostic report to wftest @ wordfence . com? You can find the link to do so at the top of the Wordfence Tools > Diagnostics page. Then click on “Send Report by Email”. Please add your forum username where indicated and respond here after you have sent it.

    Note: For the fastest response time, please make sure and add any information or questions directly to this topic and not the email address above unless asked.

    Thanks,

    Peter.

    Thread Starter laimermic

    (@laimermic)

    Ok i will try disabling all Plugins, etc.

    Unfortunately i am not able to change any setting. But i think i can generate a report

    Plugin Support wfpeter

    (@wfpeter)

    Thanks @laimermic, let me know how that goes for you.

    Peter.

    Thread Starter laimermic

    (@laimermic)

    Unfortunately deactivating Plugins and Theme didn’t help anything. Sending a report is also not possible but i can download a report. Can i send that report manually to [email protected], or is that only possible through the wordfence installation?

    Maybe it would help if i could delete wordfence and all related data. But due to the option “Delete Wordfence tables and data on deactivation” (which is deactivated on my site) this does not work for me. I can’t change this setting too.

    Plugin Support wfpeter

    (@wfpeter)

    Hi @laimermic,

    You certainly can send the report manually, just make sure to reference your forum username in the subject line so that we can easily find it.

    The blank requests when changing our settings are curious, do you experience this with any other plugins or elsewhere on the site while Wordfence itself is disabled? Wordfence can be manually removed if you’re having trouble with the front-end by following the “Manual Removal” instructions in this guide: https://www.wordfence.com/help/advanced/remove-or-reset/

    Thanks again,

    Peter.

    Thread Starter laimermic

    (@laimermic)

    I completely removed wordfence and reinstalled it. Unfortunately, that didn’t help. The error is still the same. If the Wordfence plug-in is deactivated, the error does not occur with other plug-ins. I have now manually emailed the report

    Plugin Support wfpeter

    (@wfpeter)

    Hi @laimermic, I received your manually sent diagnostic.

    Your connectivity to/from our servers and other configuration all seem to check out as “OK” so the idea that local changes are not saving is certainly an unusual one.

    As bizarre as it sounds, as Wordfence should definitely not be blocking itself, have you tried putting Wordfence into Learning Mode? From the Wordfence Dashboard click on Manage WAF. Then you will see Basic Firewall Options > Web Application Firewall Status. Change the option to Learning Mode. Now perform the actions that were causing issues. This will help Wordfence learn that these actions are normal and it will allow them in the future. After you have finished performing the actions, switch the WAF from Learning Mode back to Enabled and Protecting. Now test to see if these actions work correctly going forward.

    There could however be a proxy server or firewall on your server side that is blocking these actions. Are you aware of anything like that? If not it could be worth reaching out to your host to see if they can explain why saving Wordfence settings and other operations in the plugin are being stopped. Another hint could be found by deliberately trying to make the error reoccur then checking Wordfence > Tools > Diagnostics > Log Files. If there’s a recent entry that matches up with the request you just made, it should provide more detailed error information that you can paste to me here.

    Many thanks,

    Peter.

    Thread Starter laimermic

    (@laimermic)

    Hi @wfpeter, sorry for the late answer

    Hallelujah it worked!

    The problem was that the main page in our multisite network can be reached at https://www.websiteadress.at.
    However, the network administration is linked at https://websiteadress.at. Due to the lack of www in the network address, there was a cross origin request which was prevented by the same-origin-policy. In the line

    define ('DOMAIN_CURRENT_SITE', 'websiteadress.at');

    the www was missing in the wp-config.php. Unfortunately, WordPress then causes problems with infinite redirects in the network administration. If I set the entry in the wp-config without www and then manually insert a www into the URL bar, there is no infinite forwarding. Weird, but that’s another topic ??

    Many thanks for your help!!!

    • This reply was modified 3 years, 5 months ago by laimermic.
Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Wordfence Bad Request’ is closed to new replies.