Discuz "Xin" "Heng" User cannot register
The reason is that Discuz has such a piece of code
functionCheck_username ($username) { $guestexp= ' \xa1\xa1|\xac\xa3|^guest|^\xd3\xce\xbf\xcd|\xb9\x43\xab\xc8 '; if(Preg_match("/\s+|^c:\\con\\con| [%,\*\ "\s\<\>\&]|$guestexp/is ",$username)) { return FALSE; } Else { return TRUE; } }
$guestexp = ' \xa1\xa1|\xac\xa3|^guest|^\xd3\xce\xbf\xcd|\xb9\x43\xab\xc8 ';
Will match, with "Hin", "Heng" username, because
Again Utf-8, "hin" code: \XE6\XAC\XA3, "Heng" code: \XE8\XA1\XA1
Bug Modification:
$guestexp = ' \xa1\xa1|\xac\xa3|^guest|^\xd3\xce\xbf\xcd|\xb9\x43\xab\xc8 ';
Switch
$guestexp = ' (? <!\xe8) \xa1\xa1| (? <!\xe6) \xac\xa3|^guest|^\xd3\xce\xbf\xcd|\xb9\x43\xab\xc8 ';
This can be matched with \XA1\XA1|\XAC\XA3 encoded UTF-8 special characters, and will not match "Hin", "Heng".
Discuz "Xin" "Heng" User cannot register bug modification