2012-09-12 20 views
1

我試圖在ejabberd上啓動BOSH。我ejabberd.cfg片斷如下:在ejabberd上執行BOSH

{5280, ejabberd_http, [ 
        {request_handlers, [ 
      {["xmpp-httpbind"], mod_http_bind} 
     ]}, 
     captcha, 
     http_bind, 
     http_poll, 
     web_admin 
      ]} 

http://localhost:5280/http-bind fails to open any page. 

而我的客戶正在從服務器此響應

發送XML:

<iq to='localhost' id='uid:50502b03:00004823' type='get' x 
mlns='jabber:client'><query xmlns='jabber:iq:auth'><username>anurag</username></ 
query></iq> 

收到的XML:

<iq xmlns='jabber:client' from='localhost' id='uid:505 
029df:00004823' type='error'><error code='503' type='cancel'><service-unavailabl 
e xmlns='urn:ietf:params:xml:ns:xmpp-stanzas'/></error></iq> 


Sent XML: </stream:stream> 
auth failed. reason: 0 
ce: 18 

我使用gloox圖書館來創建一個客戶端。

回答

1

您是否已將{mod_http_bind,[]}添加到您的模塊部分?

+0

是的我添加了這個模塊。我的錯誤是使用本地主機作爲主機名。更正主機名後,它開始工作。謝謝@ Ed209。 – Anurag