diff options
author | Robin Krahl <me@robin-krahl.de> | 2018-04-05 00:36:04 +0200 |
---|---|---|
committer | Szczepan Zalega <szczepan@nitrokey.com> | 2018-04-19 13:18:40 +0200 |
commit | 961c30f7172228bbee84eefa6aaeb24f0c1a35e6 (patch) | |
tree | cd7029ff97f15ef0d0a8ecc9610c197a6bfc9872 /NK_C_API.h | |
parent | e71601bdc6e1df905aca36baa6e8e85096397f80 (diff) | |
download | libnitrokey-961c30f7172228bbee84eefa6aaeb24f0c1a35e6.tar.gz libnitrokey-961c30f7172228bbee84eefa6aaeb24f0c1a35e6.tar.bz2 |
Correct documentation for NK_write_{hotp,totp}_slot
While the actual secret is 20 bytes, the functions accept a hex string.
That means that every byte of the secret is represented by two bytes
(characters) in the hex string. So the argument secret for the
functions NK_write_{hotp,totp}_slot is char[40], not char[20].
Diffstat (limited to 'NK_C_API.h')
-rw-r--r-- | NK_C_API.h | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -212,7 +212,7 @@ extern "C" { * Write HOTP slot data to the device * @param slot_number HOTP slot number, slot_number<3 * @param slot_name char[15](Pro) desired slot name - * @param secret char[20](Pro) 160-bit secret + * @param secret char[40](Pro) 160-bit secret as a hex string * @param hotp_counter uint32_t starting value of HOTP counter * @param use_8_digits should returned codes be 6 (false) or 8 digits (true) * @param use_enter press ENTER key after sending OTP code using double-pressed scroll/num/capslock @@ -229,7 +229,7 @@ extern "C" { * Write TOTP slot data to the device * @param slot_number TOTP slot number, slot_number<15 * @param slot_name char[15](Pro) desired slot name - * @param secret char[20](Pro) 160-bit secret + * @param secret char[40](Pro) 160-bit secret as a hex string * @param time_window uint16_t time window for this TOTP * @param use_8_digits should returned codes be 6 (false) or 8 digits (true) * @param use_enter press ENTER key after sending OTP code using double-pressed scroll/num/capslock |