gnuk/gnuk.git
3 months agoFix bn.c. master
NIIBE Yutaka [Tue, 18 Jun 2019 02:10:33 +0000 (11:10 +0900)]
Fix bn.c.

5 months agotests: Power off the reader at the end of test suite.
NIIBE Yutaka [Tue, 9 Apr 2019 01:55:38 +0000 (10:55 +0900)]
tests: Power off the reader at the end of test suite.

5 months agotests: Fix time extension S block responce to TPDU reader.
NIIBE Yutaka [Thu, 4 Apr 2019 06:44:58 +0000 (15:44 +0900)]
tests: Fix time extension S block responce to TPDU reader.

5 months agotests: Fix timer extension handling.
NIIBE Yutaka [Wed, 3 Apr 2019 08:03:35 +0000 (17:03 +0900)]
tests: Fix timer extension handling.

5 months agotests: Support keygen by OpenPGP card.
NIIBE Yutaka [Wed, 3 Apr 2019 08:02:00 +0000 (17:02 +0900)]
tests: Support keygen by OpenPGP card.

5 months agotests: KDF feature is Gnuk only.
NIIBE Yutaka [Wed, 3 Apr 2019 08:01:11 +0000 (17:01 +0900)]
tests: KDF feature is Gnuk only.

5 months agotests: Skip Gnuk only tests.
NIIBE Yutaka [Wed, 3 Apr 2019 05:51:32 +0000 (14:51 +0900)]
tests: Skip Gnuk only tests.

5 months agotests: factor out tests into classes.
NIIBE Yutaka [Wed, 3 Apr 2019 04:49:55 +0000 (13:49 +0900)]
tests: factor out tests into classes.

5 months agotests: Skip Gnuk only test.
NIIBE Yutaka [Wed, 3 Apr 2019 00:45:06 +0000 (09:45 +0900)]
tests: Skip Gnuk only test.

5 months agoAdd OpenPGP card v3.3 card factory reset setup.
NIIBE Yutaka [Tue, 2 Apr 2019 08:29:56 +0000 (17:29 +0900)]
Add OpenPGP card v3.3 card factory reset setup.

5 months agotests: Use 3.3V for the card.
NIIBE Yutaka [Tue, 2 Apr 2019 04:19:56 +0000 (13:19 +0900)]
tests: Use 3.3V for the card.

6 months agoVersion 1.2.14. release/1.2.14
NIIBE Yutaka [Mon, 4 Mar 2019 02:34:17 +0000 (11:34 +0900)]
Version 1.2.14.

6 months agoAdd count for tool/gnuk_get_random.py.
NIIBE Yutaka [Sun, 24 Feb 2019 06:12:12 +0000 (15:12 +0900)]
Add count for tool/gnuk_get_random.py.

6 months agoFix timeout initialization at receiving command.
NIIBE Yutaka [Sun, 24 Feb 2019 04:54:38 +0000 (13:54 +0900)]
Fix timeout initialization at receiving command.

6 months agoFix for ack button.
NIIBE Yutaka [Sun, 24 Feb 2019 04:04:28 +0000 (13:04 +0900)]
Fix for ack button.

6 months agoChange for firmware upgrade and ack-button.
NIIBE Yutaka [Fri, 22 Feb 2019 10:53:52 +0000 (19:53 +0900)]
Change for firmware upgrade and ack-button.

6 months agoChange the constant values for eventflag.
NIIBE Yutaka [Fri, 22 Feb 2019 05:26:46 +0000 (14:26 +0900)]
Change the constant values for eventflag.

I misunderstood semantics of __builtin_ffs function which prefers
less significant 1-bit.

6 months agoImplement timeout for the user interaction.
NIIBE Yutaka [Fri, 22 Feb 2019 00:21:11 +0000 (09:21 +0900)]
Implement timeout for the user interaction.

6 months agoAdd GnuPG e.V.'s VID:PID.
NIIBE Yutaka [Thu, 21 Feb 2019 02:39:37 +0000 (11:39 +0900)]
Add GnuPG e.V.'s VID:PID.

8 months agoComment in the commit log fix.
NIIBE Yutaka [Mon, 31 Dec 2018 10:07:33 +0000 (19:07 +0900)]
Comment in the commit log fix.

In the commit of e760d5b78061dbd99bdc15a7f5a5b9321905e535, I wrote
wrong comment.  The nvic_system_reset function lets MCU go through by
the vectors at 0x08000000.  Thanks to Peter Lebbing to confirm this
fact.

8 months agoVersion 1.2.13. release/1.2.13
NIIBE Yutaka [Wed, 26 Dec 2018 05:01:08 +0000 (14:01 +0900)]
Version 1.2.13.

8 months agoAdd ChangeLog entry for Peter's changes.
NIIBE Yutaka [Wed, 26 Dec 2018 04:38:32 +0000 (13:38 +0900)]
Add ChangeLog entry for Peter's changes.

Note that the call of nvic_system_reset from device_initialize_once
uses the old RESET vector.

8 months agoFix make {,dist}clean
Peter Lebbing [Sat, 22 Dec 2018 13:09:28 +0000 (14:09 +0100)]
Fix make {,dist}clean

8 months agoDFU fix: Copy initial MSP, reset after protect
Peter Lebbing [Fri, 21 Dec 2018 16:08:32 +0000 (17:08 +0100)]
DFU fix: Copy initial MSP, reset after protect

9 months agoAdd ChangeLog entries for Peter's changes.
NIIBE Yutaka [Fri, 21 Dec 2018 01:30:16 +0000 (10:30 +0900)]
Add ChangeLog entries for Peter's changes.

9 months agoDFU support: overwrite DFU with SYS and protect flash
Peter Lebbing [Tue, 18 Dec 2018 14:52:42 +0000 (15:52 +0100)]
DFU support: overwrite DFU with SYS and protect flash

9 months agoBuild standalone SYS
Peter Lebbing [Tue, 18 Dec 2018 14:44:07 +0000 (15:44 +0100)]
Build standalone SYS

9 months agoAdd ORIGIN_REAL, emit more configure variables
Peter Lebbing [Tue, 18 Dec 2018 14:23:18 +0000 (15:23 +0100)]
Add ORIGIN_REAL, emit more configure variables

ORIGIN{,_REAL} is made available to C and USE_DFU is made available to
make.

9 months agoUse different ORIGIN for DFU on Maple Mini
Peter Lebbing [Tue, 18 Dec 2018 14:04:21 +0000 (15:04 +0100)]
Use different ORIGIN for DFU on Maple Mini

9 months agoUpdate Chopstx to 1.13.
NIIBE Yutaka [Thu, 20 Dec 2018 05:02:30 +0000 (14:02 +0900)]
Update Chopstx to 1.13.

9 months agoFix order of EV_* for CCID thread.
NIIBE Yutaka [Thu, 6 Dec 2018 23:35:27 +0000 (08:35 +0900)]
Fix order of EV_* for CCID thread.

Since openpgp thread has lower priority than CCID thread, there is no
case where two consecutive messages EV_EXEC_ACK_REQUIRED and
EV_EXEC_FINISHED are handled simultaneously (openpgp thread needs to
work some time to send EV_EXEC_FINISHED, after sending
EV_EXEC_ACK_REQUIRED).  But just in case, when there are two messages
at once, EV_EXEC_ACK_REQUIRED should been handled before
EV_EXEC_FINISHED.

9 months agoReally fix the last race condition.
NIIBE Yutaka [Thu, 6 Dec 2018 03:09:42 +0000 (12:09 +0900)]
Really fix the last race condition.

Fixes the commit of fc36773.

9 months agoSupport Ack button for firmware update.
NIIBE Yutaka [Wed, 5 Dec 2018 06:36:16 +0000 (15:36 +0900)]
Support Ack button for firmware update.

9 months agoFix for UIF DO.
NIIBE Yutaka [Tue, 4 Dec 2018 08:11:43 +0000 (17:11 +0900)]
Fix for UIF DO.

9 months agoFix hopefully the last race condition for tx_busy handling.
NIIBE Yutaka [Sat, 1 Dec 2018 14:28:19 +0000 (23:28 +0900)]
Fix hopefully the last race condition for tx_busy handling.

9 months agoVersion 1.2.12. release/1.2.12
NIIBE Yutaka [Sun, 25 Nov 2018 05:37:09 +0000 (14:37 +0900)]
Version 1.2.12.

10 months agoFix another race condition around ack button and usb communication.
NIIBE Yutaka [Wed, 21 Nov 2018 05:56:56 +0000 (14:56 +0900)]
Fix another race condition around ack button and usb communication.

10 months agoUnique 96-bit looks different on GD32F103.
NIIBE Yutaka [Sat, 17 Nov 2018 10:01:59 +0000 (19:01 +0900)]
Unique 96-bit looks different on GD32F103.

Depending on MHZ, we change how we get the 96-bits.

10 months agoVersion 1.2.11. release/1.2.11
NIIBE Yutaka [Mon, 12 Nov 2018 05:44:18 +0000 (14:44 +0900)]
Version 1.2.11.

10 months agoAlways enable ACKBTN support.
NIIBE Yutaka [Mon, 12 Nov 2018 05:25:22 +0000 (14:25 +0900)]
Always enable ACKBTN support.

10 months agoFix tool/kdf_calc.py.
NIIBE Yutaka [Fri, 9 Nov 2018 11:52:15 +0000 (20:52 +0900)]
Fix tool/kdf_calc.py.

10 months agoFix synchronous sending.
NIIBE Yutaka [Fri, 9 Nov 2018 11:50:35 +0000 (20:50 +0900)]
Fix synchronous sending.

10 months agoFix cmd_pso and cmd_internal_authenticate.
NIIBE Yutaka [Fri, 9 Nov 2018 09:57:51 +0000 (18:57 +0900)]
Fix cmd_pso and cmd_internal_authenticate.

10 months agoSending from Gnuk Token is now synchronous.
NIIBE Yutaka [Fri, 9 Nov 2018 07:38:14 +0000 (16:38 +0900)]
Sending from Gnuk Token is now synchronous.

10 months agoMinor fixes for usb-ccid.c.
NIIBE Yutaka [Fri, 9 Nov 2018 06:23:33 +0000 (15:23 +0900)]
Minor fixes for usb-ccid.c.

10 months agoRemove unused CCID_STATE_RECEIVE and CCID_STATE_SEND state.
NIIBE Yutaka [Fri, 9 Nov 2018 03:52:21 +0000 (12:52 +0900)]
Remove unused CCID_STATE_RECEIVE and CCID_STATE_SEND state.

It was used before when Gnuk uses extended APDU exchange (7 years ago).

10 months agoIt also works with Python3.
NIIBE Yutaka [Mon, 22 Oct 2018 05:26:21 +0000 (14:26 +0900)]
It also works with Python3.

11 months agoFix UIF interaction.
NIIBE Yutaka [Fri, 12 Oct 2018 02:42:34 +0000 (11:42 +0900)]
Fix UIF interaction.

11 months agoTweak stack size.
NIIBE Yutaka [Tue, 2 Oct 2018 10:10:56 +0000 (19:10 +0900)]
Tweak stack size.

11 months agodoc: Fix by Fabio Utzig for scdaemon.
NIIBE Yutaka [Tue, 2 Oct 2018 04:31:03 +0000 (13:31 +0900)]
doc: Fix by Fabio Utzig for scdaemon.

11 months agoUpdate Chopstx to 1.11.
NIIBE Yutaka [Tue, 2 Oct 2018 04:30:51 +0000 (13:30 +0900)]
Update Chopstx to 1.11.

11 months agoUI change for LED blink.
NIIBE Yutaka [Mon, 1 Oct 2018 05:36:56 +0000 (14:36 +0900)]
UI change for LED blink.

11 months agoAllow parallel execution waiting ACK.
NIIBE Yutaka [Mon, 1 Oct 2018 05:06:31 +0000 (14:06 +0900)]
Allow parallel execution waiting ACK.

11 months agoFix UIF DO handling.
NIIBE Yutaka [Thu, 27 Sep 2018 13:29:49 +0000 (22:29 +0900)]
Fix UIF DO handling.

11 months agoFix rw_uif.
NIIBE Yutaka [Thu, 27 Sep 2018 07:38:07 +0000 (16:38 +0900)]
Fix rw_uif.

11 months agoAdd UIF Data Object support for Acknowledge Button.
NIIBE Yutaka [Thu, 27 Sep 2018 06:02:43 +0000 (15:02 +0900)]
Add UIF Data Object support for Acknowledge Button.

11 months agoBlink LED rapidly when asking ACK from user.
NIIBE Yutaka [Thu, 27 Sep 2018 03:58:06 +0000 (12:58 +0900)]
Blink LED rapidly when asking ACK from user.

11 months agoFix for ack button driver and configuration.
NIIBE Yutaka [Thu, 27 Sep 2018 02:29:46 +0000 (11:29 +0900)]
Fix for ack button driver and configuration.

11 months agoRemove ack-button.c to use the driver in Chopstx.
NIIBE Yutaka [Thu, 27 Sep 2018 01:46:18 +0000 (10:46 +0900)]
Remove ack-button.c to use the driver in Chopstx.

11 months agoExperimental Ack-button feature added (not yet finished).
NIIBE Yutaka [Wed, 26 Sep 2018 22:30:17 +0000 (07:30 +0900)]
Experimental Ack-button feature added (not yet finished).

11 months agoDoc fix for udev rules (use ATTR instead of ATTRS).
NIIBE Yutaka [Wed, 26 Sep 2018 04:57:42 +0000 (13:57 +0900)]
Doc fix for udev rules (use ATTR instead of ATTRS).

11 months agoUpdate for new Chopstx API.
NIIBE Yutaka [Wed, 26 Sep 2018 04:24:19 +0000 (13:24 +0900)]
Update for new Chopstx API.

12 months agoFix README about -no-vidpid file name.
NIIBE Yutaka [Thu, 23 Aug 2018 05:30:07 +0000 (14:30 +0900)]
Fix README about -no-vidpid file name.

13 months agoFix for GCC 7.
NIIBE Yutaka [Mon, 20 Aug 2018 07:07:07 +0000 (16:07 +0900)]
Fix for GCC 7.

14 months agoAdd ChangeLog entry.
NIIBE Yutaka [Fri, 13 Jul 2018 07:28:29 +0000 (16:28 +0900)]
Add ChangeLog entry.

14 months agoFix typo
Szczepan Zalega [Wed, 4 Jul 2018 12:16:37 +0000 (14:16 +0200)]
Fix typo

Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
14 months agoCatch exception, when no KDF data is found
Szczepan Zalega [Wed, 4 Jul 2018 12:14:07 +0000 (14:14 +0200)]
Catch exception, when no KDF data is found

While updating from GNUK 1.2.6, upgrade_by_passwd.py script shows
exception about not found referenced data:
  File "./upgrade_by_passwd.py", line 55, in main
    kdf_data = gnuk.cmd_get_data(0x00, 0xf9).tostring()
  File "/home/sz/work/nitrokey-start-firmware/tool/gnuk_token.py", line 320, in cmd_get_data
    raise ValueError("%02x%02x" % (sw[0], sw[1]))
ValueError: 6a88

While it is checked, whether the KDF DO is empty, there is no
exception catch for not found object. This patch adds it.
Tested update paths 1.2.6 -> 1.2.10, 1.2.6 -> 1.2.6, 1.2.10 -> 1.2.10, 1.2.10 -> 1.2.6.

Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
16 months agoVersion 1.2.10. release/1.2.10
NIIBE Yutaka [Thu, 10 May 2018 04:54:21 +0000 (13:54 +0900)]
Version 1.2.10.

16 months agoVersion 1.2.10.
NIIBE Yutaka [Thu, 10 May 2018 04:48:17 +0000 (13:48 +0900)]
Version 1.2.10.

16 months agognuk.elf is the target with VID:PID. New target gnuk-no-vidpid.elf.
NIIBE Yutaka [Thu, 10 May 2018 03:09:19 +0000 (12:09 +0900)]
gnuk.elf is the target with VID:PID.  New target gnuk-no-vidpid.elf.

16 months agoUpdate Chopstx to 1.9.
NIIBE Yutaka [Thu, 10 May 2018 03:04:37 +0000 (12:04 +0900)]
Update Chopstx to 1.9.

16 months agoMore usb_device_reset fix.
NIIBE Yutaka [Thu, 26 Apr 2018 12:23:44 +0000 (21:23 +0900)]
More usb_device_reset fix.

16 months agoFix USB initialization.
NIIBE Yutaka [Thu, 26 Apr 2018 12:08:30 +0000 (21:08 +0900)]
Fix USB initialization.

After USB RESET, all endpoints registers are being reset.  So,
there is no need to let each endpoint stall (it's disabled).
Actually, it's wrong to call usb_lld_stall_rx or usb_lld_stall_tx
before usb_lld_setup_endpoint, because other fields of endpoint
register are not specified after RESET.

16 months agoSupport GD32F103.
NIIBE Yutaka [Thu, 26 Apr 2018 08:33:48 +0000 (17:33 +0900)]
Support GD32F103.

17 months agoVersion 1.2.9. release/1.2.9
NIIBE Yutaka [Thu, 5 Apr 2018 05:00:50 +0000 (14:00 +0900)]
Version 1.2.9.

17 months agoMore tests for admin-less mode.
NIIBE Yutaka [Thu, 5 Apr 2018 04:06:13 +0000 (13:06 +0900)]
More tests for admin-less mode.

17 months agoFix admin-less mode -> admin-full mode change.
NIIBE Yutaka [Thu, 5 Apr 2018 03:13:45 +0000 (12:13 +0900)]
Fix admin-less mode -> admin-full mode change.

17 months agoUpdate ChangeLog.
NIIBE Yutaka [Wed, 4 Apr 2018 10:33:56 +0000 (19:33 +0900)]
Update ChangeLog.

17 months agoUpdate copyright year.
NIIBE Yutaka [Wed, 4 Apr 2018 10:29:35 +0000 (19:29 +0900)]
Update copyright year.

17 months agoMore check for length of PW1.
NIIBE Yutaka [Wed, 4 Apr 2018 10:28:42 +0000 (19:28 +0900)]
More check for length of PW1.

17 months agoFix removal of resetting code.
NIIBE Yutaka [Wed, 4 Apr 2018 09:59:28 +0000 (18:59 +0900)]
Fix removal of resetting code.

17 months agoMore tests (3).
NIIBE Yutaka [Wed, 4 Apr 2018 08:42:14 +0000 (17:42 +0900)]
More tests (3).

17 months agoMore tests (2).
NIIBE Yutaka [Wed, 4 Apr 2018 07:34:51 +0000 (16:34 +0900)]
More tests (2).

17 months agoMore tests.
NIIBE Yutaka [Wed, 4 Apr 2018 07:34:07 +0000 (16:34 +0900)]
More tests.

17 months agoMore test suite improvement. Add experimental KDF DO tests.
NIIBE Yutaka [Wed, 4 Apr 2018 06:44:34 +0000 (15:44 +0900)]
More test suite improvement.  Add experimental KDF DO tests.

17 months agoTest suite improvement.
NIIBE Yutaka [Wed, 4 Apr 2018 06:09:30 +0000 (15:09 +0900)]
Test suite improvement.

17 months agoAdd a test case to reset PW3.
NIIBE Yutaka [Wed, 4 Apr 2018 01:51:32 +0000 (10:51 +0900)]
Add a test case to reset PW3.

17 months agoRename tests.
NIIBE Yutaka [Tue, 3 Apr 2018 23:48:40 +0000 (08:48 +0900)]
Rename tests.

17 months agoClear all keystrings when KDF DO is written.
NIIBE Yutaka [Tue, 3 Apr 2018 11:24:28 +0000 (20:24 +0900)]
Clear all keystrings when KDF DO is written.

17 months agoFix tool/.
NIIBE Yutaka [Tue, 3 Apr 2018 06:12:58 +0000 (15:12 +0900)]
Fix tool/.

17 months agoSupport authentication with KDF Data Object.
NIIBE Yutaka [Mon, 2 Apr 2018 02:13:55 +0000 (11:13 +0900)]
Support authentication with KDF Data Object.

17 months agoFix kdf_calc.py.
NIIBE Yutaka [Mon, 2 Apr 2018 01:44:17 +0000 (10:44 +0900)]
Fix kdf_calc.py.

17 months agoAdd kdf_calc.py.
NIIBE Yutaka [Sat, 31 Mar 2018 01:28:54 +0000 (10:28 +0900)]
Add kdf_calc.py.

17 months agoFix previous commit.
NIIBE Yutaka [Fri, 30 Mar 2018 08:46:52 +0000 (17:46 +0900)]
Fix previous commit.

17 months agoSupport single-salt KDF for admin-less mode.
NIIBE Yutaka [Fri, 30 Mar 2018 01:36:11 +0000 (10:36 +0900)]
Support single-salt KDF for admin-less mode.

18 months agoKDF format validation should be done before removing data object.
NIIBE Yutaka [Thu, 22 Mar 2018 07:03:56 +0000 (16:03 +0900)]
KDF format validation should be done before removing data object.

18 months agofactory-reset should erase all upgrade public keys.
NIIBE Yutaka [Tue, 13 Mar 2018 05:05:18 +0000 (14:05 +0900)]
factory-reset should erase all upgrade public keys.

19 months agoFix KDF DO handling.
NIIBE Yutaka [Mon, 12 Feb 2018 22:26:29 +0000 (07:26 +0900)]
Fix KDF DO handling.

19 months agoFix .gitignore. release/1.2.8
NIIBE Yutaka [Tue, 23 Jan 2018 04:47:46 +0000 (13:47 +0900)]
Fix .gitignore.

19 months agoFix README.
NIIBE Yutaka [Tue, 23 Jan 2018 04:26:41 +0000 (13:26 +0900)]
Fix README.