Software /
code /
prosody
Comparison
plugins/muc/mod_muc.lua @ 9240:f9a83aca4421
MUC: Add support for registering with a MUC, including reserving a nickname as per XEP-0045
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Mon, 03 Sep 2018 12:26:25 +0100 |
parent | 9237:b86c2e135797 |
child | 9626:4d3ab7153153 |
comparison
equal
deleted
inserted
replaced
9239:03e37f7d6c97 | 9240:f9a83aca4421 |
---|---|
78 | 78 |
79 local history = module:require "muc/history"; | 79 local history = module:require "muc/history"; |
80 room_mt.send_history = history.send; | 80 room_mt.send_history = history.send; |
81 room_mt.get_historylength = history.get_length; | 81 room_mt.get_historylength = history.get_length; |
82 room_mt.set_historylength = history.set_length; | 82 room_mt.set_historylength = history.set_length; |
83 | |
84 local register = module:require "muc/register"; | |
85 room_mt.get_registered_nick = register.get_registered_nick; | |
86 room_mt.get_registered_jid = register.get_registered_jid; | |
87 room_mt.handle_register_iq = register.handle_register_iq; | |
83 | 88 |
84 local jid_split = require "util.jid".split; | 89 local jid_split = require "util.jid".split; |
85 local jid_bare = require "util.jid".bare; | 90 local jid_bare = require "util.jid".bare; |
86 local st = require "util.stanza"; | 91 local st = require "util.stanza"; |
87 local cache = require "util.cache"; | 92 local cache = require "util.cache"; |
399 ["iq-get/bare/http://jabber.org/protocol/muc#admin:query"] = "handle_admin_query_get_command" ; | 404 ["iq-get/bare/http://jabber.org/protocol/muc#admin:query"] = "handle_admin_query_get_command" ; |
400 ["iq-set/bare/http://jabber.org/protocol/muc#owner:query"] = "handle_owner_query_set_to_room" ; | 405 ["iq-set/bare/http://jabber.org/protocol/muc#owner:query"] = "handle_owner_query_set_to_room" ; |
401 ["iq-get/bare/http://jabber.org/protocol/muc#owner:query"] = "handle_owner_query_get_to_room" ; | 406 ["iq-get/bare/http://jabber.org/protocol/muc#owner:query"] = "handle_owner_query_get_to_room" ; |
402 ["message/bare"] = "handle_message_to_room" ; | 407 ["message/bare"] = "handle_message_to_room" ; |
403 ["presence/bare"] = "handle_presence_to_room" ; | 408 ["presence/bare"] = "handle_presence_to_room" ; |
409 ["iq/bare/jabber:iq:register:query"] = "handle_register_iq"; | |
404 -- Host room | 410 -- Host room |
405 ["iq-get/host/http://jabber.org/protocol/disco#info:query"] = "handle_disco_info_get_query" ; | 411 ["iq-get/host/http://jabber.org/protocol/disco#info:query"] = "handle_disco_info_get_query" ; |
406 ["iq-get/host/http://jabber.org/protocol/disco#items:query"] = "handle_disco_items_get_query" ; | 412 ["iq-get/host/http://jabber.org/protocol/disco#items:query"] = "handle_disco_items_get_query" ; |
407 ["iq-set/host/http://jabber.org/protocol/muc#admin:query"] = "handle_admin_query_set_command" ; | 413 ["iq-set/host/http://jabber.org/protocol/muc#admin:query"] = "handle_admin_query_set_command" ; |
408 ["iq-get/host/http://jabber.org/protocol/muc#admin:query"] = "handle_admin_query_get_command" ; | 414 ["iq-get/host/http://jabber.org/protocol/muc#admin:query"] = "handle_admin_query_get_command" ; |