aboutsummaryrefslogtreecommitdiff
path: root/unittest/misc.py
diff options
context:
space:
mode:
authorSzczepan Zalega <szczepan@nitrokey.com>2019-03-19 08:20:01 +0100
committerSzczepan Zalega <szczepan@nitrokey.com>2019-03-19 08:20:01 +0100
commit07ab86a31ca07c58c58632d9b3845e9782855d0b (patch)
treee9efbc4a60a81bf7bfbe461691a916f9eccb6704 /unittest/misc.py
parent3788515d6546971a3ac6e46769fb8d6e6d24e159 (diff)
parentee79dfdaf06a865cb4c5e26daac1280c9ca09905 (diff)
downloadlibnitrokey-07ab86a31ca07c58c58632d9b3845e9782855d0b.tar.gz
libnitrokey-07ab86a31ca07c58c58632d9b3845e9782855d0b.tar.bz2
Merge branch '154-storage54'pre-v3.5
Add support for the Storage v0.54: - use binary OTP counter - handle 320 bit OTP secret - enable tests for these features Fixes #153 Fixes #154
Diffstat (limited to 'unittest/misc.py')
-rw-r--r--unittest/misc.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/unittest/misc.py b/unittest/misc.py
index 8be915d..c1c197b 100644
--- a/unittest/misc.py
+++ b/unittest/misc.py
@@ -67,4 +67,8 @@ def is_storage(C):
def is_long_OTP_secret_handled(C):
- return is_pro_rtm_08(C) or is_storage(C) and get_devices_firmware_version(C) > 43
+ return is_pro_rtm_08(C) or is_storage(C) and get_devices_firmware_version(C) >= 54
+
+
+def has_binary_counter(C):
+ return is_pro_rtm_07(C) or is_storage(C) and get_devices_firmware_version(C) >= 54