Failure to authenticate if username contains @?

i have an xmpp server running (openfire 3.7.0 beta) and i’m using smack api (3.1.0 beta i believe)

to connect to openfire.

i created an account with username "" through openfire’s web interface.

i’m attempting to log in using the api (but if fails to authenticate):

XMPPConnection connection = // initialize

connection.login("", “password”, “resource”);

however, “” is NOT my xmpp server’s domain. specifically openfire’s system property “xmpp.domain” is “”.

i even tried:

connection.login("", “password”, “resource”);

but that fails to authenticate also. any ideas on how i can authenticate an account whose username already contains "@"s?



found my answer at:

replacing “@” with “\40” allows one to authenticate properly if the username contains an “@”.

I would rather advice to NOT TO USE ‘@’ in a user name instead of going through workaround. After all the user will look like bl@user@some.domain, this does not look correct after all.