STOMP 协议 - 连接框架是否强制登录/密码?

发布于 2024-07-13 20:29:08 字数 394 浏览 5 评论 0原文

我一直在以各种形式使用 STOMP 协议。 我在 STOMP 的 PHP、Python 和 Objective-C 库中经历过这种现象。 STOMP 网站上的 STOMP 规范在这一点上没有具体说明。

基本上,所有三个库中的 CONNECT 函数(虽然 Python 库现在已经修复了这个问题,但它被认为是一个错误。即使没有指定,该函数仍然发送登录和密码参数。因此......

CONNECT
login:
passcode:

规范尚不清楚,我想知道是否有人对此有更好的想法,我知道一些参与 STOMP 和 ActiveMQ 的人浏览这些论坛。

I have been using the STOMP protocol in various guises. I have experienced this phenomenon in the PHP, Python and Objective-C libraries for STOMP. The STOMP specification on the STOMP website is not specific on this point.

Basically, the CONNECT function in all three libraries (although the Python one has now fixed this, it was acknowledged as a bug. The function still sends a login and passcode parameter, even if none are specified. As so..

CONNECT
login:
passcode:

The specification is unclear, and I am wondering if anyone has any better idea about this. I am aware some people involved with STOMP and ActiveMQ browse these forums.

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

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

发布评论

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

评论(2

伴我心暖 2024-07-20 20:29:08

ActiveMQ 不需要发送这些标头。 例如,看看这个 telnet 会话,

$ telnet localhost 61613
Trying ::1...
Connected to localhost.
Escape character is '^]'.
CONNECT

^@
CONNECTED
session:ID:nc-example.com-51165-1234432649359-2:0

它成功连接到代理,没有任何标头。

干杯

ActiveMQ does not require these headers to be sent. Take a look at this telnet session for example

$ telnet localhost 61613
Trying ::1...
Connected to localhost.
Escape character is '^]'.
CONNECT

^@
CONNECTED
session:ID:nc-example.com-51165-1234432649359-2:0

It connects successfully to the broker without any headers.

Cheers

柒夜笙歌凉 2024-07-20 20:29:08

无论如何,STOMP 1.1 规范澄清了这种歧义:

STOMP 1.1 客户端可以设置以下标头:

  • 登录:用于针对安全 STOMP 服务器进行身份验证的用户 ID。

  • 密码:用于对安全 STOMP 服务器进行身份验证的密码。

For what it's worth, the STOMP 1.1 specification clarified this ambiguity stating:

STOMP 1.1 clients MAY set the following headers:

  • login : The user id used to authenticate against a secured STOMP server.

  • passcode : The password used to authenticate against a secured STOMP server.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文