diff options
author | Robin Krahl <robin.krahl@ireas.org> | 2020-09-08 18:23:30 +0200 |
---|---|---|
committer | Daniel Mueller <deso@posteo.net> | 2021-01-10 17:37:57 -0800 |
commit | 9593dfd03a6ca085d649ca090b6ec5e5f0104e78 (patch) | |
tree | cef944516af5c92561c2610f9c8a21776e95cac9 /doc/config.example.toml | |
parent | 9975f8810399d5e535f2e2fd62b4dc56b313f955 (diff) | |
download | nitrocli-9593dfd03a6ca085d649ca090b6ec5e5f0104e78.tar.gz nitrocli-9593dfd03a6ca085d649ca090b6ec5e5f0104e78.tar.bz2 |
Add --usb-path option to select device
This patch adds the --usb-path option as an additional way to filter the
Nitrokey device to connect to. While the serial number is a better
identifier in theory, the Nitrokey Storage devices do not send their
serial number in the USB device descriptor. Having the --usb-path
options allows users to select one of multiple Nitrokey Storage devices.
While we could directly call the nitrokey::Manager::connect_path
function with the specified path, we integrate the --usb-path option
into the existing find_device function for consistent error messages and
to avoid having to duplicate the --model and --serial-number checks.
Diffstat (limited to 'doc/config.example.toml')
-rw-r--r-- | doc/config.example.toml | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/doc/config.example.toml b/doc/config.example.toml index eefdfa0..82e0ece 100644 --- a/doc/config.example.toml +++ b/doc/config.example.toml @@ -7,6 +7,8 @@ model = "pro" # The serial number of the device to connect to (list of strings, default: # empty). serial_numbers = ["0xf00baa", "deadbeef"] +# The USB path of the device to connect to (string, default: empty). +usb_path = "004:001:00" # Do not cache secrets (boolean, default: false). no_cache = true # The log level (integer, default: 0). |