2
3 Comments

End-to-end encryption for web apps

Hey Everyone,

I wanted to get your thoughts on end-to-end encryption. For context, my web app is a React SPA and saves data in the cloud in Firebase (Firestore).

It seems the most common implementation in web apps is encryption in transit via https/SSL/TLS and encryption at rest. That's easy to do – in fact, it’s the default approach in Firebase’s hosting and database.

I am curious about e2ee and trying to learn more about it. In theory, it would be nice to provide an extra layer of privacy and security for users.

When I researched how to implement e2ee, most of the articles I’ve read suggest using a third-party service like Virgil Security or Tanker. (Not surprisingly, many of these articles are written by the companies themselves). But this does not seem like a good solution in terms of extra cost, complexity, and vendor lock-in (is there even a way to move your app off these services?). And most importantly, if their services go down, won’t all users be unable to decrypt their data?

I’ve also read articles that suggest using a user-generated password/key and a client-side encryption library like crypto-js or jsencrypt. This bypasses third-party services but puts the onus on the user to generate and keep the password/key. If the user forgets or losses the password/key, they are locked out permanently with no recourse.

Are there other methods/implementations of e2ee out there that I’m missing? Because both of these options seem poor to me.

If you have e2ee in your app, I would love to learn the specifics of your implementation.

Thanks!

posted to Icon for group Developers
Developers
on November 9, 2020
  1. 1

    I was really excited to see this post, as it's something I'm now facing.
    But very disapointed to see no responses :(

    Did you ever work out a solution @stevenkkim ?

    1. 2

      I haven’t decided to implement e2ee yet, but this post has the most promising info:
      https://www.indiehackers.com/post/why-you-should-use-end-to-end-encryption-a187f085f8

      The author is using LibSodium. If I were to try e2ee this is probably what I would try first.
      https://doc.libsodium.org/

      Hope that helps and good luck!

      1. 1

        Thanks!
        A lot to read through but hopefully I can get my head around it _D

Trending on Indie Hackers
I shipped a productivity SaaS in 30 days as a solo dev — here's what AI actually changed (and what it didn't) User Avatar 141 comments Never hire an SEO Agency for your Saas Startup User Avatar 100 comments A simple way to keep AI automations from making bad decisions User Avatar 67 comments “This contract looked normal - but could cost millions” User Avatar 54 comments Are indie makers actually bad customers? User Avatar 36 comments We automated our business vetting with OpenClaw User Avatar 35 comments