Not logged in. · Lost password · Register
Forum: MatriX RSS
Avatar
martinbach #1
Member since Mar 2009 · 60 posts
Group memberships: Members, Premium
Show profile · Link to this post
Subject: Unexspected disconnect on jabber.org
Hi Alex,

my app disconnects unexspected short after a successful login on jabber.org.

I tried other ejabbered based server (eg. jwchat.org  or 12jabber.com) and my local ejabberd server.
Then I tried tigase based and openfire based servers and my local servers.
All of them behave ok. But with jabber.org I get:

<stream:error xmlns:stream="http://etherx.jabber.org/streams">
  <not-authorized xmlns="urn:ietf:params:xml:ns:xmpp-streams" />
</stream:error>


I tied psi and spark against jabber.org to test my accounts, they work,
then I tried the Matrix 1.3.0.2 still the stream error.

Do you have an idea for that bahavior ? Thanks for your help.

Here is some logging:

<?xml version="1.0"?>
<LoggingData xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <Username>maltin</Username>
  <Date>2010-08-12T15:23:14.875+02:00</Date>
  <Loggingtext>Open was successful

OnSendXml: ----------------------

&lt;stream:stream xmlns:stream="http://etherx.jabber.org/streams" xmlns="jabber:client" to="jabber.org" version="1.0" &gt;

END OnSendXML ---------------------------------------------

OnReceiveXml: ------------------

&lt;stream:stream xmlns:stream="http://etherx.jabber.org/streams" xmlns="jabber:client" from="jabber.org" id="bcc3d8e67b6ec563" version="1.0" &gt;

END OnReceiveXML ---------------------------------------------

OnReceiveXml: ------------------

&lt;stream:features xmlns:stream="http://etherx.jabber.org/streams"&gt;
  &lt;starttls xmlns="urn:ietf:params:xml:ns:xmpp-tls" /&gt;
  &lt;mechanisms xmlns="urn:ietf:params:xml:ns:xmpp-sasl"&gt;
    &lt;mechanism&gt;CRAM-MD5&lt;/mechanism&gt;
    &lt;mechanism&gt;LOGIN&lt;/mechanism&gt;
    &lt;mechanism&gt;PLAIN&lt;/mechanism&gt;
    &lt;mechanism&gt;DIGEST-MD5&lt;/mechanism&gt;
    &lt;mechanism&gt;SCRAM-SHA-1&lt;/mechanism&gt;
  &lt;/mechanisms&gt;
  &lt;compression xmlns="http://jabber.org/features/compress"&gt;
    &lt;method&gt;zlib&lt;/method&gt;
  &lt;/compression&gt;
  &lt;ver xmlns="urn:xmpp:features:rosterver"&gt;
    &lt;optional /&gt;
  &lt;/ver&gt;
&lt;/stream:features&gt;

END OnReceiveXML ---------------------------------------------

OnSendXml: ----------------------

&lt;auth mechanism="DIGEST-MD5" xmlns="urn:ietf:params:xml:ns:xmpp-sasl" /&gt;

END OnSendXML ---------------------------------------------

OnReceiveXml: ------------------

&lt;challenge xmlns="urn:ietf:params:xml:ns:xmpp-sasl"&gt;bm9uY2U9Ik5zclJjak94Yml1VGgyUStVQ2h6c3pWWmxaMUpVaThvN0IxSmI1dXIzNGM9IixyZWFsbT0iamFiYmVyLm9yZyIscW9wPSJhdXRoIixtYXhidWY9MTYzODQsY2hhcnNldD11dGYtOCxhbGdvcml0aG09bWQ1LXNlc3M=&lt;/challenge&gt;

END OnReceiveXML ---------------------------------------------

OnSendXml: ----------------------

&lt;response xmlns="urn:ietf:params:xml:ns:xmpp-sasl"&gt;dXNlcm5hbWU9Im1hbHRpbiIscmVhbG09ImphYmJlci5vcmciLG5vbmNlPSJOc3JSY2pPeGJpdVRoMlErVUNoenN6VlpsWjFKVWk4bzdCMUpiNXVyMzRjPSIsY25vbmNlPSI5NWQwODUyOGZjOWI4N2ZkY2ZhZDk5NGMzMjkzMWE3OTYxMDNlMGYzNDUzMjk1NDZhMTQ5NTZkMTc1YzRmMDJjIixuYz0wMDAwMDAwMSxxb3A9YXV0aCxkaWdlc3QtdXJpPSJ4bXBwL2phYmJlci5vcmciLGNoYXJzZXQ9dXRmLTgscmVzcG9uc2U9MTRkOWJlZjQ5YzhmMjRkMTU1YzFkNGE4NWZhYmM3ZmE=&lt;/response&gt;

END OnSendXML ---------------------------------------------

OnReceiveXml: ------------------

&lt;success xmlns="urn:ietf:params:xml:ns:xmpp-sasl"&gt;cnNwYXV0aD0yZmQ2NjI1N2MxOWVjOTdlZWRhYTg2YzZhNmU2ZDViNw==&lt;/success&gt;

END OnReceiveXML ---------------------------------------------

OnLogin: Login is now

OnSendXml: ----------------------

&lt;presence xmlns="jabber:client"&gt;
  &lt;status&gt;chatty&lt;/status&gt;
  &lt;priority&gt;5&lt;/priority&gt;
&lt;/presence&gt;

END OnSendXML ---------------------------------------------

OnSendXml: ----------------------

&lt;presence xmlns="jabber:client"&gt;
  &lt;show&gt;chat&lt;/show&gt;
  &lt;status&gt;chatty&lt;/status&gt;
  &lt;priority&gt;5&lt;/priority&gt;
&lt;/presence&gt;

END OnSendXML ---------------------------------------------

OnSendXml: ----------------------

&lt;stream:stream xmlns:stream="http://etherx.jabber.org/streams" xmlns="jabber:client" to="jabber.org" version="1.0" &gt;

END OnSendXML ---------------------------------------------

OnReceiveXml: ------------------

&lt;stream:stream xmlns:stream="http://etherx.jabber.org/streams" xmlns="jabber:client" from="jabber.org" id="2da91f05543c57c9" version="1.0" &gt;

END OnReceiveXML ---------------------------------------------

OnReceiveXml: ------------------

&lt;stream:features xmlns:stream="http://etherx.jabber.org/streams"&gt;
  &lt;bind xmlns="urn:ietf:params:xml:ns:xmpp-bind"&gt;
    &lt;required /&gt;
  &lt;/bind&gt;
  &lt;session xmlns="urn:ietf:params:xml:ns:xmpp-session" /&gt;
  &lt;compression xmlns="http://jabber.org/features/compress"&gt;
    &lt;method&gt;zlib&lt;/method&gt;
  &lt;/compression&gt;
  &lt;ver xmlns="urn:xmpp:features:rosterver"&gt;
    &lt;optional /&gt;
  &lt;/ver&gt;
&lt;/stream:features&gt;

END OnReceiveXML ---------------------------------------------

OnSendXml: ----------------------

&lt;iq id="MX_1" type="set" xmlns="jabber:client"&gt;
  &lt;bind xmlns="urn:ietf:params:xml:ns:xmpp-bind"&gt;
    &lt;resource&gt;easychat&lt;/resource&gt;
  &lt;/bind&gt;
&lt;/iq&gt;

END OnSendXML ---------------------------------------------

OnReceiveXml: ------------------

&lt;stream:error xmlns:stream="http://etherx.jabber.org/streams"&gt;
  &lt;not-authorized xmlns="urn:ietf:params:xml:ns:xmpp-streams" /&gt;
&lt;/stream:error&gt;

END OnReceiveXML ---------------------------------------------

!! OnStreamError:

OnSendXml: ----------------------

&lt;/stream:stream&gt;

END OnSendXML ---------------------------------------------

OnReceiveXml: ------------------

&lt;/stream:stream&gt;

END OnReceiveXML ---------------------------------------------

!! OnError: System.IO.IOException: In die Übertragungsverbindung können keine Daten geschrieben werden: Auf das verworfene Objekt kann nicht zugegriffen werden.
Objektname: "System.Net.Sockets.Socket".. ---&gt; System.ObjectDisposedException: Auf das verworfene Objekt kann nicht zugegriffen werden.
Objektname: "System.Net.Sockets.Socket".
   bei System.Net.Sockets.Socket.EndSend(IAsyncResult asyncResult, SocketError&amp; errorCode)
   bei System.Net.Sockets.Socket.EndSend(IAsyncResult asyncResult)
   bei System.Net.Sockets.NetworkStream.EndWrite(IAsyncResult asyncResult)
   --- Ende der internen Ausnahmestapelüberwachung ---
   bei System.Net.Sockets.NetworkStream.EndWrite(IAsyncResult asyncResult)
   bei Matrix.Net.ClientSocket.#=qzVh4ZctyLdVfz1I7zo$lig==(IAsyncResult #=qSPpSJh_NOgCXCpvyRupZdw==) !!

OnClose: Matrix.EventArgs</Loggingtext>
</LoggingData>
Avatar
Alex #2
Member since Feb 2003 · 4297 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
can you please post a better Xml log. It looks like the packets are not in correct order.
1.3.0.2 should login with SCRAM-SHA-1 which is also not the case in your log.

jabber.org runs M-Link. The M-Link servers sends XMPP pings, when you don't respond to thenm you get disconnected which is fine, because according to the XMPP RFCs you have to respond to every Iq. 1.3.0.3 automatically replies to the pings when AutoReplyToPing is true.

btw, Just uploaded 1.3.0.3

Alex
Avatar
martinbach #3
Member since Mar 2009 · 60 posts
Group memberships: Members, Premium
Show profile · Link to this post
Hi Alex,

I compiled my app with matrix 1.3.0.3 and xmppClient.AutoReplyToPing = true.

But still the disconnect.

Here is the log:


<stream:stream xmlns:stream="http://etherx.jabber.org/streams" xmlns="jabber:client" to="jabber.org" version="1.0" >

<stream:stream xmlns:stream="http://etherx.jabber.org/streams" xmlns="jabber:client" from="jabber.org" id="cc351dd1e00c1625" version="1.0" >

<stream:features xmlns:stream="http://etherx.jabber.org/streams">
  <starttls xmlns="urn:ietf:params:xml:ns:xmpp-tls" />
  <mechanisms xmlns="urn:ietf:params:xml:ns:xmpp-sasl">
    <mechanism>CRAM-MD5</mechanism>
    <mechanism>LOGIN</mechanism>
    <mechanism>PLAIN</mechanism>
    <mechanism>DIGEST-MD5</mechanism>
    <mechanism>SCRAM-SHA-1</mechanism>
  </mechanisms>
  <compression xmlns="http://jabber.org/features/compress">
    <method>zlib</method>
  </compression>
  <ver xmlns="urn:xmpp:features:rosterver">
    <optional />
  </ver>
</stream:features>

<auth mechanism="SCRAM-SHA-1" xmlns="urn:ietf:params:xml:ns:xmpp-sasl">biwsbj1tYWx0aW4scj1tdzRzbG03bkVzbEtSSFV3S0ZPTHA3VWdlV0ZNUmZxRw==</auth>

<challenge xmlns="urn:ietf:params:xml:ns:xmpp-sasl">cj1tdzRzbG03bkVzbEtSSFV3S0ZPTHA3VWdlV0ZNUmZxRzZWZEgvb1NVYkN4MUdFN2NyWWdlUEMvRzl6WGRnQ0RrLHM9T0IrcUtiNEdJdUNqY1ZLdkNuVXhtZz09LGk9NDA5Ng==</challenge>

<response xmlns="urn:ietf:params:xml:ns:xmpp-sasl">Yz1iaXdzLHI9bXc0c2xtN25Fc2xLUkhVd0tGT0xwN1VnZVdGTVJmcUc2VmRIL29TVWJDeDFHRTdjcllnZVBDL0c5elhkZ0NEayxwPUx2OVNESHhkNVFYMTZnOEVGSk9WclJUYjcwWT0=</response>

<success xmlns="urn:ietf:params:xml:ns:xmpp-sasl">dj1sSU40SGlUT0dNZWFWenR0QnZXcCthQ09tUms9</success>

<presence xmlns="jabber:client">
  <status>chatty</status>
  <priority>5</priority>
</presence>

<presence xmlns="jabber:client">
  <show>chat</show>
  <status>chatty</status>
  <priority>5</priority>
</presence>

<stream:stream xmlns:stream="http://etherx.jabber.org/streams" xmlns="jabber:client" to="jabber.org" version="1.0" >

<stream:stream xmlns:stream="http://etherx.jabber.org/streams" xmlns="jabber:client" from="jabber.org" id="84d2aed111720830" version="1.0" >

<stream:features xmlns:stream="http://etherx.jabber.org/streams">
  <bind xmlns="urn:ietf:params:xml:ns:xmpp-bind">
    <required />
  </bind>
  <session xmlns="urn:ietf:params:xml:ns:xmpp-session" />
  <compression xmlns="http://jabber.org/features/compress">
    <method>zlib</method>
  </compression>
  <ver xmlns="urn:xmpp:features:rosterver">
    <optional />
  </ver>
</stream:features>

<iq id="MX_1" type="set" xmlns="jabber:client">
  <bind xmlns="urn:ietf:params:xml:ns:xmpp-bind">
    <resource>easychat</resource>
  </bind>
</iq>

<stream:error xmlns:stream="http://etherx.jabber.org/streams">
  <not-authorized xmlns="urn:ietf:params:xml:ns:xmpp-streams" />
</stream:error>

</stream:stream>

</stream:stream>
Avatar
Alex #4
Member since Feb 2003 · 4297 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
you are sending presence before the resource bind is finished. Can you try to send your presence later? After the OnBind event?

Alex
Avatar
martinbach #5
Member since Mar 2009 · 60 posts
Group memberships: Members, Premium
Show profile · Link to this post
Hi Alex,

great it works now with sending presence after onbind and the matrix 1.3.0.3.

The jabber.org seems to be much more special than other im server.
(It was the only who had problems with my coding)

jabber.org runs M-Link.

By the way: what is M-Link ?
I thought jabber.org runs ejabberd.


Thank you

Martin
Avatar
Alex #6
Member since Feb 2003 · 4297 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
Quote by martinbach:
The jabber.org seems to be much more special than other im server.
(It was the only who had problems with my coding)
the server was right, and other servers should not allow you to send presence before bind as well. Some other servers are more fault tolerant.

Quote by martinbach:
By the way: what is M-Link ?
XMPP server from Isode
http://www.isode.com/products/m-link.html

Quote by martinbach:
I thought jabber.org runs ejabberd.
Its running M-Link for a while now. See this post an the following posts.
http://www.jabber.org/2009/08/xmpp-server-migration/
Avatar
joinvert #7
Member since Feb 2011 · 2 posts
Group memberships: Members
Show profile · Link to this post
1) use TSL not SSL, TSL is the successor from SSL (if you think you really need it)
2) jabber.org and jabber.ccc.de errrmmm oooohhh, let me say it carefully,
be not surprised if something not work (or the server is out of service in general)
Friends dating| Free online chat
Close Smaller – Larger + Reply to this post:
Verification code: VeriCode Please enter the word from the image into the text field below. (Type the letters only, lower case is okay.)
Smileys: :-) ;-) :-D :-p :blush: :cool: :rolleyes: :huh: :-/ <_< :-( :'( :#: :scared: 8-( :nuts: :-O
Special characters:
Forum: MatriX RSS