Record Class IdServerMailTransportSMTP

java.lang.Object
java.lang.Record
com.io7m.idstore.server.api.IdServerMailTransportSMTP
Record Components:
host - The mail host
port - The port
All Implemented Interfaces:
IdServerJSONConfigurationElementType, IdServerMailTransportConfigurationType

public record IdServerMailTransportSMTP(String host, int port) extends Record implements IdServerMailTransportConfigurationType
Vanilla SMTP with an insecure STARTTLS upgrade (if supported). This falls back to plaintext when a mail server does not indicate support for STARTTLS. Additionally, even if a TLS session is negotiated, server certificates are not validated in any way. This TransportStrategy only offers protection against passive network eavesdroppers when the mail server indicates support for STARTTLS. Active network attackers can trivially bypass the encryption 1) by tampering with the STARTTLS indicator, 2) by presenting a self-signed certificate, 3) by presenting a certificate issued by an untrusted certificate authority; or 4) by presenting a certificate that was issued by a valid certificate authority to a domain other than the mail server's. For proper mail transport encryption, see SMTPS or SMTP_TLS.