11 May, 2023

Plesk

liton

905 views


Symptoms

  1. Domain is not available with the following error shown:

    500
    Internal Server Error

  2. The following messages can be found in Domains > example.com > Logs or in /var/www/vhosts/example.com/logs/error.log file:

    [error] [client 203.0.113.2] ModSecurity: Output filter: Response body too large (over limit of 524288, total not specified). [hostname "www.example.com"] [uri "/index.php"] [unique_id "W*****U43-wA*****G"]

Cause

Domain exceeded the default SecResponseBodyLimit parameter for ModSecurity (512 Kb).

Resolution

  1. Log in to Plesk.

  2. Navigate to Domains > example.com > Apache & nginx Settings

  3. Add the following line to Additional directives for HTTP and to Additional directives for HTTPS:

    <IfModule mod_security2.c>
    SecResponseBodyLimit 536870912
    </IfModule>

  4. Press Apply .

Server-wide
  1. Log in to Plesk.

  2. Navigate to Tools & settings > Web Application Firewall (ModSecurity) > Settings > Custom directives section:

  3. Add the following line:

    SecResponseBodyLimit 536870912

  4. Press Apply

Reference:

https://support.plesk.com/hc/en-us/articles/12388040127383

https://talk.plesk.com/threads/mod_security-error-response-body-too-large.350523/