发送 xmpp<消息>;到其他域的组件

发布于 2024-08-29 10:35:08 字数 1291 浏览 8 评论 0原文

步骤1:在同一个域(.myserver.kicks-ass.net)上,我能够成功发送到mycomponent。

步骤 2:当我登录到其他域时,例如 gmail.com 并尝试发送给 上的另一个用户[电子邮件受保护],也成功了。

步骤3:就像步骤2一样,但是我将其发送到mycomponent.myserver.kicks-ass.net,我收到以下错误

<message xmlns='jabber:client'
         to='mycomponent.myserver.kicks-ass.net'
         from='[email protected]/123'
         type='chat'>
<body>
just t4st
</body>
<x xmlns='jabber:x:event'>
<offline/>
<composing/>
</x>
</message>
<message xmlns='jabber:client'
         to='[email protected]/123'
         from='mycomponent.myserver.kicks-ass.net'
         type='error'>
<body>
just t4st
</body>
<x xmlns='jabber:x:event'>
<offline/>
<composing/>
</x>
<error code='404'
       type='cancel'>
<remote-server-not-found xmlns='urn:ietf:params:xml:ns:xmpp-stanzas'/>
</error>
</message>

step 1:on the same domain(.myserver.kicks-ass.net), i able to send to the mycomponent,succesfully.

step 2:when i login to other domain ,example gmail.com and try send to another user on [email protected], success as well.

step 3:just like step2, but i send the to mycomponent.myserver.kicks-ass.net , i get below error

<message xmlns='jabber:client'
         to='mycomponent.myserver.kicks-ass.net'
         from='[email protected]/123'
         type='chat'>
<body>
just t4st
</body>
<x xmlns='jabber:x:event'>
<offline/>
<composing/>
</x>
</message>
<message xmlns='jabber:client'
         to='[email protected]/123'
         from='mycomponent.myserver.kicks-ass.net'
         type='error'>
<body>
just t4st
</body>
<x xmlns='jabber:x:event'>
<offline/>
<composing/>
</x>
<error code='404'
       type='cancel'>
<remote-server-not-found xmlns='urn:ietf:params:xml:ns:xmpp-stanzas'/>
</error>
</message>

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

燕归巢 2024-09-05 10:35:08

您是否有以下 SRV 记录:

_xmpp-server._tcp.mycomponent.myserver.kicks-ass.net

您可以使用以下 shell 命令对此进行测试:

 % dig +short -t SRV _xmpp-server._tcp.mycomponent.myserver.kicks-ass.net.

您可以从网络外部远程登录到该主机/端口吗?例如:

% dig +short -t SRV _xmpp-server._tcp.jabber.org.
30 30 5269 hermes.jabber.org.
% telnet hermes.jabber.org 5269
Trying 208.68.163.220...
Connected to hermes.jabber.org.
Escape character is '^]'.
<<
<stream:error><bad-format xmlns='urn:ietf:params:xml:ns:xmpp-streams'/></stream:error></stream:stream>
Connection closed by foreign host

Do you have an SRV record for:

_xmpp-server._tcp.mycomponent.myserver.kicks-ass.net

You can test for this with the following shell command:

 % dig +short -t SRV _xmpp-server._tcp.mycomponent.myserver.kicks-ass.net.

Can you telnet to that host/port from outside your network? For example:

% dig +short -t SRV _xmpp-server._tcp.jabber.org.
30 30 5269 hermes.jabber.org.
% telnet hermes.jabber.org 5269
Trying 208.68.163.220...
Connected to hermes.jabber.org.
Escape character is '^]'.
<<
<stream:error><bad-format xmlns='urn:ietf:params:xml:ns:xmpp-streams'/></stream:error></stream:stream>
Connection closed by foreign host
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文