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
feita há 2 anos791 visualizações
1 Resposta
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
respondido há 2 anos

Você não está conectado. Fazer login para postar uma resposta.

Uma boa resposta responde claramente à pergunta, dá feedback construtivo e incentiva o crescimento profissional de quem perguntou.

Diretrizes para responder a perguntas