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

added CSV import functionality #6

Merged
merged 1 commit into from
Apr 26, 2017
Merged

added CSV import functionality #6

merged 1 commit into from
Apr 26, 2017

Conversation

8go
Copy link
Owner

@8go 8go commented Apr 26, 2017

Added the functionality to import passwords from a CSV file

  • This allows to migrate passwords from other password managers to TrezorPass. E.g. One could export his passwords from KeePass into a CSV file. Then modify this CSV via scripts or by hand such that the resulting CSV file corresponds to the TrezorPass CSV import format. This modified CSV can then be imported into TrezorPass.

  • This new functionality reads a properly formated CSV file from disk and adds its contents to the current entries.

  • Import format in CSV should be : group, key, password, comments

  • There is no special error checking, so be extra careful.

  • Make a backup first. As a matter of fact, TrezorPass automatically makes a backup for you before performing a CSV import.

  • Entries from CSV will be added to existing pwdb. If this is not desired create an empty pwdb file first.

  • GroupNames are unique, so if a groupname exists then key-password-comments tuples are added to the already existing group. If a group name does not exist, a new group is created and the key-password-comments tuples are added to the newly created group.

  • Keys are not unique. So key-password-comments are always added. If a key with a given name existed before and the CSV file contains a key with the same name, then the key-password-comments is added and after the import the given group has 2 keys with the same name. Both keys exist then, the old from before the import, and the new one from the import.

  • Examples of valid CSV file format: Some example lines

First Bank account,login,myloginname,	# no comment
foo@gmail.com,2-factor-authentication key,abcdef12345678,seed to regenerate 2FA codes
foo@gmail.com,recovery phrase,"passwd with 2 commas , ,",	
foo@gmail.com,large multi-line comments,,"first line, some comma, 
second line"
phone,PIN,1234,my phone PIN

@8go 8go merged commit a93df19 into master Apr 26, 2017
@8go 8go changed the title added CVS import functionality added CSV import functionality Apr 26, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant