diff options
author | Robin Krahl <me@robin-krahl.de> | 2018-12-11 23:51:01 +0100 |
---|---|---|
committer | Daniel Mueller <deso@posteo.net> | 2018-12-17 07:52:13 -0800 |
commit | 4d314264a897c474c12e626a2be36b75dc57f5c9 (patch) | |
tree | 11385b55f271a2b95d2d632ad1a2107180be5c3a /argparse/vagga.yaml | |
parent | 986ad2f782cf944990e4eda8bf88ea1821233302 (diff) | |
download | nitrocli-4d314264a897c474c12e626a2be36b75dc57f5c9.tar.gz nitrocli-4d314264a897c474c12e626a2be36b75dc57f5c9.tar.bz2 |
Port the open and close commands to libnitrokey
This patch removes the raw hidapi implementations of the Enable
Encrypted Volume and Disable Encrypted Volume commands and replaces them
with the methods enable_encrypted_volume and disable_encrypted_volume of
the Storage struct provided by the nitrokey trait.
To provide some context to the error messages, the errors are wrapped
using the map_err method of the Result enum and the get_error function
that combines a nitrokey error code and a string into a nitrocli error.
It would be more idiomatic to define a conversion from a nitrokey error
to a nitrocli error, but then we would lose information about the
context of the error.
Diffstat (limited to 'argparse/vagga.yaml')
0 files changed, 0 insertions, 0 deletions