UTF-8/unicode bug in username/JID

Hi,

I did create a user “b\u20acn” using Spark but I can not login. Using the adminconsole to edit this users causes an exception. A short application using Smack can login, so it seems to be a Spark problem.

\u20ac is the “Euro Sign”, so the user is called “bEn” while the E is not an E but the Euro Sign.

Am I allowed to use this character in a name?

Has someone similar problems with special characters?

LG

Message was edited by (topic + “in username/JID”)

You can check the list of supported characters from the XMPP-node here http://www.xmpp.org/specs/rfc3920.html#nodeprep

Hi Alex,

as far as I understand the specifications every unicode 3.2 character is allowed for the username (XMPP node identifier) except "&’’/:<>@[/b].

The Euro Sign is a UCS-2 or unicode 1.0 character and thus allowed.

Do you agree?

LG

What exception are you receiving in the admin console?

Hi Alex,

I know a nice game, it’‘s called keep the (in this case non-paying) customer busy. We should play it together, shouldn’'t we?

My question was a complete different one, I’'m not interested in the admin console or the exception. The admin console uses UTF-8 encoding for the URL (/user-properties.jsp?username=b%E2%82%ACn) for “bEn” while the value is stored as unicode in the database ( http://www.jivesoftware.org/community/thread.jspa?threadID=18000 ).

u20ac is the unicode representation for the ? “Euro Sign”. I wonder why unicode instead of UTF-8 (“0xE2 0x82 0xAC”) is used to store the user name (Unicode/UTF-8 reference: http://de.wikipedia.org/wiki/UTF-8#Beispiele ).

I’'m not happy to post the exception here as this is the Spark forum.

LG

The requested user (null) was not found.

Exception:

org.jivesoftware.wildfire.user.UserNotFoundException

at org.jivesoftware.wildfire.user.DefaultUserProvider.loadUser(DefaultUserProvider .java:79)

at org.jivesoftware.wildfire.user.UserManager.getUser(UserManager.java:157)

at org.jivesoftware.wildfire.admin.user_002dproperties_jsp._jspService(user_002dpr operties_jsp.java:99)

at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFil terChain.java:252)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain .java:173)

at com.opensymphony.module.sitemesh.filter.PageFilter.parsePage(PageFilter.java:11 8)

at com.opensymphony.module.sitemesh.filter.PageFilter.doFilter(PageFilter.java:52)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFil terChain.java:202)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain .java:173)

at org.jivesoftware.util.LocaleFilter.doFilter(LocaleFilter.java:43)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFil terChain.java:202)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain .java:173)

at org.jivesoftware.util.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingF ilter.java:41)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFil terChain.java:202)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain .java:173)

at org.jivesoftware.admin.AuthCheckFilter.doFilter(AuthCheckFilter.java:98)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFil terChain.java:202)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain .java:173)

at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java: 213)

at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java: 178)

at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)

at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)

at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:10 7)

at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)

at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:868)

at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConn ection(Http11BaseProtocol.java:663)

at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:5 27)

at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorke rThread.java:80)

at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:6 84)

at java.lang.Thread.run(Unknown Source)

org.jivesoftware.wildfire.user.UserNotFoundException

at org.jivesoftware.wildfire.user.DefaultUserProvider.loadUser(DefaultUserProvider .java:68)

at org.jivesoftware.wildfire.user.UserManager.getUser(UserManager.java:157)

at org.jivesoftware.wildfire.admin.user_002dproperties_jsp._jspService(user_002dpr operties_jsp.java:99)

at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFil terChain.java:252)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain .java:173)

at com.opensymphony.module.sitemesh.filter.PageFilter.parsePage(PageFilter.java:11 8)

at com.opensymphony.module.sitemesh.filter.PageFilter.doFilter(PageFilter.java:52)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFil terChain.java:202)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain .java:173)

at org.jivesoftware.util.LocaleFilter.doFilter(LocaleFilter.java:43)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFil terChain.java:202)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain .java:173)

at org.jivesoftware.util.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingF ilter.java:41)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFil terChain.java:202)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain .java:173)

at org.jivesoftware.admin.AuthCheckFilter.doFilter(AuthCheckFilter.java:98)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFil terChain.java:202)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain .java:173)

at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java: 213)

at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java: 178)

at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)

at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)

at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:10 7)

at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)

at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:868)

at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConn ection(Http11BaseProtocol.java:663)

at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:5 27)

at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorke rThread.java:80)

at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:6 84)

at java.lang.Thread.run(Unknown Source)

Hi Alex,

it could be that this bug is related only to the embedded DB.

I did create a user b’‘Euro’‘n on your server without problems. There is then another problem, in the title window I see ‘‘b?n’’ while unter the menu it’'s written '‘B’‘Euro’'n.

LG

May a developer look at this? It shouldn’'t be too hard to reproduce this issue and create a JM- or SPARK- issue.

still no SPARK-issue, still the same problem with Spark 1.1.2.5

still no SPARK-issue, still the same problem with Spark 1.1.3

Maybe I should also upload a picture, logged in @js.com?

http://img471.imageshack.us/img471/6039/clipboard98ff.png

Spark 1.1.4: still the same problem, but a new discovery: If I modify the roster name “Derek” to “D€rek” and open then the chat window then also in the title window “D€rek” will be displayed. So it’'s not a problem of the font.

http://img133.imageshack.us/img133/1604/clipboard19rw.png

.

moving the content of this post to

http://www.jivesoftware.org/community/thread.jspa?messageID=119027&#119027

as it is related to Wifi.

The Spark problem is still there.

Message was edited by: it2000

Tracking the window title display problem within Spark here: SPARK-286

You go, LG! It’'s nice they gave you JIRA account finally

It also happens when you right click the user the select View Profile, if the profile has unicode characters, Spark will not show any field. I see this happening while pulling vcards from OpenLDAP (which is unicode).