Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I'm trying to build an email platform too, yes it's hard. But I thought it was only because I'm a beginner and 1 man team.

Some of the reasons why I think it's hard:

* I don't think security was a big deal to many of the mail applications when they were being built. I tried and gave up so many times trying to find a strong hashing algorithm that both dovecot and ruby supported. There was practically no documentation on this and it felt like I was venturing into territory never before seen.

* Parsing emails to be display correctly seems impossible. Sometimes emails have "<br>" in them and sometimes they have "\n". But what if the "\n" doesn't mean newline but it's just what someone wrote in the email? They come in a variety of mime types and formats. It sometimes seems impossible to do this.

* Not everyone uses the RFC standards! I thought the RFC said that a subject can only be 78 chars long. Yet I get emails all day long that go way beyond this which cause major problems in my code. AM I THE ONLY ONE AROUND HERE THAT CARES ABOUT RFCS?



Look at http://archiveopteryx.org/badmail/ for your storage backend.

Strict RFC implementation, email normalization. Bad emails won't kill your email client 30 years from now.


> Sometimes emails have "<br>" in them and sometimes they have "\n".

One of those should have an HTML MIME type, one should have a plaintext MIME type. The decoding is specified in detail in RFCs and W3C recommendations, please follow those rather than try to implement this using try and error.

> Not everyone uses the RFC standards!

That is unfortunately true, ...

> I thought the RFC said that a subject can only be 78 chars long.

... and one of the major reasons why is because people think but don't read. There exist all kinds of crazy myths about the content of RFCs, which is how all those broken implementations arise, this seems to be one of them--but feel free to point out which RFC says this where, in case I really have missed it.


On your last point, email subjects are created by end users. I don't think I've ever had a mail client complain that my subject was too long and refer me to the RFC. Pretty much every application developer will prefer complying with their users' preferences rather than specs.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: