Issue Bug Closed

#46077BELog module error: "vsprintf(): Too few arguments"

Dmitry Dulepov 03/06/13, 19:55 updated 10/02/18, 12:15

Description

AbstractExceptionHandler contains a function named writeLog. That function adds an entry to the system log. System log expects not just a string but a string format with % characters. Callers of this methods may supply something like this to writeLog:

=========
Core: Exception handler (WEB): Uncaught TYPO3 Exception: #1303237468: Given select field item list was not found. | RuntimeException thrown in file /var/www/typo3/sysext/core/Classes/Utility/ExtensionManagementUtility.php in line 409. Requested URL: http://typo3master.dev/typo3/ajax.php?_dc=1362593068887&ajaxID=BackendLogin%3A%3AisTimedOut&skipSessionUpdate=1
=========

This message contains % symbols but it is not a format. Therefore, it should be escaped. The best way is to do it in the writeLog itself because it does not create any log data to format but only adds a plain string.

Reviews 2