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

Save passwords and account information in an encrypted form #6

Closed
juniorz opened this issue Sep 15, 2015 · 7 comments
Closed

Save passwords and account information in an encrypted form #6

juniorz opened this issue Sep 15, 2015 · 7 comments
Assignees
Labels

Comments

@juniorz
Copy link
Member

juniorz commented Sep 15, 2015

Should we really save passwords? Is this only interesting on a multi-account scenario?

@olabini
Copy link
Contributor

olabini commented Sep 16, 2015

Well, we probably want to do something to save configuration data, including things like TLS fingerprints and other stuff like it - basically, I think the whole config file should optionally be encrypted so you can save all your account information in one place, and then not have to enter all the info every time. xmpp-client already saves passwords, but in a plain text file.

@olabini olabini changed the title Figure out how to save passwords Save passwords and account information in an encrypted form Sep 16, 2015
@tdruiva
Copy link
Contributor

tdruiva commented Sep 18, 2015

Jitsi use masterpassword approach.
For xmmp-client I use to type the pass of each account, but with Jitsi I only need to do it one time.
Apparently they are using AES algorithm to encrypt this info.

@olabini olabini modified the milestone: Later Oct 7, 2015
@olabini
Copy link
Contributor

olabini commented Oct 19, 2015

When we do this, we should use something like bcrypt/scrypt to make the unlocking of the file take 0.5-1s - we can then cache the bcrypted value in memory for the duration of the program so we don't have to redo it every time we save the config file.

We might also give the user the possibility of turning off the caching and always ask for the password when reading or saving the file.

@olabini
Copy link
Contributor

olabini commented Oct 24, 2015

We should use scrypt for this. We save the parameters first in the file and then use scrypt to generate a good AES-128 or 256 key and encrypt the whole file.

@olabini
Copy link
Contributor

olabini commented Oct 24, 2015

BTW, that Jitsi thing is a bit scary - fixed salt, fixed amount of iterations and it uses ECB. We should definitely not follow that pattern.

@olabini olabini self-assigned this Oct 27, 2015
@olabini
Copy link
Contributor

olabini commented Oct 27, 2015

OK, working on this today. These are the sub tasks:

  • Decrypt existing configuration file
  • Encrypt existing configuration file
  • Ask for password to load config file (GUI)
  • Ask for password to load config file (CLI)
  • Ask whether config file should be encrypted when creating (GUI)
  • Ask whether config file should be encrypted when creating (CLI)

@olabini
Copy link
Contributor

olabini commented Oct 28, 2015

This has been fixed. The only thing you can't do is set up encrypted storage using the CLI, and since the CLI can't store the account passwords either, I tihnk that's fine for now.

@olabini olabini closed this as completed Oct 28, 2015
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

3 participants