-
Notifications
You must be signed in to change notification settings - Fork 2.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FR] Add config option to skip cert validation/verification for SMTP #3709
Comments
For example certificate is for mail.blabla.com which resolves to 122.34.56.78 and one want to access it local ip 192.168.1.5. But accessing locally will say certificate is invalid. There needs to option to skip that verification. As a workaround I added DNS record in host file in my container (docker/podman) with switch |
You can already use: receivers:
- name: myreceiver
email_configs:
- to: '[email protected]'
tls_config:
insecure_skip_verify: true ... but this is per-receiver. An option is needed for global SMTP tls_config. |
Fixes: prometheus#3709 Signed-off-by: Mathieu Parent <[email protected]>
I created #3732, with: global:
smtp_from: '[email protected]'
# smtp_smarthost: 'mail.blabla.com:465'
smtp_smarthost: '10.0.0.1:465'
smtp_auth_username: '[email protected]'
smtp_auth_password: 'randompasss'
smtp_require_tls: false
smtp_tls_config:
insecure_skip_verify: true
receivers:
- name: myreceiver
email_configs:
- to: '[email protected]' |
Fixes: prometheus#3709 Signed-off-by: Mathieu Parent <[email protected]>
Fixes: prometheus#3709 Signed-off-by: Mathieu Parent <[email protected]>
Fixes: prometheus#3709 Signed-off-by: Mathieu Parent <[email protected]>
Fixes: prometheus#3709 Signed-off-by: Mathieu Parent <[email protected]>
Independent of the pending improvement for global smtp tls config, i think there is nothing to do here. |
Also instead of disabling tls_verify I would encourage you to use |
Fixes: prometheus#3709 Signed-off-by: Mathieu Parent <[email protected]>
What did you do?
I have a SMTP server with invalid cert. (accessing via different IP than where domain points to)
What did you expect to see?
a configuration option like insecure_skip_verify in tls_config but for SMTP which allows me to use self-signed/invalid certificate for SMTP.
Environment
System information:
Linux 6.6.14-200.fc39.x86_64 x86_64
Alertmanager version:
alertmanager, version 0.26.0 (branch: HEAD, revision: d7b4f0c)
build user: root@df8d7debeef4
build date: 20230824-11:11:58
go version: go1.20.7
platform: linux/amd64
tags: netgo
Prometheus version:
prometheus, version 2.49.1 (branch: HEAD, revision: 43e14844a33b65e2a396e3944272af8b3a494071)
build user: root@6d5f4c649d25
build date: 20240115-16:58:43
go version: go1.21.6
platform: linux/amd64
tags: netgo,builtinassets,stringlabels
Alertmanager configuration file:
The text was updated successfully, but these errors were encountered: