Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.


Welcome, Guest
Guest Settings
Help

Thread: Some mail questions SSL, POP3 and IMAP



Permlink Replies: 6 - Last Post: Apr 5, 2017 2:56 AM Last Post By: Asger Joergensen Threads: [ Previous | Next ]
Asger Joergensen

Posts: 370
Registered: 11/18/08
Some mail questions SSL, POP3 and IMAP
Click to report abuse...   Click to reply to this thread Reply
  Posted: Apr 3, 2017 6:42 AM
Hi

Does indy POP3 and IMAP, with AoutoLOgin = true, use SSL as default ?

Is it normal that a mailserver can be accessed with both POP3 and IMAP ?
(the one I use can)

It is said that when using POP3 the downloaded messages are deleted,
unless specified not to, but when I used:

TIdPOP3::Retrieve( int, TIdMessage*);

The messages were fortunately not deleted, is that just on my server or
is that the normal functionality for TIdPOP3::Retrieve.

Thanks in advance
Best regards
Asger

Remy Lebeau (Te...


Posts: 9,447
Registered: 12/23/01
Re: Some mail questions SSL, POP3 and IMAP
Click to report abuse...   Click to reply to this thread Reply
  Posted: Apr 3, 2017 3:14 PM   in response to: Asger Joergensen in response to: Asger Joergensen
Asger wrote:

Does indy POP3 and IMAP, with AoutoLOgin = true, use SSL as default ?

SSL/TLS has nothing to do with user authentication itself. AutoLogin simply
tells Indy whether to perform protocol-appropriate authentication after connecting
to the server.

However, SSL/TLS is commonly used to protect the transmission of sensitive
information, like login credentials. So, IF the Indy client is configured
to use SSL/TLS (and no, that is NOT the default setup), it will attempt to
enable SSL/TLS before then performing user authentication.

To enable SSL/TLS, you must:

- assign an SSLIOHandler component, like TIdSSLIOHandlerSocketOpenSSL, to
the client's IOHandler property.

- set the client's UseTLS property to the appropriate SSL/TLS mode, depending
on the capabilities of the particular port you are connecting to.

- utNoTLSSupport = SSL/TLS is disabled

- utUseImplicitTLS = initiate an SSL/TLS handshake as soon as the socket
is connected, before exchanging any protocol data, such as greetings and
logins.

- utUseExplicitTLS = connect to the server unsecurely and then initiate
an SSL/TLS handshake only if the server advertises support for the appropriate
start command (STLS, STARTTLS, etc).

POP3 typically requires utUseImplicitTLS on port 995, and utUseExplicitTLS
on port 110.

IMAP typically requires utUseImplicitTLS on port 993, and utUseExplicitTLS
on port 143.

Is it normal that a mailserver can be accessed with both POP3 and IMAP ?

That is entirely up to email providers to decide. But it is common for a
provider to support both, yes.

It is said that when using POP3 the downloaded messages are deleted,
unless specified not to

That is typically NOT the case, no. But it is possible, yes.

First off, there is no way in the POP3 protocol to specify a message SHOULD
NOT be deleted. There is only a command (DELE, via the TIdPOP3::Delete()
method) to mark a message for deletion (the message is not actually deleted
until the QUIT command is sent, via the TIdPOP3::Disconnect() method).

However, POP3 does not prevent server-side policies from automatically marking
a message for deletion once it has been downloaded. This is even stated
in the POP3 specification (see RFC 1939, https://tools.ietf.org/html/rfc1939,

Section 8, "Scaling and Operational Considerations", for details).

but when I used:

TIdPOP3::Retrieve( int, TIdMessage*);

The messages were fortunately not deleted, is that just on my server
or is that the normal functionality for TIdPOP3::Retrieve.

That is the normal behavior for most POP3 servers.

--
Remy Lebeau (TeamB)
Asger Joergensen

Posts: 370
Registered: 11/18/08
Re: Some mail questions SSL, POP3 and IMAP
Click to report abuse...   Click to reply to this thread Reply
  Posted: Apr 4, 2017 1:54 AM   in response to: Remy Lebeau (Te... in response to: Remy Lebeau (Te...
Hi Remy

Thank you very much for explaining.

Best regards
Asger

Edited by: Asger Joergensen on Apr 4, 2017 1:12 PM
Asger Joergensen

Posts: 370
Registered: 11/18/08
Re: Some mail questions SSL, POP3 and IMAP
Click to report abuse...   Click to reply to this thread Reply
  Posted: Apr 4, 2017 4:10 AM   in response to: Remy Lebeau (Te... in response to: Remy Lebeau (Te...
Hi Remy

Thank you very much for explaining.

Best regards
Asger
Asger Joergensen

Posts: 370
Registered: 11/18/08
Re: Some mail questions SSL, POP3 and IMAP
Click to report abuse...   Click to reply to this thread Reply
  Posted: Apr 4, 2017 5:19 AM   in response to: Remy Lebeau (Te... in response to: Remy Lebeau (Te...
Hi Remy

Thank you very much for explaining.

Best regards
Asger
Asger Joergensen

Posts: 370
Registered: 11/18/08
Re: Some mail questions SSL, POP3 and IMAP
Click to report abuse...   Click to reply to this thread Reply
  Posted: Apr 4, 2017 3:20 PM   in response to: Remy Lebeau (Te... in response to: Remy Lebeau (Te...
Hi Remy

Thank you very much for explaining.

Best regards
Asger
Asger Joergensen

Posts: 370
Registered: 11/18/08
Re: Some mail questions SSL, POP3 and IMAP
Click to report abuse...   Click to reply to this thread Reply
  Posted: Apr 5, 2017 2:56 AM   in response to: Remy Lebeau (Te... in response to: Remy Lebeau (Te...
Hi Remy

Thank you very much for explaining.

Best regards
Asger
Legend
Helpful Answer (5 pts)
Correct Answer (10 pts)

Server Response from: ETNAJIVE02