Re: VB code to check POP3 account



Hi Tom,
>> Well... I'm not sure how much TCP/IP experience you have, so
>> I'll give you some general information - and let you ask specific
>> questions as needed.
TFTR(s). Enough to know the general nature of what goes on. Also good
that I help manage the POP3 server itself.

>> You could use outlook automation to do this, but then of course you
>> are then reliant on the presence of outlook. It that isn't a problem for
>> you then this may be an easy way to accomplish this - especially if
>> the POP3 server uses one of the alternative authentication methods.
I'll look into the suggestion, as I've seen a little of this before.
The target host is up 24/7 with the ability to run Outlook. More on the
authentication methods below.

>> You can of course get 3rd party POP3 controls, if you don't like the
>> above and you have to do something other then clear text
>> authentication. That would eliminate the reliance on outlook, and would
>> most likely let you more easily access more secure POP3 accounts.
Last resort. While easier & providing a control I could use for other
things, I would be looking at the low-cost route (not that some controls are
very affordable). Again, authentication listed below.

>> Or you can use my prefered way... And that is just to use a socket
>> and just talk directly to the server. For the majority of pop servers,
>> this method will be just fine (actually, all of them would be just fine -
>> it's just that most just use a regular plain text login). The pop3
>> protocol is fairly simple. Connect to port 110, get a ready response,
>> and then start sending/recieving text. You will probably want to look
>> at the RFC for available commands and user authentication (there are
>> 2 common ways to do this - USER/PASS and APOP) APOP is a
>> little more complicated because it involves the use of an MD5 hash to
>> compute a checksum.
Yes, I didn't mention I had a small program here (running on the same
system) written in VB by a past employee that is able to logon an account of
the same mail server (not a hard-coded name, but a field for it's name or
IP) & show the messages. By the response codes (& lack of any other file but
the possible RTL) it looks like direct communication. APOP methods are not
needed, as it should be cleartext authentication.

>> As for the socket communication... There are a number of ways to
>> do that as well. I'm not sure which version of VB you have, but I
>> know at least Pro had the winsock control available. I can't give
>> you much advice on that, since I never used it much :)
Pro. A thought would be the possibility of using VB3 or 16-bit VB4
(both Pro) at a later point to set up a WfW311 system that is dedicated to
this task (I collect older systems & realize many people would just rather
have me get a system a few years old for this). Of course that kills the
ability of any VB6 or 32-bit controls.

>> You also have the choice of 3rd party socket controls. Again, I
>> can't give much advice here, since I didn't really use many. I did
>> use a control from Mabry for a few apps, and it worked well -
>> but, unfortunately, I'm not sure if it's still available.
Again, a last resort, but probably in front of a POP3-specific control,
because of more functionality for me. But cost is a factor again. I'm not
sure of what I would gain here either.

>> And the last way, and my prefered method, is to just use the
>> winsock API directly. If you decide to go this way, I do have a
>> file that has a lot of the winsock api declared - including wrapper
>> functions for some of the common winsock macros and a couple
>> of extra utility functions. I would be willing to pass that along
>> if you want it. Too bad I never finished that winsock typelib :)
Might be one of my prefered methods too, as I have exposure here. Even
have Daniel Applegate's book of the 16-bit stuff, although I realize the
16-bit winsock was added after the fact. But I do run the Microsoft 16-bit
winsock on a few systems & could probably find the API calls.

> Oh yeah... The rfc for pop3:
> ftp://ftp.rfc-editor.org/in-notes/rfc1939.txt
> There are couple of more for extensions, updates etc - but you
> should be able to get them from the same site:
> http://www.rfc-editor.org/ and to a search for pop3 :)
Yes, I do have a few books around with the POP3 command/response codes.
Good to know what is going on behind the scenes, but being an internal
program (not even that work is calling for it, but I think it could help
me/us) might make me lazy for error control. But I'll make it more robust
later. ;-)
David
David@xxxxxxxxxxxxx


.



Relevant Pages

  • Re: Communication to TCP-IP Port
    ... there are some very good examples of winsock code with/without the winsock ... I will look for a WinSock control or perhaps just use the ... >> IP like you do with a com port, ... >> You can't communicate to a TCP/IP port like you ...
    (microsoft.public.access.modulesdaovba)
  • San Diego .NET Developer Group Meeting (FEB 6th 2007)
    ... Using Forms Authentication with SharePoint 2007: ... and control access to your site ... Automating Builds with MSBuild and Team Foundation Server: ...
    (microsoft.public.dotnet.general)
  • Re: Access Control problems
    ... You need to configure 2 things for access control ... after authentication, ... the ntfs permission of files / folder. ... Configure IIS 5.0 Web Site Authentication in Windows 2000 ...
    (microsoft.public.inetserver.iis.security)
  • Re: Composite Control need write permisson
    ... If a control needs write access, then the permissions on the directory ... or has a process in place that let's you request particular ... Integrated Windows Authentication may cause some ...
    (microsoft.public.dotnet.framework.aspnet.buildingcontrols)
  • Re: Coding the Winsock control....
    ... do I just add the ActiveX Microsoft Winsock version 6 ... rename the winsock control to "winsock1"?? ... > Private Sub Winsock1_DataArrival ...
    (microsoft.public.access.formscoding)