¿Establecer automáticamente el rol de los usuarios anónimos en Visitante en ejabberd?

I'm working on a project that has group chat capability using XMPP and moc_muc, in which only registered users can send messages (while anonymous users can only read but not write). I'm using ejabberd, with SASL anonymous support (registered users are authenticated using a custom external script).

The only method that I can come up right now is to use 2 different hosts for the 2 types of users, and write a component to set the roles of a user based on his/her host anytime he/she joins a room. This might work, but seems to be a quite complicated method for a seemingly trivial problem. I don't know too much about XMPP and all the specifications/modules/components in the wild, so I might have missed something obvious. I would appreciate any pointer!

Gracias un montón

preguntado el 04 de julio de 12 a las 02:07

You're along the right lines, though this is less of an XMPP question and more of an ejabberd one. An XMPP component can't generally access server internals, which would be required to do as you describe. Thus you need to write an ejabberd-specific plugin or modify its mod_muc code (on the assumption it doesn't support this feature already). -

@MattJ Thanks a lot, I was kinda hoping that an external component written with SleekXmpp could do the job; but maybe it's time to learn Erlang :) -

0 Respuestas

No es la respuesta que estás buscando? Examinar otras preguntas etiquetadas or haz tu propia pregunta.