Lambda SSL error UNABLE_TO_VERIFY_LEAF_SIGNATURE posted on forums by Shikasta_Kashti

0

Hi,

I'm trying to connect to my mail server from Lambda but when I do I get this error: UNABLE_TO_VERIFY_LEAF_SIGNATURE and it happens intermittently.

I found one post here in the AWS Lambda forums with same error and it indicates it was some DNS error. Here's the link to that post: https://forums.aws.amazon.com/message.jspa?messageID=608080

Any ideas as to what's wrong here? It was week fine until last week. I checked the SSL of the server with ssllabs.com and it doesn't indicate any issue with it.

Original: https://forums.aws.amazon.com/thread.jspa?threadID=235965

Pieter
질문됨 2년 전791회 조회
1개 답변
0

Found an article: https://levelup.gitconnected.com/how-to-resolve-certificate-errors-in-nodejs-app-involving-ssl-calls-781ce48daded

Suggestions are:

  1. Quick fix: Add rejectUnauthorized on request or ENVIRONMENT setting
  2. Add CA certificate to request

Add to request:

https.request({ 
      ....,
      rejectUnauthorized: false,
    },
...)

or environment variable:

NODE_TLS_REJECT_UNAUTHORIZED=0

Alternatively and safer solution is CA certificate:

   ca: [fs.readFileSync([certificate path])],
   rejectUnauthorized: true,
}```
Pieter
답변함 2년 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠