Archived Forum Post

Index of archived forum posts

Question:

IMAP - Unable To Connect?

Mar 03 '16 at 06:21

Hi Guys,

We're using the IMAP components to connect our software to customer mailboxes and while it's been working fine for all, I've had a report in this morning from one particular customer that they get nothing but error messages back. I think it's something on their network (e.g. Firewall) but they've been running some tool from Microsoft that claims that everything is fine, Outlook can connect without any problems etc. They also claim to have checked their firewall to make sure that port 993 is open.

I've tried to connect using the customer's details and do indeed get an error out (verbose log below) but connecting to our own mailboxes or webmail (e.g. Gmail) is working absolutely fine. Having stepped through our code it looks to be failing when connecting and never even reaches the login stage.

Any ideas?

Unable to connect to server. The following error was returned:
ChilkatLog:
  Connect_Imap(47ms):
    DllDate: Feb 13 2015
    ChilkatVersion: 9.5.0.48
    UnlockPrefix: ****
    Username: ****
    Architecture: Little Endian; 64-bit
    Language: .NET 4.0 / x64
    VerboseLogging: 1
    connectToImapServer(47ms):
      hostname: ****
      port: 993
      socket2Connect(47ms):
        connect2(47ms):
          hostname: ****
          port: 993
          ssl: 1
          connectImplicitSsl(47ms):
            connectSocket(31ms):
              domainOrIpAddress: ****
              port: 993
              connectTimeoutMs: 30000
              connect_ipv6_or_ipv4(31ms):
                Multi-threaded domain to IP address resolution
                connecting to IPV4 address...
                ipAddress: ****
                createSocket:
                  Setting SO_SNDBUF size
                  sendBufSize: 262144
                  Setting SO_RCVBUF size
                  recvBufSize: 4194304
                --createSocket
                connect(31ms):
                  Waiting for the connect to complete...
                  myIP: ****
                  myPort: 64051
                  socket connect successful.
                --connect
              --connect_ipv6_or_ipv4
            --connectSocket
            clientHandshake(16ms):
              clientHandshake2(16ms):
                readHandshakeMessages(16ms):
                  numBytesRequested: 5
                  Connection closed by peer.
                  passiveClose:
                    Passive socket closing complete.
                  --passiveClose
                  Failed to read beginning of SSL/TLS record.
                --readHandshakeMessages
              --clientHandshake2
            --clientHandshake
            Client handshake failed. (3)
          --connectImplicitSsl
          ConnectFailReason: 0
        --connect2
      --socket2Connect
      failReason: 0
    --connectToImapServer
    connect failed.
  --Connect_Imap
--ChilkatLog

Accepted Answer

Never mind. I updated to the latest version of the IMAP component (v9.5.0.55) and it seemed to do the trick.

It seems that the customer had switched to Exchange 2013 and something in the configuration didn't sit well with v9.5.0.48