mrpdaemon / encdroid

Encdroid is an Android application for accessing EncFS volumes on cloud storage
GNU General Public License v3.0
86 stars 20 forks source link

Optional PIN code to lock the app #13

Open mrpdaemon opened 11 years ago

marfl commented 9 years ago

Hi,

I started to work on optional PINs per volume. This fits my own usage better, as I have one EncFS container with notes that is low-security and I use all the time (-> better no PIN) and one EncFS container that I access rarely and would love an extra layer of security for...

Do you like the idea? :)

Cheers, Martin

mrpdaemon commented 9 years ago

Martin, thanks for taking this up - appreciate the help :) Let me know if you have any questions etc. that can help you with the code etc.

Thinking about optional PIN code per-volume, it sounds interesting, but I am not sure how we would reconcile this with the current global setting of "remember passwords". Currently we have one setting that toggles between a) password always required for all volumes and b) passwords are saved upon first entry. Your proposal would require having per-volume settings (which doesn't exist in the UI yet) to toggle between 3 different possibilities 1) no PIN, password always required 2) no PIN, password saved upon first entry 3) PIN protected, password saved upon first entry.

Some issues:

For these reasons, I think an app-wide PIN code that is independent from the password caching setting is a better approach. In fact we can mandate the user to configure a PIN code if they want the app to save passwords.

marfl commented 9 years ago

Hi Mark,

sorry for the late reply (and for all future late replies, I'm juggling many things at once...).

I started this in a very lazy way. This would be version 0.1: if password caching is on and a password would be saved, the user is asked first if he wants to set an optional pin for that volume. Afterwards, the pin can only be changed or deleted by deleting the volume and adding it again or by entering a wrong pin three times (after which both pin and password are deleted by the app).

So this would take care of your first issue? Additionally we can add a few management entries to the per volume context menu, like change pin or set pin if none was set.

About the second issue: yes, I didn't think about this... Are volumes currently only locked when the app is closed?

Cheers, Martin

marfl commented 9 years ago

Hi Mark,

I finished coding my "proposal", you can check it out at my fork at https://github.com/marfl/encdroid . I'll be using it in production now and update my fork if I notice any bugs.

Two open issues with the code (that I'm aware of):