gpt4 book ai didi

xmpp - 使用ejabberd进行文件传输

转载 作者:行者123 更新时间:2023-12-03 02:09:08 32 4
gpt4 key购买 nike

我有一个使用 ejabberd2 的聊天应用程序。现在,我需要通过聊天消息传输文件。我只是在 ejabberd.cfg 文件中配置 mod_proxy65 并打开端口 7777。但发送文件失败。

myejabberd.cfg 设置

{mod_proxy65,  [
{ip, {118,132,178,95}},
{name, "SOCKS5 Bytestreams"},
{host, "proxy.amadoa.org"}
]},

有人知道如何在 ejabberd2 中启用 mod_proxy65 吗?我需要在这里安装任何额外的模块吗?

非常感谢您的帮助。谢谢

最佳答案

大多数人将主机与 ejabberd 配置中的主机名混淆,主机名是您应该提供公共(public) IP 或 www.domain.com 的位置,其中主机是您为 ejabberd 服务器提供的逻辑名称;默认为 proxy.domain.com,

而且IP地址是Ejabberd监听的接口(interface)的IP,所以应该是本地地址。 Llike:192.168.1.10 监听一个接口(interface),或 0.0.0.0 监听所有接口(interface),或 127.0.0.1 允许本地仅文件传输。

对我有用的配置示例:

{mod_proxy65,  [
{host, "proxy.domain.com"}, %% defines the Jabber ID of service. If not specified, Jabber ID will be hostname of the virtual host with the prefix 'proxy'.

%%{ip, {192,168,1,90}}, %% this line works, or use the below line
{ip, {0,0,0,0}}, %% 127.0.0.1 by default, make it 0.0.0.0 to listen on all interfaces, or the ip of specific interface

{hostname, "www.domain.com"}, % useful service run behind a NAT. default is value of ip option. Ex: "proxy.mydomain.org", "200.150.100.50"
{port, 7777}, %% Default, we don't need to add
{access, all}, %% Default, we don't need to add
{shaper, c2s_shaper}
]},

关于xmpp - 使用ejabberd进行文件传输,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19498037/

32 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com