From 1a0947f882505a15ab1d9d2d7b51db1cf85ea8b6 Mon Sep 17 00:00:00 2001 From: Robin Krahl Date: Tue, 29 May 2018 21:09:15 +0000 Subject: Add Authenticate to the common traits extended by Device Authenticate is supported by both the Nitrokey Pro and the Nitrokey Storage. Therefore Device should extend it. --- src/device.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/device.rs b/src/device.rs index 7d69df8..cd8a05a 100644 --- a/src/device.rs +++ b/src/device.rs @@ -1,3 +1,4 @@ +use auth::Authenticate; use config::{Config, RawConfig}; use libc; use nitrokey_sys; @@ -148,7 +149,7 @@ pub struct Storage {} /// /// This trait provides the commands that can be executed without authentication and that are /// present on all supported Nitrokey devices. -pub trait Device: GetPasswordSafe + GenerateOtp { +pub trait Device: Authenticate + GetPasswordSafe + GenerateOtp { /// Returns the serial number of the Nitrokey device. The serial number is the string /// representation of a hex number. /// -- cgit v1.2.1