From 8a938be4ffa97490d89206cc1fd079a057cfc65c Mon Sep 17 00:00:00 2001 From: Szczepan Zalega Date: Tue, 26 Jul 2016 10:59:24 +0200 Subject: Manage retry counts of user and admin passwords Signed-off-by: Szczepan Zalega --- include/NitrokeyManager.h | 3 +++ include/stick10_commands.h | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/NitrokeyManager.h b/include/NitrokeyManager.h index 6f4ab75..6588711 100644 --- a/include/NitrokeyManager.h +++ b/include/NitrokeyManager.h @@ -44,6 +44,9 @@ namespace nitrokey { void get_password_safe_slot_status(); + uint8_t get_admin_retry_count(); + uint8_t get_user_retry_count(); + private: NitrokeyManager(); ~NitrokeyManager(); diff --git a/include/stick10_commands.h b/include/stick10_commands.h index c8eda03..31041d0 100644 --- a/include/stick10_commands.h +++ b/include/stick10_commands.h @@ -313,7 +313,7 @@ class GetPasswordRetryCount : Command { bool isValid() const { return true; } std::string dissect() const { std::stringstream ss; - ss << " password_retry_count\t" << password_retry_count << std::endl; + ss << " password_retry_count\t" << (int)password_retry_count << std::endl; return ss.str(); } } __packed; @@ -331,7 +331,7 @@ class GetUserPasswordRetryCount bool isValid() const { return true; } std::string dissect() const { std::stringstream ss; - ss << " password_retry_count\t" << password_retry_count << std::endl; + ss << " password_retry_count\t" << (int)password_retry_count << std::endl; return ss.str(); } } __packed; -- cgit v1.2.1