Chinese Username login

Hi everyone.

I got a little problem and if anyone knows the answer i would be really

greatful.

As the title suggests, i want to login using a chinese character username. I

first added the a test username (??/??) to my openfire server to see if it was

possible. No problems there as the name was successfully added. However when i

tried to login using the name and password i get an exception thrown when i try

the connection.connect method. the stack trace says:

SASL authentication failed:

at

org.jivesoftware.smack.SASLAuthentication.authenticate(SASLAuthentication.java:2 09)

at

org.jivesoftware.smack.XMPPConnection.login(XMPPConnection.java:341)

Do i need to do something special to the name before i pass it to the

connect method? i’ve had a look around and can’t see if there is an obvious

answer.

Any help would be great.

Thanks

Steven

Hi, you can find the JID definition in XMPP procotol:

jid = node “@” domain “/” resource

domain = fqdn / address-literal

fqdn = (sub-domain 1*("." sub-domain))

sub-domain = (internationalized domain label)

address-literal = IPv4address / IPv6address

It seems that JID it’s an Email address, so the Chinese character is not supported.

Hi thankyou for your reply.

Unfortunately i cannot speak (or read) Chinese myself, rather the project i

am working on is aimed at a Chinese user base. I did translate what you said

though and i believe that you are saying that i cannot login with a Chinese

name and my set up of one on Openfire was something that Openfire should not

have let me do.

Is there any kind of workaround to this?

Thanks

Steven

Hi all,

So, is this problem unsolvable? I have tried a number of ways to get around

this but all fail.

Is there any approach that i might have missed out? i am prepared to

implement a dirty hack if that is what it takes.

Any advice would be great.

Thanks again

Steven

Hi again,

on this issue i have found the post:

This would explain why i cannot use a chinese username and/or password. However, the op didnt receive a reply so i am still at a loss as to how to get around the problem. Is there a way to not use the encoding in StringUtils?

Any help would be great.

Thanks

Steven