Connection disconnects with error “internal error” code=1 ErrorDomain=libxmlErrorDomain after XMPPframework sends auth to the server

依然范特西╮ 提交于 2019-12-12 00:50:52

问题


I am using XMPPFramework to connect to my xmpp server on local network ,it connects but as soon as it sends the auth packet and recieves challenge it disconnects with error : "internal error" code=1 ErrorDomain=libxmlErrorDomain. Basically it is not able to parse the challenge :

2013-03-08 15:56:41.890 iPhoneXMPP[23710:13703] Data to be parsed <challenge xmlns="urn:ietf:params:xml:ns:xmpp-sasl">cmVhbG09ImluZm9zeXMuY29tIixub25jZT0ib05JYmxSU2hLQXUxWnorRUNGbmRJby83Snljdm5DLzNKQWV2SXB5UCIsY2hhcnNldD11dGYtOCxhbGdvcml0aG09bWQ1LXNlc3M=</challenge>
2013-03-08 15:56:41.891 iPhoneXMPP[23710:13703] Parser failed

How can i solve this issue,is it something related to how i have configured my xcode to work with libxml2 ?


回答1:


There was a extra charcter at the end of each packet,due to which the SAX parser libxml2 was failing.trimming each packet by one character solved the problem.



来源:https://stackoverflow.com/questions/15355228/connection-disconnects-with-error-internal-error-code-1-errordomain-libxmlerro

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!