ejabberd 17.07中的自定义身份验证模块

时间:2017-07-26 16:38:32

标签: erlang xmpp ejabberd ejabberd-auth

在ejabberd 16.02中,我有一个自定义身份验证模块。它被命名为ejabberd_auth_component.beam,并被放入正确的目录中。然后,我在配置中设置auth_method: component。然后ejabberd将使用自定义模块(前提是它实现了正确的功能)。

这在ejabberd 17.07中不再有效。 ejabberd现在忽略auth_method: component作为无效选项类型。有没有办法让自定义身份验证模块在17.07运行?我一直在仔细阅读更新的代码库,但还没有找到添加新的auth方法的方法。

1 个答案:

答案 0 :(得分:0)

  1. 确保您在模块中正确定义了所有(非可选)回调:https://github.com/processone/ejabberd/blob/17.07/src/ejabberd_auth.erl#L70
  2. 确保模块中有def my_action # some code here render "show.json" end 编译器指令。