Mercurial > prosody-hg
comparison plugins/mod_bosh.lua @ 1049:c476bceaf2db
mod_bosh: Put dummy authid in session creation response to keep JSJaC happy
| author | Matthew Wild <mwild1@gmail.com> |
|---|---|
| date | Thu, 23 Apr 2009 03:27:22 +0100 |
| parents | 45fc590539cd |
| children | 9552c08241af bb21eb3cd364 |
comparison
equal
deleted
inserted
replaced
| 1048:45fc590539cd | 1049:c476bceaf2db |
|---|---|
| 178 local features = st.stanza("stream:features"); | 178 local features = st.stanza("stream:features"); |
| 179 fire_event("stream-features", session, features); | 179 fire_event("stream-features", session, features); |
| 180 --xmpp:version='1.0' xmlns:xmpp='urn:xmpp:xbosh' | 180 --xmpp:version='1.0' xmlns:xmpp='urn:xmpp:xbosh' |
| 181 local response = st.stanza("body", { xmlns = xmlns_bosh, | 181 local response = st.stanza("body", { xmlns = xmlns_bosh, |
| 182 inactivity = tostring(BOSH_DEFAULT_INACTIVITY), polling = tostring(BOSH_DEFAULT_POLLING), requests = tostring(BOSH_DEFAULT_REQUESTS), hold = tostring(session.bosh_hold), maxpause = "120", | 182 inactivity = tostring(BOSH_DEFAULT_INACTIVITY), polling = tostring(BOSH_DEFAULT_POLLING), requests = tostring(BOSH_DEFAULT_REQUESTS), hold = tostring(session.bosh_hold), maxpause = "120", |
| 183 sid = sid, ver = '1.6', from = session.host, secure = 'true', ["xmpp:version"] = "1.0", | 183 sid = sid, authid = sid, ver = '1.6', from = session.host, secure = 'true', ["xmpp:version"] = "1.0", |
| 184 ["xmlns:xmpp"] = "urn:xmpp:xbosh", ["xmlns:stream"] = "http://etherx.jabber.org/streams" }):add_child(features); | 184 ["xmlns:xmpp"] = "urn:xmpp:xbosh", ["xmlns:stream"] = "http://etherx.jabber.org/streams" }):add_child(features); |
| 185 request:send{ headers = default_headers, body = tostring(response) }; | 185 request:send{ headers = default_headers, body = tostring(response) }; |
| 186 | 186 |
| 187 request.sid = sid; | 187 request.sid = sid; |
| 188 return; | 188 return; |
