Note. If you do not have time to read this long journey, the solution (with source code) is here: http://www.coastrd.com/smtps .
For a long time, sending uing SMTP email (port 25) through a remote mail server (usually to a web hosting company) was easily connected with the application. Open TCP port 25, send "HELO ..." etc.
There is a problem with the googles email service because they insist on using port 465 SMTPS, i.e. SMTP with TLS encryption:
http://en.wikipedia.org/wiki/Transport_Layer_Security#How_it_works
Studying the way to do this with the C ++ language or the base flavor, I came across:
http://forums.realsoftware.com/viewtopic.php?f=2&t=29542
http://forums.realsoftware.com/viewtopic.php?f=2&t=26959&p=162671#p162671
and Python question:
Python smtp gmail authentication error (sending email via smtp gmm server)
If I understand this correctly, will I need to implement TLS encryption in my C ++ code, complete with all shaking hands and talks?
From a C # question:
sending email using gmail smtp (secure layer) in C ++
This library does not do this.
http://johnwiggins.net/jwsmtp/
ADDED:
Many people simply install stunnel as a service and then configure it to manage the SSL connection.
http://www.stunnel.org/about/
Stunnel - OpenSSL. OpenSSL (http://josefsson.org/gnutls4win/)
" libgcrypt , , 10 ".
: "libeay32.dll" 1.35MB + "libssl32.dll" 310k + "zlib1.dll" 75k
:
http://www.chilkatsoft.com/downloads.asp
DLL ActiveX (COM) ( "dll" - .net).
"ChilkatMime.dll" 1.33Mb, "ChilkatCert.dll" 1.26MB, "ChilkatUtil.dll" 720k. C.dll, , C/++/BASIC/Python .. , , , .
, , , , 25, , 465.
, :
http://www.catalyst.com/products/sockettools/secure/library/index.html
1/3 . ! , , . . dll, .dll, , 230 ! .
SLL/TLS ( ) ( STARTTLS ..)
CodeIgniter , ( Python, asp, php ..),
http://codeigniter.com/forums/viewthread/84689/
, "", MIME:
"EHLO " + sLocalHost + CRLF
"MAIL FROM: " + sMailFrom + CRLF
"RCPT TO: " + "me@mydomain.com" + CRLF
"DATA: Testing, Testing xyz" + CRLF
CRLF + "." + CRLF
"QUIT"
.
MIME- ( , ..), , , .
CryptLib - , SSL/TLS C .dll 1 ( ). , DLL , , .
http://www.cs.auckland.ac.nz/~pgut001/cryptlib/download.html
, MIME. 330 ! .
(MTA), MIME- , !
:
http://www.coastrd.com/smtps.