Typhoeus ETHON 在 RestClient::Request.execute 成功时报告 ssl_certproblem

问题描述

我正在尝试将使用 RestClient::Request.execute 发出的 REST 调用替换为使用 Faraday 和 Typhoeus 的并行调用,但 ETHON 报告 return_code=ssl_certproblem

当前代码

RestClient::Request.execute(
    ...
    ssl_client_key: OpenSSL::PKey::RSA.new(private_key),ssl_client_cert: OpenSSL::X509::Certificate.new(identity_certificate),ssl_ca_path: ca_certificate_file_path
)

代码

ssl_options = Hash.new
ssl_options[:client_key] = OpenSSL::PKey::RSA.new(private_key)
ssl_options[:client_cert] = OpenSSL::X509::Certificate.new(identity_certificate)
ssl_options[:ca_path] = ca_certificate_file_path

Faraday::Connection.new(url,options={
    :ssl => ssl_options
}) do |builder|
    builder.adapter  :typhoeus
end

在这里做错了什么?

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)

相关问答

Selenium Web驱动程序和Java。元素在(x,y)点处不可单击。其...
Python-如何使用点“。” 访问字典成员?
Java 字符串是不可变的。到底是什么意思?
Java中的“ final”关键字如何工作?(我仍然可以修改对象。...
“loop:”在Java代码中。这是什么,为什么要编译?
java.lang.ClassNotFoundException:sun.jdbc.odbc.JdbcOdbc...