Subscribe to
Posts
Comments
NSLog(); Header Image

WebMail.app

Mail (the app) on Mac OS X uses standard mbox files to store its messages. Given this, how hard would it be to write a webmail client that literally served up your local mboxes. When I'm at a friend's house, how great would it be to log into my machine with a simple browser and see my current email. Mail will have already filtered them into the proper folder(s), marked some as spam, and done all the "checking" of my eight accounts for me (every five or ten minutes, in fact).

Mac OS X has Apache and the ability to run perl, python, php, and scads of other things. The idea here is pretty simple: use Mail to do what it's always done - to fetch your messages, filter them, etc. Then use its documents - standard mbox files - to serve up a multiple-account webmail system. Replies could go into the Outbox mbox for sending by… Mail itself once again! The really ambitious developer could probably add in other Mail "hooks" such as the ability to specify a signature for replies, the ability to "mark as junk," and other things. Mail is also fairly AppleScriptable, no?

Or maybe it has already been done?

20 Responses to "WebMail.app"

  1. I have used Zoë for this in the past. It's not so much a webmail server for OS X as an indexer. It is to your email what Google is to the web, and it does some really cool tricks. Plus the fact that it is very usable as a webmail client.

    http://guests.evectors.it/zoe/

  2. Mail is scriptable, but it is buggy and unreliable. I really like Mail's UI and junk handling, but it's not well suited to scripting. Perhaps the next iteration in Panther will include better AppleScript support.

  3. Good idea! I don't know if you read Rael Dornfest, but he posted a "hack" awhile ago that basically fed your mbox into pine so you could telnet into your machine and get the same mail as Mail.app. Steven Frank also had posted the source to a program called Emila that he was working on, and it contained some mbox parsing code. If you can't find it let me know and I'll send it to you.

  4. Mailsmith is really scriptable... I'll have to check what format it uses. I'm guessing it's something standard/simple.

  5. Install the UW IMAP daemon and SquirrelMail (needs PHP).

  6. It stores mail in standard mbox format. The configuration is stored in PLIST-format. Both are easily parsed using Perl, Python, or Ruby. All three feature easy HTML output. So, a webmail system reading mail.app's mailboxes shouldn't be that hard to write yourself.

  7. [NSLog] Mail.app enhancements

    Erik blogs about an idea for a web-interface to Mail.app. So I've done some digging on designing my own web interface. Since Perl has the most advanced CGI interface. If Mail::MboxParser is half as advanced, it shouldn't be too difficult to write. The ...

  8. This is an interesting idea, but it seems more of a hassle than simply using IMAP (which already works quite well with Mail.app). Use IMAP and all you need is something like IMP to get your mail when you're away from your desk.

    Most mail servers already support IMAP, but people just tend to set up their email accounts using POP because that's what they're used to.

  9. Brad, unfortunately you're also missing the point. First, IMAP is not an ideal solution for some situations. I know what it is full well and I choose to use POP. I dislike IMAP.

    Secondly, and more importantly, you're missing the fact that by doing what I'm suggesting, nearly everything is handled for you by Mail: the fetching, the filtering, the "marking as junk," the sending, etc. And hey, when you get home, everything is where you left it.

    Letting Mail do the lifting and simply reading its files, effectively, is why this idea is so appealing.

  10. Erik, I'm curious -- why don't you like IMAP?

  11. IMAP moves the storage responsibilty to the server, which means that you need huge storage space there when archiving a lot (my mail archive contains nearly 10500 messages currently). It further means that you cannot access your mails while you're offline (ISP breakdown or iBook/PowerBook on the road). Additionally, when the server is hacked, your whole inbox can be read/wiped by the intruder.

  12. Erik: Maybe you could write about why you dislike IMAP, then we could help you out by making some suggestions?

    About my "missing the fact that by doing what I'm suggesting, nearly everything is handled for you by Mail." I didn't miss that fact, I simply pointed out that you're suggestion doesn't seem to offer anything that a good webmail/desktop IMAP client combination doesn't already offer (without you having to do any coding).

    Andreas wrote: "It further means that you cannot access your mails while you're offline"

    Wrong. In fact, the default "message caching" setting for IMAP accounts in Mail.app is to cache all message and attachments on your machine. So, you can access all your messages offline, change them while offline, and when you connect, Mail will synchronize everything.

    No need to get snarky guys. I just trying to help! 🙂

  13. Andreas, when your computer gets hacked the same thing can happen. And judging from my firewall logs (and I think pretty much everyone will agree), a lot more home users are getting hacked than servers. A server is a lot more likely to be backed up so that even if your email is wiped (and you really care about your email being read? I haven't found your PGP key yet so you don't seem to be too concerned about anyone reading your email).

  14. Aaron: the difference between a server and a desktop machine is that I can't secure the former. A server has to have certain services running (like apache, sendmail, popd, sshd, etc), which are a potential security risk (esp. sendmail). On my deskop, I just turn them all off.

    Additionally, the client is my responsibility to care about. I'm not trusting anyone esle to secure my inbox (I wouldn't even trust myself if I had a choice).

    And PGP is nice, but until there's some better adaption, I can't use it (hen-and-egg-problem, I know.) I actually thought about installing/using it many times lately. Of course, when my email machine gets hacked, so does the private key...

  15. oh and Brad: didn't know about that feature, thanks. So the main problem left is the huge server-side storage required (something in the range of 1GB)...

  16. Brad, you're still missing the problem: IMAP isn't something everyone's got, but everyone's got a Web browser. And why have to set up IMAP accounts for 10 accounts just to catch up on mail? I want a Web interface for mail residing on my computer already. Thassit! 🙂

  17. Good point...it's been a long time since I didn't have IMAP. I guess I have a skewed view of the services offered by most ISP's.

    Best of luck with your idea!

  18. Andreas: of course you can secure a server. Sure, you need to run services on it but if it is completely possible to secure it by keeping it patched and up to date: when you compile use a static bounds checker, using an OS that supports stack protection (ie: ProPolice), simple things like that go a long ways. And anyways, there are a lot of Windows users who have completely firewalled their boxes off, yet still subject to attacks from Worms via email...

    Also, generally your private key is encrypted with a passphrase so if somebody grabs your private key, they're still SOL if they don't have your passphrase (sure they could install a trojan to sniff it but a good admin will have installed tripwire and would have known instantly about modifications to the system). There is a solution to the adoption problem and that is to just start using it, even if you don't encrypt emails you can still sign them and people notice that and then maybe they'll adopt it. I started using PGP about two years ago and in the beginning nobody I know used it either, but it's caught on with a couple of my friends and we all use it regularly now.

  19. I found this page after doing some googling. I had a similar idea. I really want to be able to fire up a web browser and see my mail as it currently exists on my main work computer: an iMac 17" running Panther's Mail.app. I can't find anyone who's written an app that I want, so I'm in the process of making my own. I'm using the existing Perl modules to parse the mbox files and folders. If anyone is interested in seeing what I have so far, or in helping out, drop me an email. joel@edogg.com

  20. Mail.app web interface

    I had this idea a while ago. My main work machine is a 17" iMac which lives at my office. I have customized all kinds of automatic filtering and sorting options configured. This is a real time-saver, while I'm at work. However, I often work from home and


Trackback URI | Comments RSS

Leave a Reply

Please abide by the comment policy. Valid HTML includes: <blockquote><p>, <em>, <strong>, <ul>, <ol>, and <a href>. Please use the "Quote Me" functionality to quote comments.