aboutsummaryrefslogtreecommitdiff
path: root/NitrokeyManager.cc
Commit message (Collapse)AuthorAge
...
* Return OTP codes as strings to make sure they are zero-filled properlySzczepan Zalega2017-04-03
| | | | | | | | | Adjust Python tests for new OTP codes return value Also remove manual 0-filling Fixes #57 Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Fix compilation warningsSzczepan Zalega2017-03-31
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Do not allow to set delays lower than 20 msSzczepan Zalega2017-03-31
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Allow to directly choose loglevelSzczepan Zalega2017-03-29
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Allow to change device commands delays runtimeSzczepan Zalega2017-03-29
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Add function commentSzczepan Zalega2017-03-14
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Allow to check is current device visible to the OSSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Handle enabling update mode on Storage deviceSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Log execution of connect functionSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Build debug-log-free library for increased securitySzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Feature check for 320 bits OTP secretSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Make names more consistentSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Rename is_connected to be more specificSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Get proper card serial for Storage. Get serial as one number.Szczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Return SD card size as get from the deviceSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Handle SD card related functionsSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Handle disconnection while requesting device's statusSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Rename strdup to _strdup under MSVCSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Compiles on MXE, but not working on WindowsSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Adjust for compilation on Visual Studio 2017Szczepan Zalega2017-03-11
| | | | Building works however tests are not. Possibly linking with original hidapi solution would work.
* Mark issues with FIXMESzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Allow users to lock encrypted volumes specificallySzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Pass devices shared pointer to methods instead of refSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Make disconnect thread safe. Check is device actually connected by invoking ↵Szczepan Zalega2017-03-11
| | | | | | its checking method Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Be tread-safe on initializing instanceSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Send current time when checking time synchronizationSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Use const char pointers for C stringsSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Read slot command supportSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Remove support for new authorization protocol for storageSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Throw on not connected device when requesting modelSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Fix firmware version in device statusSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Name fix for firmware version getterSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Comments - fixmeSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Add const qualifier to functionsSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Do not call disconnect on connectSzczepan Zalega2017-03-11
| | | | | | device will be disconnected automatically in its destructor Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Protect concurrent use with lock guardSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Use nullptr instead of NULLSzczepan Zalega2017-03-11
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Helper functions for getting device stateSzczepan Zalega2017-01-11
| | | | | | | | | get status for Pro and Storage check is device connected use make_shared for keeping instance reference fixed accessing active volume flag Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Remove unused inttypesSzczepan Zalega2017-01-09
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Use proper firmware version getter for feature availability checkSzczepan Zalega2016-12-12
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Check maximum OTP secret size in new authorization style commandsSzczepan Zalega2016-12-09
| | | | | | | Authenticate before testing invalid hex strings Remove invalid test for empty string for writing otp slot (empty string allows editing) Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Get major firmware versionSzczepan Zalega2016-12-06
|
* Merge HOTP and TOTP writing commands for 0.8Szczepan Zalega2016-12-03
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Remove length field from send_otp_data packetSzczepan Zalega2016-12-03
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Support longer secrets (40 bytes) for NK Pro 0.8Szczepan Zalega2016-12-03
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Use another OTP writing protocol and test itSzczepan Zalega2016-12-03
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Working support for new NK Pro 0.8 authorization-less formatSzczepan Zalega2016-12-03
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Convinient function for checking if authorization command is supportedSzczepan Zalega2016-12-03
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Rename methods in API to make string return more obviousSzczepan Zalega2016-11-26
| | | | Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
* Document Storage methods in C APISzczepan Zalega2016-11-26
| | | | | | Use uint8_t instead of int where appropriate Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>