Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add password protection similar like xochitl #15

Closed
torwag opened this issue Aug 31, 2020 · 16 comments
Closed

Add password protection similar like xochitl #15

torwag opened this issue Aug 31, 2020 · 16 comments
Labels
enhancement New feature or request
Milestone

Comments

@torwag
Copy link

torwag commented Aug 31, 2020

Seems to be a bit of a weak spot if you have a password on xochitl to protect important data, but one can start e,g, a shell terminal just without any password.

@Eeems Eeems added the enhancement New feature or request label Aug 31, 2020
@Eeems
Copy link
Collaborator

Eeems commented Aug 31, 2020

I like this! My one concern is that since xochitl needs to be launched for wifi to connect, I'd prefer to hold off on this until we get oxide handling wifi connections. That way you can get unstuck if for some reason you forgot your password, don't have a USB cable, but still have ssh credentials.

@Eeems
Copy link
Collaborator

Eeems commented Aug 31, 2020

So, blocked by #7

@torwag
Copy link
Author

torwag commented Aug 31, 2020

or we keep 1111 as a "hidden" super password ;)... just joking

@Eeems
Copy link
Collaborator

Eeems commented Sep 5, 2020

QSettings xochitlSettings("/home/root/.config/remarkable/xochitl.conf", QSettings::IniFormat);
xochitlSettings.sync();
qDebug() << xochitlSettings.value("Password").toString();

@torwag
Copy link
Author

torwag commented Sep 6, 2020

are you telling me that they keep the login password in the settings completely unencrypted?

@torwag
Copy link
Author

torwag commented Sep 6, 2020

Ohh well, just checked...

@Eeems
Copy link
Collaborator

Eeems commented Sep 6, 2020

@torwag Yup, completely human readable too.

Honestly I'm not too concerned, technically you'd already have root access to the device if you can read it. Which means you already can do whatever you want. As we start to develop apps though, we might start creating attack vectors that would mean we want to do something to secure it better.

@Eeems
Copy link
Collaborator

Eeems commented Sep 7, 2020

So I'm trying to figure out the correct scope here. Here is what I think would be the correct way to do this:

On Install

  • If a password is detected in xochitl configuration remove it and use it for oxide.
  • If a password is ever detected in xochitl's configuration, remove it and update oxide's password.
  • On resume from any application, pause the application and present password screen.

On Uninstall

  • If a password is configured add it to xochitl's configuration.

@torwag and @raisjnn thoughts?

I'm also thinking of mimicking the xochitl password screen.

@torwag
Copy link
Author

torwag commented Sep 8, 2020

That sounds valid to me. I thinking whether some users prefer to have two passwords. One for xochitl one for oxide... like in:
you can play with dads tablet but do not mess with my working notes.
But then, I believe the rM is pretty much a single user device and most will be annoyed to type the password twice.
Should oxide provide a way to change the password, write it back on xochitl and read if from xochitl on a user request? I would found it odd that I have to add a password in xochitl, which works without password, to actually replace my password in oxide.

@Eeems
Copy link
Collaborator

Eeems commented Sep 8, 2020

So maybe on install/first launch prompt to import? Afterwords just leave it alone? And then on uninstall only export if xochitl doesn't have a password configured?

@torwag
Copy link
Author

torwag commented Sep 8, 2020

Best would be if it prompts for import during install and prompt to copy it back to xochitl during uninstall, albeit the uninstall one might be tricky to realize. I just think it would be best if a user knows exactly what is going on with something like passwords.
If the uninstall routine is tricky to handle, I wonder if it would be better to set the password back in xochitl or not
a) For security reasons it would be better. Not exposing xochitl unprotected, if oxide gets removed. Also if oxide takes over the password and deactivates it on xochitl, it should be the responsibility of oxide to undo this step during uninstall.
b) If a user wants to get rid of oxide because he forgot the password or due to some misbehave, well he might be not amused to see suddenly the same password set in xochitl.

Against b) speaks the point that if someone is able to uninstall oxide, he most likely has root access and is able to recover the password easily.

@Eeems
Copy link
Collaborator

Eeems commented Sep 8, 2020

I'm thinking that the best way to handle this would be to have an initial wizard on first launch after install that does the following:

  1. Ask if the user wants to import the password from xochitl (default: yes).
    1. Ask if the user would like the password cleared from xochitl (default: yes).
    2. If the password was cleared, ask if the user would like to restore the password from oxide to xochitl on uninstall (default: yes).
  2. If no password was imported, ask if the user wants to set a password (default: yes).
    1. Prompt for password twice and store to oxide.

@Eeems Eeems added this to the v2.1-beta milestone Sep 16, 2020
@Eeems
Copy link
Collaborator

Eeems commented Jan 2, 2021

2021-01-01T204552 409

@Eeems
Copy link
Collaborator

Eeems commented Jan 2, 2021

2021-01-02T162120 373

@Eeems
Copy link
Collaborator

Eeems commented Jan 3, 2021

Mostly done. I don't have an option to change the PIN, or to not use a PIN. I think the option to change the PIN will just be part of #99. I will need to add the option to not pick a PIN though.

@Eeems
Copy link
Collaborator

Eeems commented Jan 4, 2021

Okay no pin option exists. Closing this. #99 will handle the changing of the pin.

@Eeems Eeems closed this as completed Jan 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants