diff options
author | Szczepan Zalega <szczepan@nitrokey.com> | 2016-08-05 16:55:15 +0200 |
---|---|---|
committer | Szczepan Zalega <szczepan@nitrokey.com> | 2016-08-05 17:17:58 +0200 |
commit | f3229a742cb5707ea06490126b8f60ac2d4cc120 (patch) | |
tree | 358d8604c7e51086824d086556c27f440d9a2087 /include/stick10_commands.h | |
parent | 263c5d2d34922cf9950aff6f6245e2d8122f4c65 (diff) | |
download | libnitrokey-f3229a742cb5707ea06490126b8f60ac2d4cc120.tar.gz libnitrokey-f3229a742cb5707ea06490126b8f60ac2d4cc120.tar.bz2 |
Slots token ID documentation and payload fields update
Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
Diffstat (limited to 'include/stick10_commands.h')
-rw-r--r-- | include/stick10_commands.h | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/include/stick10_commands.h b/include/stick10_commands.h index b9a249d..ef83747 100644 --- a/include/stick10_commands.h +++ b/include/stick10_commands.h @@ -95,7 +95,15 @@ class WriteToHOTPSlot : Command<CommandID::WRITE_TO_SLOT> { bool use_tokenID : 1; }; }; - uint8_t slot_token_id[13]; + union{ + uint8_t slot_token_id[13]; /** OATH Token Identifier */ + struct{ /** @see https://openauthentication.org/token-specs/ */ + uint8_t omp[2]; + uint8_t tt[2]; + uint8_t mui[8]; + uint8_t keyboard_layout; //disabled feature in nitroapp as of 20160805 + } slot_token_fields; + }; uint64_t slot_counter; bool isValid() const { return !(slot_number & 0xF0); } @@ -136,7 +144,15 @@ class WriteToTOTPSlot : Command<CommandID::WRITE_TO_SLOT> { bool use_tokenID : 1; }; }; - uint8_t slot_token_id[13]; + union{ + uint8_t slot_token_id[13]; /** OATH Token Identifier */ + struct{ /** @see https://openauthentication.org/token-specs/ */ + uint8_t omp[2]; + uint8_t tt[2]; + uint8_t mui[8]; + uint8_t keyboard_layout; //disabled feature in nitroapp as of 20160805 + } slot_token_fields; + }; uint16_t slot_interval; bool isValid() const { return !(slot_number & 0xF0); } //TODO check |