summaryrefslogtreecommitdiff
path: root/docs/design
diff options
context:
space:
mode:
authorelijah <elijah@riseup.net>2013-08-15 01:42:40 -0700
committerelijah <elijah@riseup.net>2013-08-15 01:42:40 -0700
commitc5733cb6f9903d9bd75c04f96568e95085d9c1dc (patch)
tree1c96587d06058465314cfada63d74e77e04cfba7 /docs/design
parentde0fab649ccb881f25b04134285964a1e4da2b1f (diff)
added tech section to docs, moved some of the pages from website and design to this new section.
Diffstat (limited to 'docs/design')
-rw-r--r--docs/design/hard-problems.md111
-rw-r--r--docs/design/limitations.md100
2 files changed, 0 insertions, 211 deletions
diff --git a/docs/design/hard-problems.md b/docs/design/hard-problems.md
deleted file mode 100644
index 4c5c470..0000000
--- a/docs/design/hard-problems.md
+++ /dev/null
@@ -1,111 +0,0 @@
-@title = 'Hard problems in secure communication'
-@nav_title = 'Hard problems'
-@summary = "How LEAP addresses the difficult problems in secure communication"
-
-## The big seven
-
-If you take a survey of interesting initiatives to create more secure communication, a pattern starts to emerge: it seems that any serious attempt to build a system for secure message communication eventually comes up against the following list of seven hard problems.
-
-1. **Authenticity problem**: Public key validation is very difficult for users to manage, but without it you cannot have confidentiality.
-2. **Meta-data problem**: Existing protocols are vulnerable to meta-data analysis, even though meta-data is often much more sensitive than content.
-3. **Asynchronous problem**: For encrypted communication, you must currently choose between forward secrecy or the ability to communicate asynchronously.
-4. **Group problem**: In practice, people work in groups, but public key cryptography doesn't.
-5. **Resource problem**: There are no open protocols to allow users to securely share a resource.
-6. **Availability problem**: People want to smoothly switch devices, and restore their data if they lose a device, but this very difficult to do securely.
-7. **Update problem**: Almost universally, software updates are done in ways that invite attacks and device compromises.
-
-It is possible to safely ignore many of these problems if you don't particularly care about usability or matching the features that users have grown accustomed to with contemporary methods of online communication. But if you do care about usability and features, then you are stuck with finding solutions to these problems.
-
-## Our solutions
-
-In our work, LEAP has tried to directly face down these seven problems. In some cases, we have come up with solid solutions. In other cases, we are moving forward with temporary stop-gap measures and investigating long term solutions. In two cases, we have no current plan for addressing the problems.
-
-### Authenticity problem
-
-The problem:
-
-> Public key validation is very difficult for users to manage, but without it you cannot have confidentiality.
-
-If proper key validation is a precondition for secure communication, but it is too difficult for most users, what hope do we have? We have developed a unique federated system called [Nicknym](/nicknym) that automatically discovers and validates public keys allowing the user to take advantage of public key cryptography without knowing anything about keys or signatures.
-
-### Meta-data problem
-
-The problem:
-
-> Existing protocols are vulnerable to meta-data analysis, even though meta-data is often much more sensitive than content.
-
-As a short term measure, we are integrating opportunistic encrypted transport for email and chat messages when relayed between servers. There are two important aspects to this:
-
-* Relaying servers need a solid way to discover and validate the keys of one another. For this, we are initially using DANE.
-* An attacker must not be able to downgrade the encrypted transport back to cleartext. For this, we are modifying software to ensure that encrypted transport cannot later be downgraded.
-
-This approach is potentially effective against external network observers, but does not protect the meta-data from the service providers themselves.
-
-In the long term, we plan to adopt one of several different schemes for securely routing meta-data. These include:
-
-* Auto-alias-pairs: Each party auto-negotiates aliases for communicating with each other. Behind the scenes, the client then invisibly uses these aliases for subsequent communication. The advantage is that this is backward compatible with existing routing. The disadvantage is that the user's server stores a list of their aliases. As an improvement, you could add the possibility of a third party service to maintain the alias map.
-* Onion-routing-headers: A message from user A to user B is encoded so that the "to" routing information only contains the name of B's server. When B's server receives the message, it unwraps (unencrypts) a supplementary header that contains the actual user "B". Like aliases, this provides no benefit if both users are on the same server. As an improvement, the message could be routed through intermediary servers.
-* Third-party-dropbox: To exchange messages, user A and user B negotiate a unique "dropbox" URL for depositing messages, potentially using a third party. To send a message, user A would post the message to the "dropbox". To receive a message, user B would regularly polls this URL to see if there are new messages.
-* Mixmaster-with-signatures: Messages are bounced through a mixmaster-like set of anonymization relays and then finally delivered to the recipient's server. The user's client only displays the message if it is encrypted, has a valid signature, and the user has previously added the sender to a 'allow list' (perhaps automatically generated from the list of validated public keys).
-
-For a great discussion comparing mix networks and onion routing, see [Tom Ritter's blog post on the topic](https://ritter.vg/blog-mix_and_onion_networks.html).
-
-### Asynchronous problem
-
-The problem:
-
-> For encrypted communication, you must currently choose between forward secrecy or the ability to communicate asynchronously.
-
-With the pace of growth in digital storage and decryption, forward secrecy is increasingly important. Otherwise, any encrypted communication you engage in today is likely to become cleartext communication in the near future.
-
-Because all email is asynchronous, encrypted email does not have forward secrecy. But this is a problem for chat too, because increasingly users demand the ability to send and receive offline chat messages, so we can no longer assume that chat is a synchronous protocol.
-
-In the short term, we are layering forward secret transport for email and chat relay on top of traditional object encryption. This approach is identical to our stop-gap approach for the meta-data problem, with the one addition that relaying servers need the ability to not simply negotiate TLS transport, but to also negotiate forward secret ciphers and to prevent a cipher downgrade.
-
-This approach is potentially effective against external network observers, but does not achieve forward secrecy from the from the service providers themselves.
-
-In the long term, we plan to work with other groups to create new encryption protocol standards that can be both asynchronous and forward secret. The essential idea is to combine both object encryption and session encryption, and to opportunistically upgrade to session encryption when possible, potentially using session keys that are long lived or kept alive until the next synchronous session. Currently, Open Whisper System's TextSecure is the only working example of using long lived session keys for simulating asynchronous communication with forward secrecy that we are aware of.
-
-### Group problem
-
-The problem:
-
-> In practice, people work in groups, but public key cryptography doesn't.
-
-We have a lot of ideas, but we don't have any solutions yet to fix this. Essentially, the question is how to use existing public key primitives to create strong cryptographic groups, where membership and permissions are based on keys and not arbitrary server-maintained access control lists.
-
-Most of the interesting work in this area has been done by companies working on secure file backup/sync/sharing, such as Wuala and Spideroak. Unfortunately, there are not yet any good open protocols or free software packages that can handle group cryptography.
-
-### Resource problem
-
-The problem:
-
-> There are no open protocols to allow users to securely share a resource.
-
-For example, when using secure chat or secure federated social networking, you need some way to link to external media, such as an image, video or file, that has the same security guarantees as the message itself. Embedding this type of resource in the messages themselves is prohibitively inefficient.
-
-We don't have a proposal for how to address this problem. There are a lot of great initiatives working under the banner of read-write-web, but these do not take encryption into account. In many ways, solutions to the resource problem are dependent on solutions to the the group problem.
-
-### Availability problem
-
-The problem:
-
-> People want to smoothly switch devices, and restore their data if they lose a device, but this very difficult to do securely.
-
-Users today demand the ability to access their data on multiple devices and to have piece of mind that there data will not be lost forever if they lose a device. In the free software world, only Firefox has addressed this problem adequately and in a secure way (with Firefox Sync).
-
-At LEAP, we have worked to solve the availability problem with a system we call [Soledad](/soledad) (for Synchronization of Locally Encrypted Documents Among Devices). Soledad gives the client application an encrypted, synchronized, searchable document database. All data is client encrypted, both when it is stored on the local device and synced with the cloud. As far as we know, there is nothing else like it, either in the free software or commercial world.
-
-### Update problem
-
-The problem:
-
-> Almost universally, software updates are done in ways that invite attacks and device compromises.
-
-The sad state of update security is especially troublesome because update attacks can now be purchased off the shelf by repressive regimes. The problem of software update is particular bad on desktop platforms. In the case of mobile and HTML5 apps, the vulnerabilities are not as dire, but the issues are also harder to fix.
-
-To address the update problem, LEAP is adopting a unique update system called Thandy from the Tor project. Thandy is complex to manage, but is very effective at preventing known update attacks.
-
-Thandy, and the related [TUF](https://updateframework.com), are designed to address the many [security vulnerabilities in existing software update systems](https://updateframework.com/projects/project/wiki/Docs/Security). In one example, other update systems suffer from an inability of the client to confirm that they have the most up-to-date copy, thus opening a huge vulnerability where the attacker simply waits for a security upgrade, prevents the upgrade, and launches an attack exploiting the vulnerability that should have just been fixed. Thandy/TUF provides a unique mechanism for distributing and verifying updates so that no client device will install the wrong update or miss an update without knowing it.
-
-Related to the update problem is the backdoor problem: how do you know that an update does not have a backdoor added by the software developers themselves? Probably the best approach is that taken by [Gitian](https://gitian.org/), which provides a "deterministic build process to allow multiple builders to create identical binaries". We hope to adopt Gitian in the future.
diff --git a/docs/design/limitations.md b/docs/design/limitations.md
deleted file mode 100644
index e61d1c3..0000000
--- a/docs/design/limitations.md
+++ /dev/null
@@ -1,100 +0,0 @@
-@title = 'Known Limitations'
-@toc = true
-@summary = 'Known limitations, issues, and security problems with the LEAP platform'
-
-Herein lie the know limitations, issues, and security problems of the LEAP platform.
-
-Provider problems
-==========================================
-
-Meta-data can be recorded by the provider
--------------------------------------------------
-
-Currently, the service provider is able to observe the meta-data routing information of messages in transit of their own users (email and chat). This information is not stored, but a nefarious provider could observe this information in transit and record it.
-
-We have several plans to eliminate this, but these are not part of the initial release.
-
-The provider can undermine the security of the web application
--------------------------------------------------------------------------
-
-Both the client and the web application use something called SRP (Secure Remote Password) to prevent the server from ever seeing a cleartext copy of the password. This is in contrast to normal password systems, where the password is hashed on the server, so the server could record a copy of the password when it is initially set.
-
-However, because all the javascript cryptographic libraries used by the user's web browser to perform the SRP negotiation are loaded from the provider's server, a nefarious or compromised provider could give the user's browser bad libraries that secretly sent a cleartext copy of the user's password.
-
-There are two methods that can be used to prevent this:
-
-* We could offer the option of first visiting a third party website that loads the authentication libraries before redirecting to the provider's website. Unfortunately, this user experience is a bit awkward.
-* We could allow providers the option of not allowing authentication or signup through the webapp. Instead, the client could be distributed with an HTML page with all the javascript needed to authenticate. When the user wants to authenticate, the client loads this page in a web browser, authenticates with the provider's API, and then redirects to the actual website.
-
-It is not either or, we could support both options.
-
-The details for both of these are bit more tricky than in these simple descriptions, because of the need to work around the single origin policy, but it is still entirely possible to do this securely (using either CORS or PostMessage).
-
-Still possible to brute force the password verifier
------------------------------------------------------------------
-
-SRP (Secure Remote Password) does not store a hash of the password in the provider's user database, but instead a password verifier. However, if an attacker gains access to the database of password verifiers (plus salts) they can perform a brute force attack similar to a normal attack on a database of password hashes. The attack in the case of SRP is more difficult, since there is more cryptographic work involved, but it is still possible.
-
-To mitigate exposure of the password verifiers, we plan to separate them out into a separate database with only a separate single-purpose authentication API daemon granted access.
-
-The provider can observe VPN traffic
---------------------------------------------------
-
-The "Encrypted Internet" feature of LEAP currently works using OpenVPN secure tunnel to proxy all network traffic to a gateway operated by the provider. Once the traffic exits this gateway, it is cleartext (unless otherwise encrypted on the client, e.g. HTTPS) and could be observed and record by the provider, or any network observer able to monitor all traffic into and out of the gateway.
-
-This limitation is mitigated by having the LEAP client authenticate with the VPN gateway using semi-anonymous or anonymous client certificates. A nefarious or compromised provider could attempt to record the moment that a user fetches a new client certificate, and record the IP address or authentication credentials of the user at that time.
-
-In the future, we plan to remove this vulnerability in two ways:
-
-* Allow the client to fetch new client certificates using blind signatures, so that there is no way for the provider to associate user with certificate, but we can also ensure that only valid users get client certificates.
-* Use Tor as an alternate and optional transport for "Encrypted Internet". From the stand point of the user, it would work the same (using perhaps tun socks proxy and dnscrypt-proxy). This option would be slower and not support UDP traffic, but it would be much more secure. The Tor project prefers that every application that uses Tor be specifically designed for Tor so that it does not leak information in other ways. Using Tor as a default route like we do with OpenVPN would violate this, but would be more user friendly.
-
-User problems
-=================================
-
-A compromised device is a sad device
-----------------------------------------------
-
-The LEAP client tries to minimize attacks related to physical access to the device. In particular, we try to be very resistant to offline attacks, where an attacker has captured the user's device while the LEAP client does not have an open session. For example, locally stored data is kept in an encrypted database that is only unlocked when the user authenticates with the application.
-
-However, if an attacker gains access to the device, and then the device is returned to the user, they can do all kinds of nasty things, like install a keylogger that captures every keystroke.
-
-This vulnerability is true of all software, not just LEAP, but it is worth noting.
-
-Passwords are never going to be very good
----------------------------------------------------
-
-LEAP relies on the user's password to unlock access to the user's client encrypted data storage. It does this the right way, using a solid KDF, but passwords are pretty limited and offer marginal security if an attacker gains offline access to the user's encrypted storage (for example, if they obtain the device).
-
-In the future, we hope to add support for OpenPGP smart cards in order to overcome many of the problems associated with passwords.
-
-Design problems
-============================================
-
-Enumeration of usernames
------------------------------
-
-The system LEAP uses to validate the public keys of users is inherently vulnerable to an attacker enumerating usernames. Because requests for public keys may be proxy'ed through other providers, there is no good method of preventing an attacker from launching many queries for public keys and eventually mapping most of the usernames.
-
-This is unfortunate, but this is also a problem with all other such systems of key discovery and validation (i.e. DANE). For now, we consider this to be an acceptable compromise.
-
-Much trust is placed in LEAP
--------------------------------------------
-
-In order to shield the service provider from being pressured by a host government or criminal organization to add a backdoor into the client, the model with the LEAP platform is that the client is normally downloaded from the leap.se website and subsequent updates are signed by LEAP developers.
-
-This is good for the provider, but not so good for LEAP, since this system could potentially place pressure on LEAP. Because LEAP does not have a provider-customer relationship with any user, LEAP cannot target compromised applications for particular users. LEAP could, however, introduce a backdoor in the client used by all users.
-
-To prevent this, we plan to adopt [Gitian](https://gitian.org/) or something equivalent. Gitian allows for a way to standardize the entire build environment and build process in order for third parties to be able to verify that the released binary application does indeed match the correct source code.
-
-External authority problems
-=================================================
-
-Certificate authorities considered dangerous
----------------------------------------------------
-
-The long term goal with LEAP is to entirely rid ourselves of reliance on the x.509 certificate authority system. However, there are a few places where the platform still relies on it:
-
-* When the client first validates a new provider, it will assume the provider's TLS connection is valid if presented with a server certificate signed by a commercial CA recognized by the operating system.
-* When nicknym discovers new public keys for users, it uses a TLS connection validated by a commercial CA recognized by the operating system.
-* Currently, the web application does not get deployed with any other TLS validation than the standard commercial CA method. Eventually, we plan to support [DNS-based Authentication of Named Entities (DANE)](https://datatracker.ietf.org/wg/dane/), [Trust Assertions for Certificate Keys (TACK)](http://tack.io/), or [Public Key Pinning Extension for HTTP](https://datatracker.ietf.org/doc/draft-ietf-websec-key-pinning/).