InvalidArgumentException: Source path .suspected has to start with a slash.

Created on 24 April 2025, 8 days ago

Problem/Motivation

The following error is being triggered by bot traffic on all our sites using this module:

InvalidArgumentException: Source path .suspected has to start with a slash.

Steps to reproduce

Visit the path /index.php.suspected

Proposed resolution

Catch any InvalidArgumentException thrown by the condition. Mention that this is a workaround, until 🐛 InvalidArgumentException: Source path has to start with a slash - thrown when requesting double slash path Needs work lands in core.

🐛 Bug report
Status

Active

Version

4.0

Component

Code

Created by

🇧🇪Belgium dieterholvoet Brussels

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024