Hi I am trying to use the email output plugin in logstash but I can't get it to work on the server with docker, on localhost it works with port 587 but on the server I get an OpenSSL hostname not match with ssl certificate error, any idea of where should I put the certificate for the email
This is telling you that the server hostname/ip you are using doesn't match the CN or SAN on the certificate. I would use what's on the cert or if possible update the SANs on the cert.
The logstash email output is a wrapper around mail. The smtp delivery module for that notes that
When using TLS, some mail servers provide certificates that are self-signed or whose names do not exactly match the hostname given in the address. OpenSSL will reject these by default. The best remedy is to use the correct hostname or update the certificate authorities trusted by your ruby.
It then goes on to note that
If that isn't possible, you can control this behavior with an :openssl_verify_mode setting.
That is only true if you are calling mail directly, the email output does not provide a way to set mail options.
Thanks for answering, this is the output plugin configuration
output {
stdout {
codec => rubydebug
}
email {
to => "jrojasp@grupoasd.com.co"
subject => "pruebacorreo"
htmlbody => "<html><>"
domain => "papiro.grupoasd.com.co"
address => "10.0.4.106"
port => 587
use_tls => true
username => "notificaciones.prueba@prueba.com.co"
password => 123456"
}
}
This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.