Results 1 to 9 of 9

Thread: POP Basics and Advanced ...

  1. #1

    Thread Starter
    Randalf the Red honeybee's Avatar
    Join Date
    Jun 2000
    Location
    off others' brains
    Posts
    4,345

    POP Basics and Advanced ...

    Can someone give me a list of all POP and SMTP protocol commands that a client needs to know and the possible server responses? Or direct me to a resource which will give me all these details?

    And I mean all, including SMTP authentication etc.

    .
    I am not a complete idiot. Some parts are still missing.
    Check out the rtf-help tutorial
    General VB Faq Thread
    Change is the only constant thing. I have not changed my signature in a long while and now it has started to stink!
    Get more power for your floppy disks. ; View honeybee's Elite Club:
    Use meaningfull thread titles. And add "[Resolved]" in the thread title when you have got a satisfactory response.
    And if that response was mine, please think about giving me a rep. I like to collect them!

  2. #2

    Thread Starter
    Randalf the Red honeybee's Avatar
    Join Date
    Jun 2000
    Location
    off others' brains
    Posts
    4,345

    Well ...

    OK, proceeded upto the use of EHLO and subsequently AUTH PLAIN. Can someone explain me what is CRAM-MD5 and its equivalent stuff? Encoding/SSL? If so, how can it be used in VB?

    .
    I am not a complete idiot. Some parts are still missing.
    Check out the rtf-help tutorial
    General VB Faq Thread
    Change is the only constant thing. I have not changed my signature in a long while and now it has started to stink!
    Get more power for your floppy disks. ; View honeybee's Elite Club:
    Use meaningfull thread titles. And add "[Resolved]" in the thread title when you have got a satisfactory response.
    And if that response was mine, please think about giving me a rep. I like to collect them!

  3. #3
    PowerPoster
    Join Date
    Aug 2000
    Location
    India
    Posts
    2,288
    Look at www.vbip.com . It gives you a full explanation of all that is required for POP and SMTP implementation. Look at the doc file on planetsourcecode, which explains the concept very nicely. http://planetsourcecode.com/vb/scrip...20969&lngWId=1

  4. #4

    Thread Starter
    Randalf the Red honeybee's Avatar
    Join Date
    Jun 2000
    Location
    off others' brains
    Posts
    4,345

    Well ...

    Thanks, Amit. I am checking out the links and will be back with results after I test the code/concepts.

    .
    I am not a complete idiot. Some parts are still missing.
    Check out the rtf-help tutorial
    General VB Faq Thread
    Change is the only constant thing. I have not changed my signature in a long while and now it has started to stink!
    Get more power for your floppy disks. ; View honeybee's Elite Club:
    Use meaningfull thread titles. And add "[Resolved]" in the thread title when you have got a satisfactory response.
    And if that response was mine, please think about giving me a rep. I like to collect them!

  5. #5

    Thread Starter
    Randalf the Red honeybee's Avatar
    Join Date
    Jun 2000
    Location
    off others' brains
    Posts
    4,345

    Well ...

    OK, can't make a headway now. I send the EHLO command to the SMTP server and get a reply that says AUTH LOGIN and AUTH PLAIN are supported. There are other methods, like CRAM-MD5, but I think that's something to do with SSL or such other encryption.

    I try the AUTH PLAIN command. The server responds with 334 Go On. That means the AUTH PLAIN command was acknowledged by the SMTP server. Now what? How do I proceed?

    I created a dummy SMTP server and ran my Outlook Express with it. OE sent the EHLO command and I imitated the server response I had received earlier. OE simply proceeded with the MAIL FROM command.

    Then I adopted the same approach with my own SMTP code, and when the server returned 334 Go On after I had sent AUTH PLAIN, I tried sending the MAIL FROM command, but the server then returns with AUTHENTICATION FAILED message.

    I am testing the code in this way: I try to send various possible commands to my SMTP server. Whenever I am stuck at some response, I use my SMTP server code to imitate these responses with my Outlook Express as the client. Whatever steps OE takes, I repeat them with my SMTP code. So far I don't seem to be able to authorize the SMTP transaction the way OE does. Any help?

    I am using the GMX mail service for this purpose. My OE settings for SMTP are simple authorization with the same username and password as the POP settings. No SSL etc. And OE works perfect with the GMX account. The SMTP server is mail.gmx.net.

    .
    I am not a complete idiot. Some parts are still missing.
    Check out the rtf-help tutorial
    General VB Faq Thread
    Change is the only constant thing. I have not changed my signature in a long while and now it has started to stink!
    Get more power for your floppy disks. ; View honeybee's Elite Club:
    Use meaningfull thread titles. And add "[Resolved]" in the thread title when you have got a satisfactory response.
    And if that response was mine, please think about giving me a rep. I like to collect them!

  6. #6
    PowerPoster
    Join Date
    Aug 2000
    Location
    India
    Posts
    2,288
    What are you trying to create, Mail server or client?

  7. #7

    Thread Starter
    Randalf the Red honeybee's Avatar
    Join Date
    Jun 2000
    Location
    off others' brains
    Posts
    4,345

    Well ...

    A client, well, sort of.

    There are two computer users in my home, me and my brother. And I want to write an application that will sit in the system tray and will check and retrieve all emails from all the accounts set up in it. So if one of us connects to the net, still all emails to him or me will be downloaded, and we need not re-connect just because the other could not check his emails.

    Currently we have accounts set up in OE, but that requires us to log off and then log back in. Instead this application will run all the time, and will retrieve emails from the POP accounts which we are going to set up in it. Then OE will be instructed to retrieve emails from this application, which will be a local transfer.

    I have code (downloaded from somewhere) that includes an SMTP client and a POP client, both of which run well by themselves. I want to add the simple authentication feature to the SMTP client code as after Jan 30, even Yahoo is going to be SMTP authenticated. And I am stuck here.

    I am using a test POP server just to see how OE reacts to the commands from a real POP server.

    If I confused you with the earlier description of my testing, here is it once again:

    I take the SMTP client code and make changes to it, so after EHLO it sends AUTH PLAIN command. Note that all commands from the client to the SMTP server as well as the SMTP server back to the client are being logged in a text file, so I can track them any time. I receive 334 from the SMTP server. That's a code which indicates that the SMTP server has recognized the AUTH PLAIN command. Now I have to pass on the authentication information to the SMTP server. And I don't know how.

    So, I now run my pseudo-POP server. It's a plain winsock app that will display all received data in a listbox, and has a textbox in which I shall type a response code and send it. I change my OE settings so all SMTP on my GMX account will be directed towards 127.0.0.1 where my pseudo-POP server is running. Then I create a dummy message to be sent from my GMX account in the OE and send it. OE connects to my POP server, which is indicated by the POP server as it accepts a Winsock connection. I then send a POP server response of 220. OE then sends me EHLO and I reply to it just like the GMX server responded, only I restrict the AUTH clause to PLAIN because I have no idea about CRAM-MD5 and such. OE acknowledges it and sends me a command string of AUTH PLAIN. Fine, my GMX server had sent me 334, so I send OE a response code of 334. OE goes on to send me the MAIL FROM command. I abort at this stage.

    I now return to my SMTP code. Connect to the net, send an email to the GMX SMTP server. When I retrace the steps till the AUTH LOGIN, the GMX server sends me the response code 334. Imitating the OE behaviour, I send the MAIL FROM command, when the GMX server gives me "Authentication Failure" message and terminates the connection.

    .
    I am not a complete idiot. Some parts are still missing.
    Check out the rtf-help tutorial
    General VB Faq Thread
    Change is the only constant thing. I have not changed my signature in a long while and now it has started to stink!
    Get more power for your floppy disks. ; View honeybee's Elite Club:
    Use meaningfull thread titles. And add "[Resolved]" in the thread title when you have got a satisfactory response.
    And if that response was mine, please think about giving me a rep. I like to collect them!

  8. #8
    PowerPoster
    Join Date
    Aug 2000
    Location
    India
    Posts
    2,288
    Dsesn't the doc file I referred say anything about the authentication. When I was working on a email client, it did not use to ask for password for SMTP. If it doesnot gives you any clue, you can try writing to the author of SMTP articles at www.vbip.com. They had responded to me favourably when I was working on my project. I will try and see if I am of any help.

  9. #9

    Thread Starter
    Randalf the Red honeybee's Avatar
    Join Date
    Jun 2000
    Location
    off others' brains
    Posts
    4,345

    Well ...

    I shall give that a try.

    I am basically stuck at the exact process of identifying the client to the server after I send AUTH LOGIN or AUTH PLAIN.

    .
    I am not a complete idiot. Some parts are still missing.
    Check out the rtf-help tutorial
    General VB Faq Thread
    Change is the only constant thing. I have not changed my signature in a long while and now it has started to stink!
    Get more power for your floppy disks. ; View honeybee's Elite Club:
    Use meaningfull thread titles. And add "[Resolved]" in the thread title when you have got a satisfactory response.
    And if that response was mine, please think about giving me a rep. I like to collect them!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width