Problem/Motivation
Frequently I find urls like: example.com/user/password?name%5B%23post_render%5D%5B0%5D=array_map&name%5B%23suffix%5D=eval%28%24_POST%5Bc%5D%29%3B%2F%2F&name%5B%23type%5D=markup&name%5B%23markup%5D=assert
result in the logging: Warning: mb_strlen() expects parameter 1 to be string, array given in Drupal\Core\Form\FormValidator->performRequiredValidation() (line 333 of /xxx/core/lib/Drupal/Core/Form/FormValidator.php)
I presume the code should give an error message to the user and prevent a warning in the logging.
I Drupal 7 these is warnings exists as well, but are not so important.