Charmed Quark Systems
Google
WWW CharmedQuark.com

Go Back   Charmed Quark Systems > General Discussion > Beta Driver Development
Register FAQ Members List Calendar Mark Forums Read

Beta Driver Development Discussion of new drivers, finding someone to write a new driver, etc...

Reply
 
Thread Tools Display Modes
  #1  
Old 06-14-2007, 06:34 AM
wuench wuench is offline
 
Join Date: Jan 2006
Location: Saint Louis, MO US
Posts: 2,552
Lightbulb POP3 Email Notification Driver

POP3 Email Notification Driver
Version 1.7

POP3 is a simple protocol used to retrieve email. This driver will use the POP3 protocol to download the current number of emails in your inbox, as well as the email headers (Date, Sender, Subject). The primary purpose of this driver is to notify you of the emails in your inbox, it does not actually download the entire message.

The driver also has the ability to search the email message for tokens you define that can be used to trigger events in CQC.

Release Info
Version 1.0 - Original Version
Version 1.1
  • Configurable date/time formats
  • Configurable line formats
  • Read/Write Fields
Version 1.2
  • Custom Fields (Email field updates)
  • GetMail Field (manual mail download)
Version 1.3 - Fixed blank subject exception

Version 1.4
Version 1.5 - Fixed String Exception
Version 1.6 - Lowered logging level for ConvertDate Error
Version 1.7 - Configurable Timeout

See Attached HTML file for instructions...

Available in CQC 4.3.901+

Attached Files
File Type: html GenericPop3Email.html (9.9 KB, 34 views)

Last edited by wuench : 05-05-2013 at 06:17 AM. Reason: Version 1.7 Update
Reply With Quote
  #2  
Old 06-14-2007, 06:53 AM
robertmee robertmee is offline
 
Join Date: Feb 2005
Posts: 1,953
Default

Quote:
Originally Posted by wuench
POP3 Email Notification Driver
Version 1.0

I put together this little driver to download email counts and headers via POP3. It will reach out at the configured interval, login to your POP3 server and download the From, Date, and Subject lines into stringlists. Messages are not deleted from the inbox.

Authentication
At this time only plaintext authentication is supported. POP3 Secure Authentication/APOP and SSL (i.e. GMAIL) are not supported.

Field Descriptions
All fields are read only.

Hostname: Hostname of the POP3 Server (String)
HostAddress: IP and Port of POP3 Server (String)
Username: Username used for authentication (String)
MessageCount: Number of email messages in inbox (Card4)
Interval: Polling Interval in Minutes (Card4)
LastUpdatedTime: Time of last update (Time)
LastUpdated: Time of last update (String)
LastStatus: Status of last update (Enum/String)
DateList: Date lines in message headers (StringList)
FromList: From lines in message headers (StringList)
SubjectList: Subject lines in message headers (StringList)

Entries in the stringlist fields have a message number prepended to them to make the entries unique.

Hey, that's cool...No problem with installing multiple instances of these for multiple accounts, right?
Reply With Quote
  #3  
Old 06-14-2007, 07:01 AM
wuench wuench is offline
 
Join Date: Jan 2006
Location: Saint Louis, MO US
Posts: 2,552
Default

Quote:
Originally Posted by robertmee
Hey, that's cool...No problem with installing multiple instances of these for multiple accounts, right?

You should be able to do that, no problem.
Reply With Quote
  #4  
Old 06-14-2007, 07:58 AM
Squintz's Avatar
Squintz Squintz is offline
Integration Partner
 
Join Date: Aug 2005
Location: Harford, Maryland
Posts: 1,953
Default

That is pretty cool. Does it not download the contents of the message?

I won't get much use out of it since I use GMAIL but I could think of a million uses for it otherwise. OnForce.com notifications is one. Vonage voice mail notifications is another.
__________________
David
Z-Wave World Magazine|Baltimore Hackerspace
"Why think outside the box when you could let the box think for you." - My take on Home Automation
Reply With Quote
  #5  
Old 06-14-2007, 08:51 AM
wuench wuench is offline
 
Join Date: Jan 2006
Location: Saint Louis, MO US
Posts: 2,552
Default

It does not download messages. I have thought about it, but it get's a little complicated with MIME, HTTP, multipart messages, and attachments. Also, dealing with deleting the emails or not and determining if they are new adds more complications. I am not sure turning CQC into a full on email client would be better than just having the IV launch a Web Widget or a real email client that has more functionality and security.

Unfortunately GMAIL uses SSL tunneling and Dean doesn't have SSL code in CQC yet to deal with it. So until then it won't be possible. Secure POP Authentication, though, would be easy to add, if I just had a secure server to test against or someone willing to test for me. That is just a MD5 password hash which CQC has an object for.
Reply With Quote
  #6  
Old 06-14-2007, 09:03 AM
Dean Roddey's Avatar
Dean Roddey Dean Roddey is offline
Administrator
 
Join Date: Aug 2002
Location: Mountain View, CA
Posts: 32,496
Default

BTW, I'm currenty adding support for SMTP outgoing e-mails. I got most of it done yesterday and will complete it today. It only supports SMTP and it won't support accounts that require POP3 login before sending outgoing.
__________________
Dean Roddey
Software Geek Extraordinaire
Reply With Quote
  #7  
Old 06-14-2007, 11:52 AM
zaccari zaccari is offline
 
Join Date: Sep 2006
Location: Baltimore, MD
Posts: 2,394
Default

Quote:
Originally Posted by wuench
Unfortunately GMAIL uses SSL tunneling and Dean doesn't have SSL code in CQC yet to deal with it. So until then it won't be possible. Secure POP Authentication, though, would be easy to add, if I just had a secure server to test against or someone willing to test for me. That is just a MD5 password hash which CQC has an object for.
Catch me in #cqc sometime over the next few days. We can probably work something out to get you what you need.

Russ...
Reply With Quote
  #8  
Old 06-14-2007, 02:00 PM
wuench wuench is offline
 
Join Date: Jan 2006
Location: Saint Louis, MO US
Posts: 2,552
Default

Quote:
Originally Posted by Dean Roddey
BTW, I'm currenty adding support for SMTP outgoing e-mails. I got most of it done yesterday and will complete it today. It only supports SMTP and it won't support accounts that require POP3 login before sending outgoing.

I noticed that in your blog. Maybe with a little more work we can replace MSExchange with CQC...
Reply With Quote
  #9  
Old 06-14-2007, 02:00 PM
wuench wuench is offline
 
Join Date: Jan 2006
Location: Saint Louis, MO US
Posts: 2,552
Default

Quote:
Originally Posted by zaccari
Catch me in #cqc sometime over the next few days. We can probably work something out to get you what you need.

Russ...


Thanks Russ. #CQC, is that the chat on CQC Users??
Reply With Quote
  #10  
Old 06-14-2007, 04:24 PM
znelbok's Avatar
znelbok znelbok is offline
Integration Partner
 
Join Date: May 2005
Location: Calderwood, Australia
Posts: 3,758
Default

Can you use the event trigger with this dirver.

So if I send an e-mail home the server will see it and then do something based on the text in the subject field? Not sure what yet, just thinking out loud

Mick
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 01:20 AM.


Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.