xmpp icon indicating copy to clipboard operation
xmpp copied to clipboard

Starttls error

Open kliver50 opened this issue 6 years ago • 0 comments

Error connect to server.

Starttls send after authentication.

Code ` $options = new Options('tcp://' . $server . ':' . $port); $options->setUsername($user) ->setPassword($pass) ->setTo($domain) // ->setLogger($logger) ->setContextOptions(['ssl'=>['allow_self_signed' => true, 'verify_peer' => false, 'verify_peer_name' => false]]);

$client = new Client($options); $client->connect(); ` packet log (C - client, S - Server) C:

<?xml version="1.0" encoding="UTF-8"?>
<stream:stream to="example.com" xmlns:stream="http://etherx.jabber.org/streams" xmlns="jabber:client" version="1.0">

S: <?xml version='1.0'?><stream:stream id='17121742892586591802' version='1.0' xml:lang='ru' xmlns:stream='http://etherx.jabber.org/streams' from='example.com' xmlns='jabber:client'> S: <stream:features><mechanisms xmlns='urn:ietf:params:xml:ns:xmpp-sasl'><mechanism>PLAIN</mechanism><mechanism>X-OAUTH2</mechanism></mechanisms><starttls xmlns='urn:ietf:params:xml:ns:xmpp-tls'/><register xmlns='http://jabber.org/features/iq-register'/></stream:features> C: <auth xmlns="urn:ietf:params:xml:ns:xmpp-sasl" mechanism="PLAIN">base64 data</auth> S: <success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/> C:

<?xml version="1.0" encoding="UTF-8"?>
<stream:stream to="example.com" xmlns:stream="http://etherx.jabber.org/streams" xmlns="jabber:client" version="1.0">

S: <?xml version='1.0'?><stream:stream id='17737822639213207479' version='1.0' xml:lang='ru' xmlns:stream='http://etherx.jabber.org/streams' from='example.com' xmlns='jabber:client'> S: <stream:features><bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'/><session xmlns='urn:ietf:params:xml:ns:xmpp-session'><optional/></session><c ver='MRePpsP+2TprEejkwaKRZINo4G0=' node='http://www.process-one.net/en/ejabberd/' hash='sha-1' xmlns='http://jabber.org/protocol/caps'/><csi xmlns='urn:xmpp:csi:0'/></stream:features> C: <iq type="set" id="fabiang_xmpp_5dadafdf2ba4a"><bind xmlns="urn:ietf:params:xml:ns:xmpp-bind"><resource>pb</resource></bind></iq> S:

<iq type='result' id='fabiang_xmpp_5dadafdf2ba4a'><bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'><jid>[email protected]/pb</jid></bind></iq>

C: <iq type="set" id="fabiang_xmpp_5dadafdf51726"><session xmlns="urn:ietf:params:xml:ns:xmpp-session"/></iq> S: <iq xml:lang='ru' to='[email protected]/pb' from='[email protected]' type='result' id='fabiang_xmpp_5dadafdf51726'/> C: <starttls xmlns="urn:ietf:params:xml:ns:xmpp-tls"/> S: <failure xmlns='urn:ietf:params:xml:ns:xmpp-tls'/>

kliver50 avatar Oct 21 '19 13:10 kliver50