Issue Bug Rejected

#95941Prevent crashes in reference index update due to invalid user input

Alexander Stehlik 11/10/21, 11:15 updated 06/12/23, 18:15

Description

Currently an editor can cause crashes in the referenceindex:update command by entering invalid data in link fields (e.g. the header_link).

The first scenario is the safeguard in the TypolinkSoftReferenceParser against phar:// URLs. When the user enters such an URL the Backend crashes with an Exception and the update command will always fail until the invalid URL is removed.

The same happens with a combination of a slash / in the link value and a special char that is denied by the filename sanitation. Then the softref parser crashes with an InvalidPathException. Example: bla/blubb<specialchar>test (replace specialchar with this).

IMO editor input should not cause these kinds of Exceptions. Instead the errors should be catched / logged and additionally the validation of link input could be improved to deny disallowed URLs from the start.

Reviews 1