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

Reset lost password #379

Closed
maxtaco opened this issue Apr 16, 2015 · 8 comments
Closed

Reset lost password #379

maxtaco opened this issue Apr 16, 2015 · 8 comments
Assignees
Labels

Comments

@maxtaco
Copy link
Contributor

maxtaco commented Apr 16, 2015

So let's say a user forgets their password. Here are the things that are no longer accessible:

  • Site login via password hash
  • Detkey for web use
  • Device keys encrypted via Local Key Security and not stored into the keychain

The biggest problem I foresee if how to handle device keys behind LKS after the password is reset on another device without LKS (like the phone). Those keys are now not accessible. What should happen is:

  • the devices that use LKS that don't use keychain storage should be deprovisioned (the server has to know where are when to apply this, which it doesn't now).
  • those devices then need to be individually reprovisioned with the password.

In addition to the hairy LKS problem, we of course need to resolve the detkey and password hash problems. That would have to be done by whatever device is resetting the password. BTW, password reset can happen with any provisioned device key. So it is likely to happen on a mobile phone that doesn't have LKS-style key locking.

All of this is a ton of work, it makes the case for keeping secret keys in plaintext. The users who really care will likely have encrypted home directories. Those who don't will be susceptible to their devices being seized and no way to disable file access.

@maxtaco
Copy link
Contributor Author

maxtaco commented Apr 16, 2015

Here's a solution that's not too painful.

For every device in the devices table:

  • Encrypt the scrypt slice of the passphrase with that device's DH subkey, and push this to the server.

We'll need to do this on PW change, and on device provisioning.

Now, a device with an unlocked DH key can change PWs without knowing the previous PW. All it needs to do is to decrypt the encryption above and XOR into the mask. The previous PW is no longer required.

@maxtaco maxtaco modified the milestone: Major feature parity Apr 16, 2015
@maxtaco
Copy link
Contributor Author

maxtaco commented Apr 16, 2015

Also see #184, in which a slightly different solution was proposed. The only question is whether or not to rely on KBFS to recover.

@patrickxb patrickxb added this to the Milestone 1 milestone Apr 30, 2015
@maxtaco
Copy link
Contributor Author

maxtaco commented Jun 4, 2015

Let's not rely on KBFS to recover, since that won't be ready until milestone 2.

@maxtaco
Copy link
Contributor Author

maxtaco commented Jun 7, 2015

Some related issues:

  • keybase/keybase#239 -- Change server to allow passphrase updates
  • Generate update_passphrase_hash signatures proofs#20 -- generate proofs for these updates
  • keybase/keybase#240 -- Store encrypted passphrase masks on server
  • keybase/keybase#242 -- update passphrase XOR masks on passphrase update.
  • keybase/keybase#243 -- store update requests in private merkle chain
  • keybase/keybase#246 -- be more strict and only allow device updates for the current passphrase

@maxtaco maxtaco self-assigned this Jun 15, 2015
@maxtaco
Copy link
Contributor Author

maxtaco commented Jun 27, 2015

Client work needed here:

@patrickxb
Copy link
Contributor

The client side of this should be all finished as of a9cc312

@maxtaco
Copy link
Contributor Author

maxtaco commented Jul 21, 2015

(Except for new detkey uploads, which is blocked on keybase/keybase#260)

@maxtaco
Copy link
Contributor Author

maxtaco commented Aug 11, 2015

Leave keybase/keybase#243 for future work, but close this out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants