ESOTALK_VERSION = 1.0.0g5esoTalk validates usernames only by length and reserved words. It does not reject newline characters. Administrators can rename members, including themselves. At the same time, ET::writeConfig() writes the current logged-in user’s username directly into a single-line PHP comment at the end of config/config.php:
$contents .= "\n// Last updated by: ".ET::$session->user["username"]." (".ET::$session->ip.") @ ".date("r")."\n?>";
If the current administrator username contains a newline, the content after the newline escapes the // comment context and becomes executable PHP code. Any later configuration save writes this code into config/config.php. Because config/config.php is included during application bootstrap, the injected PHP code executes on subsequent requests.
Username validation does not reject control characters:
public function validateUsername($username, $checkForDuplicate = true)
{
if (in_array(strtolower($username), self::$reservedNames)) return "nameTaken";
$length = mb_strlen($username, "UTF-8");
if ($length < 3 or $length > 20) return "invalidUsername";
...
}
Relevant locations:
core/models/ETMemberModel.class.php:246core/models/ETMemberModel.class.php:252core/models/ETMemberModel.class.php:253The administrator rename endpoint allows administrators to update usernames: