views:

813

answers:

1

I'm using Delphi 2009 and the lastest Indy 10 from svn to send e-mails using SMTP, but it doesn't work with gmail (Google Apps hosted domain). When I try to send an e-mail I get "Must issue a STARTTLS command first".

I tried googling about it but I found several forums and several solutions, but they all just bashed some code or just said I needed a OpenSLL dll, which so far isn't very clear to me exactly what I need.

Can someone please tell exactly which dll I need and what do I have to change in the my TIdSMTP and TIdMessage objects in order to send the e-mails through gmail's smtp server?

Also, an explanation about why this authentication is different and what the dll is for is very welcome.

Thanks.

+4  A: 

Perhaps Marco can help you...

Edit: with this link to the source code.

Hugues Van Landeghem
That worked, thanks, one thing that I'm still not sure, do I really need the OpenSSL dlls? The article says nothing about it, but when I tested it gives me an exception "Cannot load library" if I try to send e-mails without the dlls. This is still not very clear to me. Thanks.
Fabio Gomes
You need the OpenSSL DLLs if you use Indy's native SSL IOHandler class, There are third-party IOHandler classes available that do not use the DLLs.
Remy Lebeau - TeamB