New webmail user interface being tested on beta server

Just in time for Christmas, we’re releasing our new webmail interface for testing on our beta server.

The new interface is the culmination of many months of work from many different team members, and has a number of new and powerful features.

  1. Full AJAX design with caching, pre-fetching and optimistic actions

    Rather than having to reload the entire page on each view or action, only the data that is needed is loaded from the server and displayed on the page. After you’ve viewed a message, that data is cached while you’re logged in, so viewing the message again is instant. While viewing a message, next and previous messages are pre-loaded so moving between messages is very quick. When applying an action (e.g. move message, delete message, etc.), the action is immediately applied on the screen and sent to the server making actions appear instant.

    Like the previous interface, there’s many keyboard shortcuts like ‘j’ and ‘k’ to move to the next/previous message, ‘x’ to mark message, ‘m’ to move the current/selected message(s), ‘g’ to search the folder listing, and ‘.’ (dot) to bring up the action menu for the current/selected message(s).

    All these features put together make using the new interface one of the fastest mail experiences available.

  2. Full conversations support across folders

    All messages are grouped together into conversations. A conversation represents the back and forth sending of messages on a particular topic. The conversation system we’ve built works across folders, so when clicking on a conversation to read it, you’ll see a stream of all related messages in all folders, including any messages filed into other folders, your own sent messages in your Sent Items folder, and any unfinished drafts you might have started in reply to a message in a conversation.

    This allows you to quickly see the historical context of any new message without having to dig through your saved messages to see the past messages, or what you sent in your last message.

  3. Archiving is the new default action

    After looking at the statistics of mailboxes on our system, we found that many people didn’t create any folders in their accounts, and instead just kept everything in their Inbox. This results in a large and cluttered Inbox, and makes it harder to find messages that need dealing with or responding to. Because of the large increase in storage space available to most people relative to the volume of email they get, the old paradigm of deleting email as soon as you’ve read it is less relevant, and instead it’s better just to save it in an Archive.

    So to make managing your email easier, we’ve now made Archive the default action. You can think of Archiving an email as "I just don’t want to see this in my Inbox any more, but I don’t want to permanently delete it either".

  4. Push updates when new email arrives

    When new emails arrive in your Inbox, they’ll be immediately pushed to your browser, no need to refresh to see when new emails have arrived.

We hope you enjoy trying out the new interface and the powerful new features.

A further note: the new interface is a work in progress. Look out for further updates posted to our blog in the new year.

Posted in News. Comments Off

New Opera/Fastmail office

After many months of planning and organisation, the Opera mail services team/Fastmail have finally moved in to the new Opera Australia office in Melbourne, Australia.

entrance_small

The bold new entrance. The photo doesn’t do justice to the great textured floor.

staff_small

All the Melbourne staff, from left: Andrew, Neil, Marian, Alfie (front), Rob, Richard (front) and Greg.

breakout_small

Our nice big break-out room and kitchen area.

street_small

All the offices have big windows to let in lots of natural light.

Thanks to Alfie for all his hard work in organising the building, fit out and move to the new office.

Posted in News. Comments Off

iOS 5 and mail application access patterns

This post contains some observations about how the mail application in iOS 5 appears to interact with IMAP servers. We’re posting this mostly as a reference for people interested.

In iOS settings, you can choose a "fetch interval", which is:

  • Manually (never fetches automatically)
  • Every 15 minutes
  • Every 30 minutes
  • Every hour
  • Push (only shown on servers supporting it, which I believe is currently only Exchange servers or Yahoo Mail)

If you choose "Manually", then there is no persistent connection once you exit the mail app.

If you choose any other interval, then a background daemon holds a persistent connection to the mail server. We don’t know exactly why they hold the connection open, and we’re not sure if it leaves the connection in IDLE state to get updates pushed to it. The main advantage of holding it open is probably skipping the overhead of re-authenticating/handshaking, but there’s also no good reason to explicitly close the connection after every fetch given that IMAP is supposed to be long-lived.

If you have these fetch intervals set, and then break your network connection, then iOS will attempt to reconnect the next time it wants to fetch your mail again.

Note that the intervals listed appear to be only approximate. iOS appears to be smart about batching requests together, so it gets as much work done as it can while the phone is awake or the network connection is "up". Also, opening the mail app, or opening a folder in the mail app, will often trigger a refresh too.

Posted in Technical. Comments Off

"View" link removed from attachments on message read screen in "Public Terminal" mode

When you enable the "Public Terminal" option on the login screen, Fastmail sets the "no-cache" and "no-store" cache control headers on every page. This means that browsers should not store a copy of the pages you visit (e.g. emails you read) to their local disk. Even after you logout of your session and leave the computer, someone comes along and tries to view a page in the browser history, it should re-check with the server first, which of course will return "this user is now logged out, show the login page instead".

However this is a problem with this whole setup related to attachments. When an email has an attachment, the content of the attachment might be in a form the browser doesn’t understand (e.g. Microsoft Word document). In that case, the browser has to save a copy of the attachment to the local disk, and then launch Microsoft Word to open the file.

Now in the case of the "View" link, the saving to disk would be done automatically into a temporary file storage area. However in IE, if you try and download an SSL document with the no-cache or no-store attributes set, IE will explicitly not save the file to disk, and then when it tries to launch Microsoft Word to read the file, you’ll get a "file does not exist" error or the like.

http://support.microsoft.com/kb/812935
http://support.microsoft.com/kb/815313

For other browsers, it appears they work around this problem by actually saving a copy to disk in the temporary storage area, but they delete the file when you close the browser (at least that’s what Firefox did when I tested). That still potentially does leave the file on disk for some time.

To ensure the best privacy possible, while still allowing people to view attached documents in "Public Terminal" mode, we’ve decided to do the following:

  • When you login with the "Public terminal" mode, we’ve removed the "View" link next to attachments. This solves two problems; the unexpected "file not found" in IE, and the privacy concern of storing attachments to disk in the temporary file area of other browsers
  • We’ve left the "View" link next to image attachments, because the web browser can display images itself, without launching a separate program, so it can obey the "no-cache"/"no-store" directives
  • With the "Download" link (which automatically brings up a "Save as…" dialog box), we’ve removed the "no-cache" and "no-store" settings, which means that IE will let you download it and save it somewhere so you can open it to view the document.

We like this solution because it makes things clearer to the user. In "Public Terminal" mode, if you want to view an attachment, you have to download it first, explicitly save it somewhere and then view it. The alternative approach of letting the browser do it either fails (IE), or causes an auto-save of the file to a temporary area which leaves it temporarily cached on the machine when the user doesn’t expect it.

Posted in News, Technical. Comments Off

TCP keepalive, iOS 5 and NAT routers

This post contains some very technical information. For users just interested in the summary:

If over the next week you experience an increase in frozen, non-responding or broken IMAP connections, please contact our support team (use the "Support" link at the top of the http://www.fastmail.fm homepage) with details. Please make sure you include your operating system, email software, how you connect to the internet, and what modem/router/network connection you use in your report.

The long story: The IMAP protocol is designed as a long lived connection protocol. That is, your email client connects from your computer to the server, and stays connected for as long as possible.

In many cases, the connection remains open, but completely idle for extended periods of time while your email client is running but you are doing other things.

In general while a connection is idle, no data at all is sent between the server and the client, but they both know the connection still exists, so as soon as data is available on one side, it can send it to the other just fine.

There is a problem in some cases though. If you have a home modem and wireless network, then you are usually using a system called NAT that allows multiple devices on your wireless network to connect to the internet through one connection. For NAT to work, your modem/router must keep a mapping for every connection from any device inside your network to any server on the internet.

The problem is some modems/routers have very poor NAT implementations that "forget" the NAT mapping for any connection that’s been idle for 5 minutes or more (some appear to be 10 minutes or more). What this means is that if an IMAP connection remains idle with no communication for 5 minutes, then the connection is broken.

In itself this wouldn’t be so bad, but the way the connection is broken is that rather than telling the client "this connection has been closed", packets from the client or server just disappear which causes some nasty user visible behaviour.

The effect is that if you leave your email client idle for 5 minutes and the NAT connection is lost, if you then try and do something with the client (e.g. read or move an email), the client tries to send the appropriate command to the server. But the TCP packets that contain the command never arrive at the server, but neither are RST packets sent back that would tell the client that there’s any problem with the connection, the packets just disappear. So the local computer tries to send again after a timeout period, and again a few more times, until usually about 30 seconds later, it finally gives up and marks the connection as dead, and finally sends that information back up to the email client, which shows some "connection was dropped by the server" type message.

From a user perspective, it’s a really annoying failure mode that looks like a problem with our server, even though it’s really because of a poor implementation of NAT in their modem.

However this is a workaround for this. At the TCP connection level, there’s a feature called keepalive that allows the operating system to send regular "is this connection still open?" type packets back and forth between the server and the client. By default keepalive isn’t turned on for connections, but it is possible to turn it on via a socket option. nginx, our frontend IMAP proxy, allows you to turn this on via a so_keepalive configuration option.

However even after you’ve enabled this option, the default time between keepalive "ping" packets is 2 hours. Fortunately again, there’s a Linux kernel tuneable net.ipv4.tcp_keepalive_time that lets you control this value.

By lowering this value to 4 minutes, it causes TCP keepalive packets to be sent over open but idle IMAP connections from the server to the client every 4 minutes. The packets themselves don’t contain any data, but what they do do is cause any existing NAT connection to be marked as "alive" on the users modem/router. So poor routers with NAT connections that would normally timeout after 5 minutes of inactivity are kept alive, so the user doesn’t see the nasty broken connection problem described above, and neither is there a visible downside to the user either.

So this is how things have been for the last 4-5 years, which has worked great.

Unfortunately, there’s a new and recent problem that has now appeared.

iOS 5 now uses long lived persistent IMAP connections (apparently previous versions only used short lived connections). The problem is that our ping packets every 4 minutes mean that the device (iPhone/iPad/iPod) is "woken up" every 4 minutes as well. This means the device never goes into a deeper sleep mode, which causes significantly more battery drain when you setup a connection to the Fastmail IMAP server on iOS 5 devices.

Given the rapid increase in use of mobile devices like iPhones, and the big difference in battery life it can apparently cause, this is a significant issue.

So we’ve decided to re-visit the need for enabling so_keepalive in the first place. Given the original reason was due to poor NAT routers with short NAT table timeouts, that was definitely an observed problem a few years back, but we’re not sure how much of a problem it is now. It’s possible that the vast majority of modems/routers available in the last few years have much better NAT implementations. Unfortunately there’s no way to easily test this, short of actually disabling keepalive, and waiting for users to report issues.

So we’ve done that now on mail.messagingengine.com, and we’ll see over the next week what sort of reports we get. Depending on the number, there’s a few options we have:

  1. If there’s lots of problem reports, we’d re-enable keepalive by default, but setup an alternate server name like mail-mobile.messagingengine.com that has keepalive disabled, and tell mobile users to use that server name instead. The problem with this is many devices now have auto configuration systems enabled, so users don’t even have to enter a server name, so we’d have to work out how to get that auto configuration to use a different server name
  2. If there’s not many problem reports, we’d leave keepalive off by default, but setup an alternative server name like mail-keepalive.messagingengine.com that has keepalive enabled, and for users that report connection "freezing" problems, we’d tell them to switch to using that server name instead
  3. Ideally, we’d detect what sort of client was connecting, and turn on/off keepalive as needed. This might be possible using software like p0f, but integrating that with nginx would require a bit of work, and still leaves you with the problem of an iPhone user that is usually in their office/home all day and uses a wireless network with a poor NAT router, would they prefer the longer battery life, or better connectivity experience.

I’ll update this post in a week or two when we have some more data.

Posted in News, Technical. Comments Off

DKIM signing outgoing email with From address domain

DKIM is an email authentication standard that allows senders of email to sign an email with a particular domain, and for receivers of the email to confirm that the email was signed by that domain and hasn’t been altered. There’s some more information about how DKIM is useful in this previous blog post. We’ve been DKIM signing all email sent via FastMail for the last 2 years.

In the original design of the DKIM, the domain that signed the email had no particular relationship to the domain in the From address of the email. This was particularly useful for large email providers like us. We have 10,000′s of domains, but would sign all email with just our "generic" messagingengine.com domain.

However this state of affairs is beginning to change. Standards like Author Domain Signing Practices explicitly link the domain of the email address in the From header of the email to the DKIM signing domain. Also recently Gmail has changed their web interface so that email sent with a From domain that’s different to the DKIM signing domain may be shown with an extra "via messagingengine.com" notice next to the sender name.

So we’ve now rolled out new code that changes how all emails sent through FastMail are DKIM signed. We always DKIM sign with messagingengine.com (as we always have), but we also now sign with a separate key for the domain used in the From address header where possible (see below for more details).

For most users, there should be no noticeable difference. For users that use virtual domains at FastMail, or have their own domain in a family/business, then when you send via FastMail, Gmail should no longer show "via messagingengine.com" on the received message (if your DNS is correctly setup, see below for more details).

For users that host their DNS with FastMail (eg. nameservers for your domain are ns1.messagingengine.com and ns2.messagingengine.com), this will "just work". We’ve generated DKIM public/private keys for all domains in our database, and automatically do so when new domains are added. We also publish the public keys for all domains via ns1.messagingengine.com/ns2.messagingengine.com.

In general if you can, we highly recommend hosting your DNS with us. For most cases the default settings we provide "just work", and if you need to customise your DNS, our control panel allows you to add any records of any type, without the arbitrary limitations many other DNS providers have.

However for users that host DNS for their domains externally and want to continue to do so, you’ll have to explicitly add the DKIM public key using your domain hosters DNS management interface. Unfortunately there’s 100′s of different DNS providers out there, so we can’t give specific directions for each one.

The general steps are:

  1. Login to your FastMail account and go to Options –> Virtual Domains (or Manage –> Domains for a family/business account).
  2. Scroll to the bottom, and you’ll see a new "DKIM signing keys" section. For each domain you have, you’ll see a DKIM public key.
  3. Login to your DNS provider, and create a new TXT record for each domain listed and use the value in the "Public Key" column as the TXT record data to publish.

Important: Note that you have to add the TXT record for the domain name shown in the DKIM signing keys section, which will be mesmtp._domainkey.yourdomain.com, do not add it for the base domain name yourdomain.com, that won’t work.

That should be it.

Note that initially each domain is marked as DKIM disabled (Enabled column = [ ]). While a domain is DKIM disabled, we won’t sign any sent emails. This is to avoid DKIM signing failures when the receiving side tries to lookup the public signature and fails to find it. We regularly check each domain to see if the correct public key TXT record is being published. If it is, we mark the domain in our database as "DKIM enabled" (Enabled column = [*]), and then begin signing sent emails.

So after you setup the records at your DNS provider, you should wait a few hours, then check this table again to see that the domain is now correctly DKIM enabled.

Some other technical notes:

There’s currently no way to change the public/private key used to sign emails or upload new ones. We always generate our own key pair for each domain and use the DKIM selector "mesmtp" to sign emails. This shouldn’t be a problem. If you’re transitioning from another provider to FastMail, you can use our custom DNS to publish the DKIM record of the previous provider with it’s selector as well as our own during the transition. Vice-versa for transitioning away from FastMail. The only other reason to change the selector would be if the private key was compromised, which should never happen as it’s stored securely in FastMail’s systems.

Posted in News, Technical. Comments Off

Updated SSL certificate for messagingengine.com

Our existing SSL certificate for messagingengine.com was going to expire in the near future, so we updated it with a new one. The new one has a longer key as well, making it technically more secure as well. For 99% of users there was no noticeable change, things just continued to work as expected.

However because of the longer key, the new certificate has a slightly different root signing CA. It seems a few pieces of email software (mostly Eudora and some fetchmail installations) don’t have this new CA built in, and so have been complaining about the authority of mail.messagingengine.com when you try and send or receive email with an SSL connection.

Eudora: To fix this, after you get the connection error, you do the following (from the Eudora help site):

From the Personalities Window,Right Click on the Personality in question and select Properties: Incoming Mail: Last SSL Info: then go to the Certificate Manager and select the SSL Certificate in question. Click Add to Trusted.

For fetchmail, please follow the updated instructions on our wiki.

For other email software that doesn’t have the right CA certificate, you can download them and install them into your software. Since this is different for every piece of software, you’ll have to lookup the help for your particular system. The new root and intermediate certificates are:

https://www.fastmail.fm/certs/DigiCertHighAssuranceEVRootCA.crt
https://www.fastmail.fm/certs/DigiCertHighAssuranceCA-3.crt
Posted in News. Comments Off

New XMPP/Jabber server

This is a technical post. Fastmail users subscribed to receive email updates from the Fastmail blog can ignore this post if they are not interested.

We’ve just replaced the XMPP/Jabber server we use for our chat service. Previously we had been using djabberd. While this worked well for us for the last few years, unfortunately it hasn’t been receiving much development recently. This means many newer XMPP extensions aren’t available.

We looked at a number of alternate server options: Tigase, Prosody, ejabberd, OpenFire. In the end, we settled on ejabberd because of it’s relative maturity, good administration documentation, it’s widespread use in existing large installations, the active development community and it’s support for multiple domains (in the newest version).

Fortunately our existing architecture separated the XMPP/Jabber server from the backend storage details of our system (eg. user lists, user rosters, chat logging, etc) with an HTTP JSON API. Because of this, it was fairly straightforward to completely remove djabberd, write the equivalent interfacing components for ejabberd and slot that into place. A perfect two month piece of work for our summer intern student Samuel Wejeus. Thanks Samuel!

That work has now been done, and yesterday we completely removed djabberd and replaced it with ejabberd. For users that use our chat service, there shouldn’t actually be any noticeable difference at this point, everything should just continue to work as it did, but with this new base we should be able to add more features in the future.

Posted in News, Technical. Comments Off

Secure Login now only login button

When Fastmail started in 1999, https (secure SSL connections over http) was still a relatively young protocol, originally released in 1994. It was considered fairly computationally expensive, and though technically supported by most popular browsers, there were numerous performance and compatibility problems (eg. early browsers never cached any https resources). So although we always offered https as an option via the "Secure Login" button, the default button was just a regular "Login" over unencrypted http.

Of course since then there’s been massive changes in browsers, computing power and average level of security required on the Internet (eg. Firesheep). Because of this, https connections are now recommended for all logins, and we’ve defaulted to "Secure Login" being the primary login for some time.

As a further step, today we’re making "Secure Login" the only button. There’s really no reason these days not be using a secure login and having all data encrypted between your computer and our server.

For the very, very few cases where you might not want a secure login (eg. we’ve heard of some people in certain countries or on certain company networks having problems with https connections), you can click the +More link and there’s a link there that will switch you to a non-secure login screen. We highly discourage using this, however it’s an option of last resort if you need it.

Posted in News. Comments Off

Moving to a new credit card provider, may generate a small temporary charge

TL;DR: You may see a $1 charge appear on the credit card you have registered at Fastmail. This is temporary as part of a conversion process and will completely disappear within a few days. There is nothing you need to do.

We’re currently in the process of moving our credit card payment gateway to a new provider, Global Collect. Global Collect are a large and well respected provider of international payment services that will allow us to support more cards and payment methods in the future.

As part of the switching process, we’re securely converting all credit card details from being stored on Fastmail systems, to being stored at Global Collect. By doing this, we’ll be able to remove all credit card details from our system, something we’ve wanted to do for a while.

However there is one issue. To enter the credit card details into their system, we can’t just enter them as is, we have to enter them with a transaction so that the card can be checked and authorised.

We’re doing this by creating a dummy $1 authorisation against each card. With credit cards, it’s possible to create an authorisation on a card, but never actually complete the transaction. After a few days the authorisation times out, and the money is never actually taken from the account.

However the $1 authorisation is still something that banks will do their usual fraud checks against, potentially alerting you to the transaction via email or a phone call, and potentially having the transaction appear (temporarily until it time out) on your online statement. Because of different gateways, the payment on your statement may appear to come from either "Fastmail" or "Opera Software".

If you do see something like this occur on your credit card, then there’s no need to worry. This is just a consequence of the transfer, and the $1 charge will completely disappear from your credit card in a few days. In some cases, it’s also possible that there may be two separate attempts to charge $1, because Global Collect will route payment attempts through multiple gateways if one appears to fail. Again, there is no need to worry about this.

We’re sorry for any inconvenience this has caused some people, we didn’t realise up front the full issues this would cause some users, especially the surprising contacts from their bank, we thought it would be basically an invisible process for all users.

At this point there is nothing you need to do. If your bank contacts you about the charge, you should tell them it’s ok and to process it. The $1 charge will completely disappear after a few days.

Once the conversion is complete, all Fastmail payment services should continue as normal. Account renewals should be automatic (unless you’ve explicitly disabled them), and you should be able to add funds/upgrade/downgrade from the appropriate Options screens.

Long term we want to add additional payment options as supported by Global Collect, the first of these is likely to be Paypal sometime in a few months.

Posted in News. Comments Off
Follow

Get every new post delivered to your Inbox.

Join 2,379 other followers