ladjs / superagent

Ajax for Node.js and browsers (JS HTTP client). Maintained for @forwardemail, @ladjs, @spamscanner, @breejs, @cabinjs, and @lassjs.
https://ladjs.github.io/superagent/
MIT License
16.59k stars 1.33k forks source link

certificate has expired #1567

Closed lnts2015 closed 4 years ago

lnts2015 commented 4 years ago

use "superagent": "^4.0.0",

my code : superagent.get('https://xxx.net/a.json') .end((err,info)=>{ console.error(err); console.info(info); });

error info:


{ Error: certificate has expired
    at TLSSocket.<anonymous> (_tls_wrap.js:1116:38)
    at emitNone (events.js:106:13)
    at TLSSocket.emit (events.js:208:7)
    at TLSSocket._finishInit (_tls_wrap.js:643:8)
    at TLSWrap.ssl.onhandshakedone (_tls_wrap.js:473:38) code: 'CERT_HAS_EXPIRED', response: undefined }
niftylettuce commented 4 years ago

This is not a bug with superagent. The certificate of the server you are sending a request to has expired and needs renewed.

marcuspoehls commented 3 years ago

@lnts2015 Have you been able to solve this problem? Running into the same issue and all certificates look good on my servers.