N8N SMTP: Error: self-signed certificate

Error while sending user invite by smtp using servers that do not use SSL or STARTTLS. Is there any way to disable STARTTLS for sending user invites?

Describe the problem/error/question

I configured a docker N8N with environment variables to use an SMTP server without SSL and authentication in my local network. The problem apparently is that even disabling ssl the system still uses STARTTLS and there is no variable to disable it.
I created an workflow to test sending an email use the same server and it works if I disable STARTTLS otherwise I get the same error.

What is the error message (if any)?

self-signed certificate
Error: self-signed certificate
at TLSSocket.onConnectSecure (node:_tls_wrap:1677:34)
at TLSSocket.emit (node:events:519:28)
at TLSSocket.emit (node:domain:488:12)
at TLSSocket._finishInit (node:_tls_wrap:1076:8)
at TLSWrap.ssl.onhandshakedone (node:_tls_wrap:862:12)

Failed to send email
Failed to send email

Information on your n8n setup

Debug info

core

  • n8nVersion: 1.69.2
  • platform: docker (self-hosted)
  • nodeJsVersion: 20.18.0
  • database: postgres
  • executionMode: regular
  • concurrency: -1
  • license: enterprise (production)
  • consumerId: e5e2d778-60a7-46c8-b58a-f23e58ed7d6f

It looks like your topic is missing some important information. Could you provide the following if applicable.

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

Along with N8N_SMTP_SSL, can you please also try setting N8N_SMTP_STARTTLS to false?