1
votes
IdMessage1.Clear;
IdSSLIOHandlerSocketOpenSSL1 := TIdSSLIOHandlersocketopenSSL.Create(nil);

IdSSLIOHandlerSocketOpenSSL1.SSLOptions.Method      := sslvTLSv1;
IdSSLIOHandlerSocketOpenSSL1.SSLOptions.Mode        := sslmUnassigned;
IdSSLIOHandlerSocketOpenSSL1.SSLOptions.VerifyMode  := [];
IdSSLIOHandlerSocketOpenSSL1.SSLOptions.VerifyDepth := 0;

IdSSLIOHandlerSocketOpenSSL1.Host :=  'smtp.gmail.com';
IdSSLIOHandlerSocketOpenSSL1.Port := 587;
IdSMTP1.IOHandler := IdSSLIOHandlerSocketOpenSSL1;
IdSMTP1.UseTLS := utUseExplicitTLS;
IdMessage1.Body.Append('h');
IdMessage1.From.Name := '******';
IdMessage1.From.Address :=  '****';
IdMessage1.Recipients.EMailAddresses :='*****';
IdMessage1.Subject := 'POWIADOMIENIE';
IdSMTP1.UserName := '*******';
IdSMTP1.Password  := '*******';
IdSMTP1.Host :='smtp.gmail.com';

IdSMTP1.Port := 587 ;

//IdSMTP1.AuthType := satDefault;
// IdSMTP1.Authenticate;
IdSMTP1.Connect;
IdSMTP1.Send(IdMessage1);
IdSMTP1.Disconnect;

//idSMTP1.Authenticate;
end;

Hello, trying to send email to gmail using INDY and Delphi XE7 . Unfortunately, I get the error "SSL in not availaible on this server " screen from Wireshark

screenshot

1
did you try to enable access to your gmail account for 3rdparty apps? support.google.com/accounts/answer/3466521Gem
The program has available the necessary DLL's for the connection? libeay32.dll, libssl32.dll, ssleay32.dllGermán Estévez -Neftalí-
your SMTP connection is being disconnected immediately after the STARTTLS reply has been received. That implies that the SSL/TLS handshake is failing, or otherwise that an exception is being raised during the handshake. TIdSMTP closes the socket in those conditions.Remy Lebeau
Certainly WireShark has the ability to get the error messages as text that you could copy/paste into your post instead of using an illegible graphic that is useless to those reading from a mobile device or behind a corporate proxy? Graphics should only be used when absolutely necessary because there's no other way to clearly describe the problem. They are not necessary to include textual error messages. Please have a little consideration. Thanks.Ken White
I change dll's file for opensll and now everything work.Wallers Jason

1 Answers

0
votes

Changing libeay32.dll and ssleay32.dll to the current Version solves the problem!