aboutsummaryrefslogtreecommitdiff
path: root/NitrokeyManager.cc
diff options
context:
space:
mode:
Diffstat (limited to 'NitrokeyManager.cc')
-rw-r--r--NitrokeyManager.cc11
1 files changed, 10 insertions, 1 deletions
diff --git a/NitrokeyManager.cc b/NitrokeyManager.cc
index 2858a18..62687b3 100644
--- a/NitrokeyManager.cc
+++ b/NitrokeyManager.cc
@@ -650,11 +650,20 @@ namespace nitrokey{
//authorization command is supported for versions equal or below:
auto m = std::unordered_map<DeviceModel , int, EnumClassHash>({
{DeviceModel::PRO, 7},
- {DeviceModel::STORAGE, 99},
+ {DeviceModel::STORAGE, 999},
});
return get_minor_firmware_version() <= m[device->get_device_model()];
}
+ bool NitrokeyManager::is_320_OTP_secret_supported(){
+ //authorization command is supported for versions equal or below:
+ auto m = std::unordered_map<DeviceModel , int, EnumClassHash>({
+ {DeviceModel::PRO, 8},
+ {DeviceModel::STORAGE, 999},
+ });
+ return get_minor_firmware_version() >= m[device->get_device_model()];
+ }
+
DeviceModel NitrokeyManager::get_connected_device_model() const{
//FIXME throw if no device is connected or return unknown/unconnected value
if (device == nullptr){