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

avoid a "dump" panic on card ciphers #29

Merged
merged 1 commit into from
Jul 26, 2021
Merged

avoid a "dump" panic on card ciphers #29

merged 1 commit into from
Jul 26, 2021

Conversation

mvdan
Copy link
Owner

@mvdan mvdan commented Jul 24, 2021

(see commit message)

Ciphers storing a credit or debit card don't have a "Login" object,
so we would panic in the "dump" command when attempting to print login
fields such as the URL or password.

For now, simply filter ciphers depending on whether Login exists. We
should probably improve this command in the future, but for now at least
it doesn't panic.

While at it, stop using tabwriter for it. First, if one has hundreds of
passwords stored, the command would seem to hang for tens of seconds,
decrypting all secrets before printing the whole aligned table. Now, it
prints each line as it goes. Not aligned anymore, but that's not a
terrible thing either - some URLs can be very long and mess up the output.

We also start obeying ^C properly in both the "dump" command and when
reading a password. Before the fix, both would simply keep going until
they were finished.

Finally, update deps.

Fixes #28.
@mvdan mvdan mentioned this pull request Jul 24, 2021
@mvdan
Copy link
Owner Author

mvdan commented Jul 24, 2021

Unclear why CI started failing, it's possible that the bitwarden APIs changed a bit, or the secret setup prevents PR builds from working.

@mvdan mvdan merged commit 9f9dffe into master Jul 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant