使用 OpenSSL 的 PSK 提示
OpenSSL 中 PSK Hint 的具体作用是什么? 我认为这是客户端的一种服务器标识,但我没有找到任何具体的信息。
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
OpenSSL 中 PSK Hint 的具体作用是什么? 我认为这是客户端的一种服务器标识,但我没有找到任何具体的信息。
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
接受
或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
发布评论
评论(1)
PSK 身份提示未明确定义(请参阅 RFC 4279)。在预共享密钥 (PSK) 方案中,客户端和服务器都必须能够导出同一组加密密钥。身份提示是服务器提供的信息,用于告诉客户端如何导出密钥。
由于每个服务器都可以有自己独特的生成密钥的方式,因此客户端必须了解有关服务器的信息才能知道如何处理 PSK 身份提示。每个实现都以不同的方式使用提示。
例如 NETCONF 在生成时直接使用提示PSK(其中
+
表示连接):而 Symbian 安全用户平面位置 (SUPL)协议使用它来呈现协议版本并提供客户端可以使用的 PSK 生成器列表。
类似的 TLS-PSK EMV 智能卡使用身份提示来确定如何计算 PSK。
正如您所看到的,如果您从服务器获得 PSK 提示,您就必须知道它提供了哪些信息以及如何处理它,否则您将无法生成服务器生成的同一组密钥。
脚注:诺基亚负责 PSK-TLS 草案 RFC 4279 以及 将补丁提交给 OpenSSL 来实现规范。
The PSK identity hint is not well defined (see RFC 4279). In a pre-shared key (PSK) scheme, both the client and the server have to be able to derive the same set of crypto keys. The identity hint is something the server provides to tell the client how to derive the key.
Since each server can have its own unique way of generating the key, the client has to know something about the server to know what to do with the PSK identity hint. And each implementation uses the hint differently.
For example, NETCONF uses the hint directly when generating the PSK (where
+
means concatenate):Whereas the Symbian Secure User Plane Location (SUPL) protocol uses it to present the protocol version and provide a list of PSK generators that the client can use.
Similarly TLS-PSK for EMV smart cards uses the identity hint to determine how to calculate the PSK.
So as you can see, if you get a PSK hint from a server, you already have to know what information it provides and what to do with it or you won't be able to generate the same set of keys that the server generates.
Footnote: Nokia was responsible for the PSK-TLS draft RFC 4279 and also submitted the patch to OpenSSL implementing the spec.