🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.internet.socket
Article #3621

POP3 and SSL Problem

#3621
From: Chris
Date: Sun, 10 Jul 2005 20:40
42 lines
2131 bytes
Have an email account that requires SSL authentication.  Dropped a 
TIdSSLIOHandlerSocket and TidPOP3 control on my form.
When I try to connect I get a "Socket Error # 0".   When in Outlook 2003 
only SSL is checked to make this work.

Not sure what I am doing wrong here?

I am using Indy 9.0 and have the following sample code:

TIdSSLIOHandlerSocket *IdSSLPOP3IOHandlerSocket;
TIdPOP3 *SP_POP3;

bool __fastcall TForm_AutoEmail::LoginEmailServer()
{
   SP_POP3->Username   = 
iny_Locations->FieldByName("POP3_USER_ID"  )->AsString;
   SP_POP3->Password   = 
Tiny_Locations->FieldByName("EMAIL_PASSWORD")->AsString;
   SP_POP3->Host           = 
_Locations->FieldByName("POP3_HOST"     )->AsString;
   SP_POP3->Port            = 995;
   SP_POP3->IOHandler  = IdSSLPOP3IOHandlerSocket;
   try
      {
      SP_POP3->Connect(3000);        // This is where the Socket Error #0 
happens
      SP_POP3->CheckMessages();
      }
   catch(...)
      {
      if (SP_POP3->Connected())
         SP_POP3->Disconnect();
      AddToMemo("Connect/Authenticate POP3 Server Failed!",true);
      return false;
      }
   return true;
}
//---------------------------------------------------------------------------

Thanks in advance for any help

Chris 
Technical Details
Message-ID: <42d187e2@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!news-out.nntp.be!propagator2-sterling.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Thread: 11508e,b7728fe2d1a3844e,start
X-Google-Attributes: gid11508e,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Chris" <chris@visiblechanges.com>
Newsgroups: borland.public.cppbuilder.internet.socket
Subject: POP3 and SSL Problem
Date: Sun, 10 Jul 2005 15:40:36 -0500
Lines: 44
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2527
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2527
X-RFC2646: Format=Flowed; Original
NNTP-Posting-Host: 24.153.139.206
Message-ID: <42d187e2@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1121028066 24.153.139.206 (10 Jul 2005 13:41:06 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!news-out.nntp.be!propagator2-sterling.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail