Hemlis update #6 – Contact discovery

After the Snapchat exploits, we have been getting questions from concerned people wondering what we are doing to protect our system from this kind of data leakage.

We are pretty sure you don't want this.

We are pretty sure you don’t want this.

In the early days of instant messaging users found each other through word of mouth or through other out-of-band communication. Instead of searching for your friends you asked them for their username or in some cases a long unique identifier (yes icq we are talking about you) which you then had to type in to your IM client in order to talk with them. While tedious this system is obviously still in use for most IM’s and other internet services like email and web pages (remember when we didn’t have search engines?).

You have likely already done the manual labor of finding your friends at least once by using social networks like Facebook, or in the case of mobile phones, by adding them to the phones address book. Lets be honest here, today most of us don’t have the patience to do all that work over and over again each time we add a new social application. If we can’t get it working within a few minutes, we move on to the next thing.

That is exactly why contact discovery is so common and quite necessary.

Malicious lookups
The basic principle of contact discovery is that an application extracts identifiers from a contact list and then uploads it to a server in order to match it against a list of known users. Implementations differ in how they upload the data, where some send everything in plain text others will use hashes or better yet hashes sent over encrypted connections. For any matching user the server will then reply with an identifier that the application can use in further contact with that particular user. Now depending on the implementation this is a potential problem.

When building a user search the easiest way to implement it would be to do something like the following:

  • The client sends the phone number 123456 to the server which matches it to user abcd and returns abcd to the client.
  • The client then sends the email foo@bar which again matches the user abcd so the server responds abcd.
  • The client now knows that abcd = 123456 and foo@bar.

A malicious client could now repeatedly and systematically ask for new matches until it had managed to assemble a huge database of users and their information. Which is what happened to Snapchat.

A small change to the servers response could completely avoid this problem. By giving each identifier a unique response it is impossible for the client to know which user a certain identifier belongs to. Now this solution wouldn’t work for a service with public profiles, like Facebook, but it happens to work quite well for an instant messenger where a client only needs to be able to send a message to a given address.

Another potential problem lies in the data that the client sends to the server during contact discovery. Even if the client sends the data hashed (obfuscated), the server will still get access to information that some people might not want that server to have. Although we wouldn’t be able to connect an email to a specific user unless that user had uploaded their email, we could create a huge database of email addresses, which in itself is valuable to certain companies (read: spammers). In a perfect world we could have contact discovery without sharing any information with the server, but unfortunatelly we don’t know of any practical way to do this.

Hemlis update #5 – New year new progress

Welcome to 2014, the year we make a change. It’s very due we gave all of you an update. It’s easy to think that a project like this is just a question of two clients, but it’s not. Here are the full spectrum of what we have been and are up to.

Clients
Both clients (iOS & Android) are neck to neck in development and we are starting to see the final product. We are testing the app heavily ourselves and it even got it’s own notification sound. A new way of handling emotes have been implemented that we are very satisfied with. And yes it’s as user friendly and beautiful as we wanted to be.

server-web

The Hemlis servers that are up and running so far.

Backend
Right now we are focusing on getting the backend software finished. There are quite a few parts to this puzzle. Login and client distribution, the XMPP servers, key exchange, attachment distribution, user lookup and most importantly scalability.


Encryption
Although we initially said we would base our encryption on PGP we are actually using the asymmetric encryption capabilities of Daniel J. Bernstein’s nacl or more specifically the libsodium implementation of it. The private key will of course never be uploaded to the server or shared in any way. We will also provide a way for users to verify the authenticity of each others public keys, both in band and out of band.


Infrastructure

The anycast nodes are getting spread out and configured. They will route traffic hidden away from snooping eyes to our server cluster. The rest of the hardware is also being set up. So far we have two digit numbers of machines dedicated for message handling. Next in line are the file clusters for attachments (images etc). Coming up on the agenda is load balancing and client distribution.

As always, can you also find us on Twitter and Facebook if you want to follow progress in the smaller of details.

Keep it secret, keep it safe.

Hemlis update #3

Dear Heml.is backer! We just wanted to update you a bit on what’s going on with the development of Heml.is!

Since the last update we’ve found a few good people to help out building the app. We’re close to having the full crew now, so it’s really helping a lot with the speed and quality of the service we’re building.

hemlis-ios-icon

Hello iOS, time to say hello to Hemlis!

Infrastructure
We’ve also decided on infrastructure plans and started building that. It’s important to build a scalable platform that can handle the millions of users that we hope the system is going to serve. We might post a longer explanation on the infrastructure a bit later!

Hello iOS
The design for the app is looking really good now! It’s a beauty to see and is becoming more and more intuitive to use. We have come so far that we will now start the development of the iOS version.

The questions about encryption
Most questions about heml.is is about the encryption we’re going to use. How it’s going to work and details about it. For different reasons, we’ve stayed away from talking too much about the details. It’s not because we’re arrogant, it’s just that dealing with the crypto community is really time consuming. Whatever solution we’ve decided on would be criticized and we aren’t really interested in the flame war that’s inevitable. We’d rather create and get things going. Maybe a small lesson for the crypto geeks out there would be to be supportive instead of negative.

After taking all things into careful consideration, we’ve decided exactly how the encryption will work. We’ve listened to all the comments and wishes from you guys and we are now quite happy with the implementation we’re going for. It’s based on free and open source solutions and we’ll release the full source we create for the usage of it. More details will follow later, closer to release.

Until next time!
The Hemlis crew

Hemlis update #2

It’s Friday, the sun is shining and it’s almost time for that after work we’ve been thinking about all week. But before we let our minds wander towards thoughts of golden nectar, here’s another long overdue situation report from the Hemlis team.

ui

Messaging
Your messages are the center of this application and as a result your running conversations are at the top level of the navigation. By using smart defaults, logical flow and no unnecessary settings we are giving the app a clear sense of purpose and focus.

colors

Colors will be used to help you find a conversation easy.

Beyond text messages
Messaging is not only about words. Lots of nuances are lost when you write short messages compared to actually talking with someone. One thing that we have thought of a lot is how people are using emotes to convey the mood or emotion of the message. We like the idea of conveying emotion in messages, but we do not think that endless pages of emotes and stickers makes for a simple and compelling usage. We want to improve this part of texting and are testing different ideas to see if we can take text messaging to the next level. Emotes and stickers should not only make messages look fun, but also have an emotional spectrum used to carry the emotion or mood of the words.

emotes

Initial sketches for one series of emotes with a broad spectrum of emotions.

Don’t get us wrong, your emoji keyboard and usage of  : ) ; ) : /  will of course be possible.

Privacy
One of the main reasons for building Hemlis is to circumvent the mass surveillance that we now know several governments are taking part of.

As part of the ongoing mass surveillance, internet traffic is currently being stored and indexed in massive databases, allowing the data to be analyzed, searched and ultimately read at a later time. This affects everything we do online, from emails to search statistics and even our daily activities on social sites such as Facebook or Twitter.

While we wont be able to provide you with 100% privacy, we believe that we can make your conversations private enough to render mass surveillance ineffective. While most people seem to be concerned about the government reading the contents of private communications very few seem concerned about their ability to build sociograms. Our intent is that by encrypting and then tunneling all messages through the Hemlis network we are making it more difficult for them to data mine or build sociograms from your communications. The surveillance systems can see that you are using Hemlis but they can’t see what takes place inside the network.

IMG_5973

As you can see sending basic messages is now working.

Platforms
As we are still testing different ideas and implementations we are currently sticking to one platform. The initial development, is mostly done on Android, although the Android and the iOS application will be released at the same time.

Some people have suggested that we build Hemlis as a web application to make it cross platform by nature. In theory this might sound like a good idea but as we are aiming for stable and fast clients we have decided to use native code.

As a side note we are currently evaluating the possibility of extending our initial reach on to other platforms. But don’t get your hopes up just yet.

Over and out, lets go for beer!

Hello Heml.is fans! – Hemlis update #1

First off we want to thank all of you that have made Heml.is possible!
The response to our project has been beyond our wildest dreams.

We reached our funding goal much faster than we had anticipated, and while this is awesome, it also created some timing issues. You see we expected to have at least a few weeks to get organized before the funding was over. This is what we in Sweden call an “I-landsproblem”.

We also want to thank those that have given feedback and criticism and we want you to know that we are evaluating multiple solutions and will do our best to find a perfect balance between privacy and usability.

So what have we been up to?
We have answered an enormous amount of mail, tweets and messages. We have tried to reply to every single one that contacted us although a few might have slipped between the cracks. A lot of interesting people contacted us offering help, insight and praise (again we can’t thank you enough) and to our surprise some very impressive names were among them. If we haven’t reached out to you yet we will shortly!

We are currently getting our team organized and are establishing a “plan” of how we will move forward. As mentioned before, the timing is a bit off since it’s summer in Sweden, meaning most people are on vacation, so things are moving slower than we would like.
But rest assured Heml.is is comming!

First bunch of questions from our funders answered

The fundraiser has so far really blown our mind and obviously we have got a lot of questions. We have tried to answer every E-mail, Tweet and Facebook message but it has been impossible to keep up. So here are longer answers to most of the common questions you have asked!

Will it be Open Source?
We have all intentions of opening up the source as much as possible for scrutiny and help! What we really want people to understand however, is that Open Source in itself does not guarantee any privacy or safety. It sure helps with transparency, but technology by itself is not enough. The fundamental benefits of Heml.is will be the app together with our backend infrastructure, which is what really makes the system interesting and secure.

How will the codes, pre-register usernames and “My name in the app” work?
Prior to the release of Heml.is all backers will get an email with their codes and instructions on how to proceed. Note, we do not send this email directly after your payment.

How much will the app cost?
The application will be free and can always send text messages. We will however charge a small fee  (via an in-app purchase) to unlock certain features. Exactly which features is to be determined at a later time. We do this to fund the continuing development and infrastructure. As we said, we will never introduce adds or selling your data to fund the app.

Will the design look like iOS even on Android?
Both apps will have a very similar interface inspired by the lightness and simplicity of iOS7. But we do not plan to do an app that uses strict standard design as we want a design experience that is optimized for messaging.

What kind of users are your target?
In short, everyone. One of the key points of Heml.is is to make the app as user friendly as possible so as to remove the high threshold that is usually associated with encrypted software and services. If your friends wont use it you still can’t send them secure messages.

Can I change my funding amount?
If you make multiple payments with the same email the sum of all your payments will be used as your funding level.

Can I invest in Heml.is?
If you are talking about investing money for equity and/or control. No. To guarantee the safety of our users we can not accept any money “with string attached”. If you want to give us money anyway, we love to have them. For a really large amount we would love to find a cool way to show you how grateful we are.

Does Heml.is save every message on a server?
Messages will only be stored on our end until they have been delivered to the recipient. We might add support for optional expiry times to messages, in which case messages would be stored until they had been delivered or they expire. Whichever comes first.

Why not use OTR?
Even though we love OTR it’s not really feasible to use in a mobile environment. The problem is that OTR needs both parties to be online for a session to start, but a normal phone would not always be online. It would not work at all for offline messages neither.

What about old stored conversations? E.g. if you lose your phone?
We think that there really is no use in storing most messages for very long and are pondering how we can combine this with a user friendly experience. It’s not great to loose things, neither is needing to save them actively, but be sure we are thinking about it.

Will you provide an API and/or allow third party clients?
At this point we don’t see how that would be possible without compromising the security, so for now the answer is no.

How can I be sure I wont be traced when the traffic will pass country borders?
All  traffic will be encrypted from phone to phone so even if it passes  through systems meant to pickup traffic it can’t be read. Not even we  will be able to read your messages even though it passes through our  servers. We will also place the servers in countries well suited for  this. (E.g. Not the US)

Your server only?
Yes! The way to make the system secure is that we can control the infrastructure. Distributing to other servers makes it impossible to give any guarantees about the security. We’ll have audits from trusted third parties on our platforms regularily, in cooperation with our community.

For those interested in a bit of our tech backend infrastructure: We’re building encrypted tunnels/MPLS networks between countries, with anycast ingress/egress points so that your traffic should pass as few borders as possible. Messages will be sent to as close as possible to the recipient, which makes it impossible for agencies like NSA and FRA to see who’s talking to whom. This sort of virtual local network makes Heml.is much more secure than a regular system that can’t avoid border crossings.

Will you release Hemlis on other platforms?
We will focus on getting the application released for IOS and Android. Once we have accomplished that, it’s only natural that we expand to other platforms as well.

Why are you doing this?
Primarily the leak from Edward Snowden made us understand that this is needed. We don’t want a world where everyone is monitored all the time. People have a right to be private and this is our way of enabling them.

Hello world! We are fundraising!

The fundraiser is live and things took of so quickly we didn’t even have the time to write the first blog post!

This is the place where we will keep you updated of our progress with development of the Heml.is messaging platform.

It seams like the first thing we need to do is answer questions. So stay tuned for answers about to the questions most people asked us so far.