AlephNote
AlephNote copied to clipboard
[Feature request] Notes encryption via GPG
Apologies if this has already been covered before, I couldn't find anything on it. I don't know how many people would use this functionality or if it's really necessary for a note program, just something I know I'd use.
Current behavior:
Although notes may be shared securely with sync sources, the notes themselves are saved remotely in an unencrypted format. As AlephNote is becoming part of my everyday usage, someone gaining access to some data inside could be harmful. Available security additions are free, compatibly licensed, and widely-used.
Requested behavior:
Encrypt notes locally and remotely, only displaying as decrypted when a password is entered. Not all notes would need to be encrypted (e.g. for unimportant info / note sharing) and could be marked as such under the keywords, similar to denoting markdown status. For simplicity, would use a single, master password for all included notes prompted on start / on opening. Declining password entry would just show the GPG-encrypted text.
Encryption format note: I'm suggesting GPG as a widely-held standard whose information can be decrypted by other programs, meaning that you don't have to use AlephNote at all endpoints to view the data contained.
As the program supports both symmetric (password) and asymmetric (key-based), I'd recommend adding password-only support and then move to key support later. The GPG key capability isn't the focus, but a standardized, tested encryption. Key management is non-simple and primarily for communication e.g. to send to a group, you GPG uses multiple keys to encrypt, which isn't necessary with a note program.
Yeah I already had something like this on my roadmap. But now that there's an issue perhaps I will find motivation to work on it :D
My plan for this feature is mostly what you outlined above:
- Mark some (or all) notes as encrypted
- Encrypted notes are saved encrypted locally and on the remote site
- Only show encrypted notes after a password is inserted
- Support different encryption algorithms
I'm not sure why you took GPG as an example. Encryption and decryption would be both on the client side, so I think a public/private-key system would'nt be needed.
I thought more like using an symmetrical algorithm like AES (and perhaps Blowfish, Cast, Twofish, etc in the future).
I did something similar in the past: (PassPad), an encrypted notepad, perhaps I can reuse a bit of code from it
I'm not sure why you took GPG as an example.
For example, on a machine where AlephNote is not available (e.g. Mac, Linux, Android) but I can access my notes I may be able to access my notes if I have a local copy of GPG.
Encryption and decryption would be both on the client side, so I think a public/private-key system would'nt be needed.
My understanding is that GPG supports both symmetrical algorithms as well as public key ones. See: https://www.tutonics.com/2012/11/gpg-encryption-guide-part-4-symmetric.html ... EDIT: you could use
gpg --armor --symmetric --cipher-algo AES256 file.txt
... to generate a text file using standard encryption that could be decrypted by any OS that supports GPG.
Obviously if you know of an open, actively developed, and cross-platform decryption solution (I'm not sure what PassPad used) that would obviously suffice over GPG.
Again, thanks for considering. I don't know if this is something most of your users will want or care about, so I appreciate you entertaining the idea.
Another reference: https://evpo.net/encryptpad/ uses password-based GPG encryption. Unlike AlephNote, it doesn't support sync and doesn't look like that's on the roadmap.
Just a note that it is also possible to use encoding that's not exactly bulletproof, provided there's a clear note about it's status. There are a host of basic text encoding functions that would work fine for 90% of your users, foiling over-the-shoulder or casual attackers (e.g. your parents or a jealous partner).