title: ejabberd MucSub not working
body: <p>I'm working on developing an XMPP Client communicating over an ejabberd community server (version 17.09) that we host ourselves.</p>
  
  <p>I'm having trouble to implement the MucSub Feature (supported since version 16.08 as far as I know).</p>
  
  <p>When I'm sending this XML command (described in the ejabberd documentation for subscribing to a chatroom):</p>
  
  <pre><code>&lt;iq from='hag66@shakespeare.example'
  to='coven@muc.shakespeare.example'
  type='set'
  id='E6E10350-76CF-40C6-B91B-1EA08C332FC7'&gt;
    &lt;subscribe xmlns='urn:xmpp:mucsub:0'
               nick='mynick'
               password='roompassword'&gt;
      &lt;event node='urn:xmpp:mucsub:nodes:messages' /&gt;
      &lt;event node='urn:xmpp:mucsub:nodes:affiliations' /&gt;
      &lt;event node='urn:xmpp:mucsub:nodes:subject' /&gt;
      &lt;event node='urn:xmpp:mucsub:nodes:config' /&gt;
    &lt;/subscribe&gt;
  &lt;/iq&gt;
  </code></pre>
  
  <p>(of course entering existing jid's for this server, allow_subscription set to true for this chatroom) I get the result:</p>
  
  <pre><code>&lt;iq xml:lang='de'
  to='hag66@shakespeare.example'
  from='coven@muc.shakespeare.example'
  type='error' id='E6E10350-76CF-40C6-B91B-1EA08C332FC7'&gt;
  &lt;subscribe xmlns='urn:xmpp:mucsub:0' nick='mynick'&gt;
      &lt;event node='urn:xmpp:mucsub:nodes:messages'/&gt;
      &lt;event node='urn:xmpp:mucsub:nodes:affiliations'/&gt;
      &lt;event node='urn:xmpp:mucsub:nodes:subject'/&gt;
      &lt;event node='urn:xmpp:mucsub:nodes:config'/&gt;
    &lt;/subscribe&gt;
  &lt;error code='503' type='cancel'&gt;
  &lt;service-unavailable xmlns='urn:ietf:params:xml:ns:xmpp-stanzas'/&gt;
  &lt;text xml:lang='de' xmlns='urn:ietf:params:xml:ns:xmpp-stanzas'&gt;No module is handling this query&lt;/text&gt;
  &lt;/error&gt;
  &lt;/iq&gt;
  </code></pre>
  
  <p>When I alter the query to:</p>
  
  <pre><code>&lt;iq from='hag66@shakespeare.example'
  to='coven@muc.shakespeare.example'
  type='set'
  id='E6E10350-76CF-40C6-B91B-1EA08C332FC7'&gt;
    &lt;subscribe xmlns='urn:xmpp:mucsub:0'
               nick='mynick'
               password='roompassword'&gt;
      &lt;event xmlns="http://jabber.org/protocol/pubsub#event" node="urn:xmpp:mucsub:nodes:messages" /&gt;
      &lt;event xmlns="http://jabber.org/protocol/pubsub#event" node="urn:xmpp:mucsub:nodes:affiliations' /&gt;
      &lt;event xmlns="http://jabber.org/protocol/pubsub#event" node="urn:xmpp:mucsub:nodes:subject' /&gt;
      &lt;event xmlns="http://jabber.org/protocol/pubsub#event" node="urn:xmpp:mucsub:nodes:config' /&gt;
    &lt;/subscribe&gt;
  &lt;/iq&gt;
  </code></pre>
  
  <p>I get the result:</p>
  
  <pre><code>&lt;iq xmlns="jabber:client" 
  to="hag66@shakespeare.example" 
  xml:lang="en" 
  type="result" 
  from="coven@muc.shakespeare.example" 
  id="agsXMPP_8"&gt;
     &lt;subscribe xmlns="urn:xmpp:mucsub:0" nick="mynick" /&gt;
  &lt;/iq&gt;
  </code></pre>
  
  <p>which I interpret as the query being successfull. Also when I query the Chatrooms this user is subscribed to the chatroom is listed.</p>
  
  <p>My Problem now is: no matter which of this methods I use, the user does not get notifications for messages in that chat if he is not present in exactly this chatroom.</p>
  
  <p>Now the strangest thing is: if I get DiscoInfo from the server the MucSub Feature (urn:xmpp:mucsub:0) is not listed, which I don't understand as the Feature is supported by the server version I'm using and according to the documentation is enabled by default and can't even be disabled.</p>
  
  <p>Has anyone experienced the same issue and/or knows how to resolve it?</p>
  
  <p>Thanks in advance for your help</p>