Thanks for Alan's reply, but it do not work. I did this "use unlang to make SQL-User-Name have the username without the "Windows Phone\" part" like the following :
if ("%{request:User-Name}" =~ /^(.*)\\(.*)/) {
update request {
User-Name := "%{2}"
Realm := "%{1}"
}
}
in the authorize section and this had no effect. Thus I think the problem doesn't exist in the mismatch of username between FR and Mysql, maybe the FR's processing for realm like "Windows Phone\" has something wrong.