Um eine SMTP Verbindung zu testen, kann unter Mac das Programm swaks
genutzt werden. Dieses ist auch für Linux / BSD verfügbar.
brew install swaks
swaks -tls --to lb@blattertech.ch --from btsrv@blattertech.com --server mail.cyon.ch --auth-user btsrv@blattertech.com
Die Ausgabe:
user@mac ~ % swaks -tls --to lb@blattertech.ch --from btsrv@blattertech.com --server mail.cyon.ch --auth-user btsrv@blattertech.com
Password:
=== Trying mail.cyon.ch:25...
=== Connected to mail.cyon.ch.
<- 220 mail.cyon.ch ESMTP ready
-> EHLO btmb02.local
<- 250-mail.cyon.ch
<- 250-SIZE 52428800
<- 250-8BITMIME
<- 250-PIPELINING
<- 250-HELP
<- 250 STARTTLS
-> STARTTLS
<- 220 2.0.0 Start TLS
=== TLS started with cipher TLSv1.2:ECDHE-RSA-AES128-GCM-SHA256:128
=== TLS no local certificate set
=== TLS peer DN="/CN=*.cyon.ch"
~> EHLO btmb02.local
<~ 250-mail.cyon.ch
<~ 250-SIZE 52428800
<~ 250-8BITMIME
<~ 250-PIPELINING
<~ 250-HELP
<~ 250 AUTH LOGIN
~> AUTH LOGIN
<~ 334 VXNlcm5hbWU6
~> YnRzcnZAYmxhdHRlcnRlY2guY29t
<~ 334 UGFzc3dvcmQ6
~> NHlDRlR0UWpkNno=
<~ 235 2.0.0 OK
~> MAIL FROM:<btsrv@blattertech.com>
<~ 250 OK
~> RCPT TO:<lb@blattertech.ch>
<~ 250 Accepted
~> DATA
<~ 354 Enter message, ending with "." on a line by itself
~> Date: Tue, 18 Jul 2023 08:09:44 +0200
~> To: lb@blattertech.ch
~> From: btsrv@blattertech.com
~> Subject: test Tue, 18 Jul 2023 08:09:44 +0200
~> Message-Id: <20230718080944.016976@btmb02.local>
~> X-Mailer: swaks v20201014.0 jetmore.org/john/code/swaks/
~>
~> This is a test mailing
~>
~>
~> .
<~ 250 OK id=1qLdu8-007MqM-2t
~> QUIT
<~ 221 s078.cyon.net closing connection
=== Connection closed with remote host.