Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
IMAP authentication
#1
Hi folks,

I am trying to write a console based IMAP email client and am feeling a little confused about the connection/authentication part.

Some questions:
  • Does the client connect/authenticate every time it makes a request of the server, or does it make the connection once? Maybe someone can outline the general steps that happen when an client (like Thunderbird) starts up and a user starts to check her email. Reading about the IDLE capability led me to believe that the connection is eventually terminated by the server, and so the client needs to periodically refresh the connection. Am I thinking correctly that the client should 1) make the initial connection/authentication, 2) search for the initial list of folders and display them, 3) search for subjects in Inbox (or whatever the default folder is) and display them, 4) enter IDLE mode, 5) periodically refresh the IDLE mode unless 6) another action/request is needed, in which case, exit IDLE, do the action, re-enter IDLE???

  • For authentication, is an ssl context via the ssl module the right way to go, or STARTTLS? It seems like maybe the client has to be prepared for multiple possibilities with regards to authentication, in which case, what is the tree path that the client should follow?

I think that's it for questions for now, but please feel free to assume I know little and want to know much!

Thanks very much!
Reply


Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020