by Matti Ärmänen.
I had the same problem as the students are not used to passwords starting or ending with special characters. To avoid losing the changes in upgrades, I recommend to put the customized settings to config.php before line:
require_once(dirname(__FILE__) . '/lib/setup.php');