Update for Nitrokey 3A NFA fails on Linux Mint

I tried to update my Nitrokey 3A from v1.2.2 in two ways.

Via Command line tool on Linux Mint 21.1:

Command line tool to interact with Nitrokey devices 0.4.38
Do you want to download the firmware version v1.5.0? [Y/n]: Y
Download v1.5.0: 100%
Current firmware version: v1.2.2
Updated firmware version: v1.5.0

Please do not remove the Nitrokey 3 or insert any other Nitrokey 3 devices during the update. Doing so may damage the Nitrokey 3.
Do you want to perform the firmware update now? [y/N]: y

Please press the touch button to reboot the device into bootloader mode …

Critical error:
An unhandled exception occurred
Exception encountered: RuntimeError(“generator didn’t stop after throw()”)


Critical error occurred, exiting now
Unexpected? Is this a bug? Would you like to get support/help?

Exception ignored in: <generator object Updater._get_bootloader at 0x7ffb7ad2b7d0>
RuntimeError: generator ignored GeneratorExit

Via Nitrokey App 2: After I confirmed to download firmware v1.5.0, the app instructed me to touch the device and wait a few seconds. When I did, the app briefly showed the message “Failed to update Nitrokey 3”.

Is there something else I can try?

I can confirm the problem. I tried to update from FW 1.4.0 under Fedora 38, using nitropy 0.4.38. Same error message here.

EDIT: Nevermind. In my case, I was stupidly on a PC where libnitrokey was not yet installed.

Hello @Fanador
Do you have the UDEV rules updates?
Here you find the instruction how to update them Update

1 Like

Your topic is similar to ticket cant-update-to-1-3-1.

The problem is the permission to /dev/hidra*

To solve it following the link which @T.L.7Gadi has shared and flowing the chapter “Troubleshooting”:

Troubleshooting:

Issue: I get permission denied for /dev/hidrawX during update.

This likely means your user has not the needed permissions to read/write the device.
Please make sure you have set up the correct udev-rules. Download this udev-rules set and place it in
your udev rules directory (e.g., /etc/udev/rules.d). Then remove your Nitrokey 3 from the USB slot and run:
udevadm control --reload-rules && udevadm trigger or reboot your machine.
Afterwards the update should work without the permission issue.

If this doesn’t work, try to run the update as admin (sudo).

1 Like

I have a similar error message when updating my Nitrokey 3A on Manjaro Linux.
But the problem came from elsewhere because of the suggested solution to implement the udev-rules I have set up.
On GitHub I found a pull request and an issue.

As in the issue reported, when I run nitropy nk3 reboot --bootloade before nitropy nk3 update the update runs without errors.

I think the problem will be solved with one of the next versions of nitropy!