Test SMTP Connection

SMTP

telnet smtp.gmail.com 25
Trying 74.125.68.109...
Connected to smtp.gmail.com.
Escape character is '^]'.
220 smtp.gmail.com ESMTP m6sm1314984pfc.133 - gsmtp

SMTPS

Using SSL

openssl s_client -connect smtp.gmail.com:465
CONNECTED(00000003)
depth=2 OU = GlobalSign Root CA - R2, O = GlobalSign, CN = GlobalSign
verify return:1
depth=1 C = US, O = Google Trust Services, CN = GTS CA 1O1
verify return:1
depth=0 C = US, ST = California, L = Mountain View, O = Google LLC, CN = smtp.gmail.com
verify return:1
---
Certificate chain
 0 s:C = US, ST = California, L = Mountain View, O = Google LLC, CN = smtp.gmail.com
   i:C = US, O = Google Trust Services, CN = GTS CA 1O1
 1 s:C = US, O = Google Trust Services, CN = GTS CA 1O1
   i:OU = GlobalSign Root CA - R2, O = GlobalSign, CN = GlobalSign
---
Server certificate
-----BEGIN CERTIFICATE-----
MIIExjCCA66gAwIBAgIQVkWCHiVGZO8DAAAAAMv3iDANBgkqhkiG9w0BAQsFADBC
...<omitted>
MwPSLvh2HjaIF7pQ49VSqgSjKEp26EWNP+4GKVUdPGObFxC/PmXjQrWKVfWnegqt
VrtCxAkMXdLFaiIK8pxlTZUIk1yYSJUSfbw=
-----END CERTIFICATE-----
subject=C = US, ST = California, L = Mountain View, O = Google LLC, CN = smtp.gmail.com

issuer=C = US, O = Google Trust Services, CN = GTS CA 1O1

---
No client certificate CA names sent
Peer signing digest: SHA256
Peer signature type: ECDSA
Server Temp Key: X25519, 253 bits
---
SSL handshake has read 2639 bytes and written 386 bytes
Verification: OK
---
New, TLSv1.3, Cipher is TLS_AES_256_GCM_SHA384
Server public key is 256 bit
Secure Renegotiation IS NOT supported
Compression: NONE
Expansion: NONE
No ALPN negotiated
Early data was not sent
Verify return code: 0 (ok)
---
---
Post-Handshake New Session Ticket arrived:
...<omitted>
---
read R BLOCK
220 smtp.gmail.com ESMTP gb9sm9409673pjb.7 - gsmtp

Using TLS

Other utilities

  • telnet-ssl: apt install telnet-ssl

  • gnutls-cli: apt install gnutls-cli

Reference

  • https://qmail.jms1.net/test-auth.shtml

  • https://www.samlogic.net/articles/smtp-commands-reference-auth.htm

  • https://www.ndchost.com/wiki/mail/test-smtp-auth-telnet

Last updated