• Hi, Pleskians! We are running a UX testing of our upcoming product intended for server management and monitoring.
    We would like to invite you to have a call with us and have some fun checking our prototype. The agenda is pretty simple - we bring new design and some scenarios that you need to walk through and succeed. We will be watching and taking insights for further development of the design.
    If you would like to participate, please use this link to book a meeting. We will sent the link to the clickable prototype at the meeting.
  • (Plesk for Windows):
    MySQL Connector/ODBC 3.51, 5.1, and 5.3 are no longer shipped with Plesk because they have reached end of life. MariaDB Connector/ODBC 64-bit 3.2.4 is now used instead.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.

Issue Problem with web application firewall - file extension is restricted by policy

Ras Alghul

New Pleskian
Server operating system version
Plesk Obsidian v18.0.58_build1800240123.15 os_Ubuntu 22.04
Plesk version and microupdate number
Plesk Obsidian v18.0.58_build1800240123.15 os_Ubuntu 22.04
Hi,

We are experiencing an issue with one of our customers, unique to their case.

They encounter difficulties accessing our Nextcloud installation when the Web Application Firewall is enabled. This user, who operates on both Mac and iPhone, faces constant rejections. This issue persists whether they use the Nextcloud app or the desktop application, and even attempts to connect via an HTTPS browser result in rejection.

Upon reviewing the log files, this problem's cause remains unclear. It's particularly puzzling as other Apple Mac users do not encounter these issues.

Could you help us understand why this is happening and why it's isolated to this specific user?

Code:
--f7d4e022-H--
Message: Access denied with code 403 (phase 2). Match of "pmFromFile userdata_wl_extensions" against "TX:extension" required. [file "/etc/apache2/modsecurity.d/rules/comodo_free/10_HTTP_HTTP.conf"] [line "27"] [id "210730"] [rev "5"] [msg "COMODO WAF: URL file extension is restricted by policy||customer.domain.com|F|2"] [data ".com"] [severity "CRITICAL"] [tag "CWAF"] [tag "HTTP"]
Apache-Error: [file "apache2_util.c"] [line 275] [level 3] [client 80.187.80.166] ModSecurity: Access denied with code 403 (phase 2). Match of "pmFromFile userdata_wl_extensions" against "TX:extension" required. [file "/etc/apache2/modsecurity.d/rules/comodo_free/10_HTTP_HTTP.conf"] [line "27"] [id "210730"] [rev "5"] [msg "COMODO WAF: URL file extension is restricted by policy||customer.domain.com|F|2"] [data ".com"] [severity "CRITICAL"] [tag "CWAF"] [tag "HTTP"] [hostname "customer.domain.com"] [uri "/remote.php/dav/files/[email protected]"] [unique_id "ZcCchXhdkYMpOqMcyyQ3eQAAAI4"]
Action: Intercepted (phase 2)
Apache-Handler: proxy:unix:/var/www/vhosts/system/customer.domain.com/php-fpm.sock|fcgi://127.0.0.1:9000
Stopwatch: 1707121797791133 788374 (- - -)
Stopwatch2: 1707121797791133 788374; combined=1391, p1=556, p2=705, p3=0, p4=0, p5=129, sr=142, sw=1, l=0, gc=0
Producer: ModSecurity for Apache/2.9.7 (http://www.modsecurity.org/); CWAF_Apache.
Server: Apache
Engine-Mode: "ENABLED"

I'm struggling to understand the issue related to the file extension.

Interestingly, when the Application Firewall is disabled, this particular user does not experience any problems. This further complicates our understanding of the issue.


2024-02-07 14_48_56-Web Application Firewall - Plesk Obsidian 18.0.58.png
2024-02-07 14_49_05-Web Application Firewall - Plesk Obsidian 18.0.58.png
 
The request offends rule no. 210730. You can add rule no. 210730 to the lists of exceptions in the "Web Application Firewall" icon of the domain. Store the new configuration, then try again.
 
Wow thank you very much, I added the exception and now I wait for my customer what experience he has after this.
I researched that rule but even with Chatgpt4 I didn't understand it well. But lets not go too deep in the rabbithole :)
 
uri "/remote.php/dav/files/[email protected]

This is the problem. WAF thinks you are trying to access a file with a .com extension.

.com is an old executable extension, but they are still used, on windows 10 in c:\windows\system32 there are still a few .com files. format.com, tree.com, chcp.com, etc...


regards
Jan
 
Back
Top