Coinbase API client.getAccount(...)开始返回:“错误:无法获取本地发行者证书". [英] Coinbase API client.getAccount(...) started returning: "Error: unable to get local issuer certificate"

查看:106
本文介绍了Coinbase API client.getAccount(...)开始返回:“错误:无法获取本地发行者证书".的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

该问题于2020年3月31日太平洋标准时间早些时候开始.向Coinbase发出API调用的服务器托管在带有node.js(GCP)的Google App Engine上.与Coinbase相同的证书连接问题也发生在几周前,持续了大约一天.证书连接性问题在当时就已经完全消失了.那时或今天之前,未对调用Coinbase API的服务器进行任何代码更改.相同的代码已经使用了一年多,但几个月前已移至App引擎. -Coinbase是否一直在进行网络更改,从而影响对Google Cloud Platform的证书身份验证?

The issue started late-morning PT, on March 31, 2020. The server making the API call to Coinbase is hosted on Google App Engine with node.js (GCP). The same cert-connectivity problem to Coinbase also happened a few weeks ago, and lasted for about a day. The cert-connectivity problem went away all by itself at that time. No code changes were made to the server calling the Coinbase API then, or today. The same code has been working for over a year, but was moved to App engine a few months ago. - Has Coinbase been making network changes that would impact cert-authentication to Google Cloud Platform?

推荐答案

Coinbase他们更新了他们的证书. 修复:启动客户端时,您可以将strictSSL设置为false或传递新的有效证书.

Coinbase they updated their certificates . Fix: when you initiate the client you can either set strictSSL to false or pass in the new valid certificates.

将strictSSL设置为false:

Set strictSSL to false:

var Client = require('coinbase').Client;
var client = new Client({
   apiKey: mykey, 
   apiSecret: mysecret,
   strictSSL: false
});

更新证书文件(您应该可以在此处导出它们- https://baltimore-cybertrust-root.chain-demos.digicert.com/或尝试coinbase.com并在那里导出):

update cert files (you should be able to export them here - https://baltimore-cybertrust-root.chain-demos.digicert.com/ or try coinbase.com and export there):

var Client = require('coinbase').Client;
var client = new Client({
   apiKey: mykey, 
   apiSecret: mysecret,
   caFile: myNewCertFile
});

myNewCertFiles应该使用更新的证书遵循以下文件格式: https://github.com/coinbase/coinbase-node/blob/master/lib/CoinbaseCertStore.js

myNewCertFiles should follow this files format with the updated certs: https://github.com/coinbase/coinbase-node/blob/master/lib/CoinbaseCertStore.js

这篇关于Coinbase API client.getAccount(...)开始返回:“错误:无法获取本地发行者证书".的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆