Quantcast
Channel: Ignite Realtime : Discussion List - All Communities
Viewing all articles
Browse latest Browse all 10742

Bookmarks do not escape Strings for XML

$
0
0

Hi,

 

I just saw this in the Openfire logs:

 

org.xmlpull.v1.XmlPullParserException: expected = after attribute name (position: START_TAG seen ... xmlns="storage:bookmarks"><conference name="Ich liebe "Deutsche L... @1:136) 
        at org.xmlpull.mxp1.MXParser.parseAttribute(MXParser.java:2004) 

 

It seems like Smack does not escape XML correctly in Bookmarks.java:

 

for(BookmarkedConferenceconference:getBookmarkedConferences()){            if(conference.isShared()) {                continue;            }            buf.append("<conference ");            buf.append("name=\"").append(conference.getName()).append("\" ");            buf.append("autojoin=\"").append(conference.isAutoJoin()).append("\" ");            buf.append("jid=\"").append(conference.getJid()).append("\" ");            buf.append(">");             if (conference.getNickname() != null) {                buf.append("<nick>").append(conference.getNickname()).append("</nick>");            }              if (conference.getPassword() != null) {                buf.append("<password>").append(conference.getPassword()).append("</password>");            }            buf.append("</conference>");}

Viewing all articles
Browse latest Browse all 10742

Trending Articles