skates 0.2.13 → 0.2.14
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/skates/client_connection.rb +4 -4
- metadata +2 -2
@@ -121,15 +121,15 @@ module Skates
|
|
121
121
|
|
122
122
|
when :wait_for_auth_mechanisms
|
123
123
|
if stanza.name == "stream:features"
|
124
|
-
if stanza.
|
124
|
+
if stanza.children.first.name == "starttls"
|
125
125
|
doc = Nokogiri::XML::Document.new
|
126
126
|
starttls = Nokogiri::XML::Node.new("starttls", doc)
|
127
127
|
doc.add_child(starttls)
|
128
128
|
starttls["xmlns"] = "urn:ietf:params:xml:ns:xmpp-tls"
|
129
129
|
send_xml(starttls.to_s)
|
130
130
|
@state = :wait_for_proceed
|
131
|
-
elsif stanza.
|
132
|
-
if stanza.
|
131
|
+
elsif stanza.children.first.name == "mechanisms"
|
132
|
+
if stanza.children.first.children.map() { |m| m.text }.include? "PLAIN"
|
133
133
|
doc = Nokogiri::XML::Document.new
|
134
134
|
auth = Nokogiri::XML::Node.new("auth", doc)
|
135
135
|
doc.add_child(auth)
|
@@ -158,7 +158,7 @@ module Skates
|
|
158
158
|
|
159
159
|
when :wait_for_bind
|
160
160
|
if stanza.name == "stream:features"
|
161
|
-
if stanza.
|
161
|
+
if stanza.children.first.name == "bind"
|
162
162
|
doc = Nokogiri::XML::Document.new
|
163
163
|
# Let's build the binding_iq
|
164
164
|
@binding_iq_id = Integer(rand(10000000))
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: skates
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.14
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- julien Genestoux
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2010-02-
|
12
|
+
date: 2010-02-14 00:00:00 +01:00
|
13
13
|
default_executable: skates
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|