【问题标题】:Solace Client Authentication gives untrusted certificate error (Response Code: 401)Solace 客户端身份验证给出不受信任的证书错误(响应代码:401)
【发布时间】:2021-09-22 19:32:26
【问题描述】:

Solace 客户端证书身份验证方案出现不受信任的证书错误(响应代码:401)。

以下是有关配置的详细信息:
- 创建 pem 格式的自签名服务器和客户端证书(使用私钥)
- 将两者都上传到 solace VMR 上的 Certs 文件夹
- 配置服务器证书用作 Solace VMR 上的服务器证书
- 将客户端证书添加到可信根(配置/身份验证)可信根
- 从会话对象上的属性下面的客户端设置(在其他必需属性之上): objSessionProperties.SSLClientCertificateFile
objSessionProperties.SSLClientPrivateKeyFile
objSessionProperties.SSLClientPrivateKeyFilePassword

通过上述操作,我可以成功调用 Create Session,而在连接到会话时会导致异常。以下是从 Solace 收到的错误信息:
{(Subcode=LoginFailure, Error string=Untrusted Certificate, Response code= 401)}

提前感谢您的帮助。

谢谢。

【问题讨论】:

    标签: ssl client-certificates solace


    【解决方案1】:

    “不受信任的证书”登录失败错误表示设备拒绝了客户端,因为它不信任“SSLClientCertificateFile”中提供的客户端证书。您应该验证签署您的客户端证书的 CA 的证书颁发机构 (CA) 证书在设备上配置为受信任的根证书。

    【讨论】:

    • 我在使用自签名证书时遇到了这个问题。我已将 CN 名称添加到 SSLTrustedCommonNameList 属性,并将客户端证书添加到 Solace VMR 上的受信任根文件中。这里还需要其他配置吗?
    【解决方案2】:

    我的 Java 客户端解决方案是根据需要为属性 SSL 密钥存储格式创建 .p12 文件(请参阅此page)。要获取 p12 文件,您可以使用 this
    下一步是设置我的属性:
    keystore-location=/{path}/keyStore.p12,其中 path - 来自根
    keystore-password-location=configuration/fileWithPasswordForP12File.properties 提供密码以解码 keyStore.p12 文件中的数据

    此属性生效后,您会收到 403 错误:403 Client Certificate Authentication is Shutdown
    要解决此问题,您需要通过以下方式为 Solace 的每个 VNP 配置服务器证书(请参阅 doc):
    solace(configure)# message-vpn <vpn-name>
    solace(configure/message-vpn)# authentication
    solace(configure/message-vpn/authentication)# oauth
    solace(...gure/message-vpn/authentication/oauth)# no shutdown

    您可以从 Solace UI 验证当前用户的证书内容:
    System->UserMgmt->User Authentication->{select user from Client Certificate Authority Name}->Edit->Change Certificate
    此内容必须匹配 keyStore.p12 中的解码数据和从文件夹 /usr/sw/jail/certs

    上传到 solace 服务器上的证书

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2021-01-16
      • 2011-02-26
      • 1970-01-01
      • 1970-01-01
      • 2011-04-09
      • 2013-10-07
      • 1970-01-01
      • 2022-06-23
      相关资源
      最近更新 更多