Package: yhsm-tools
Severity: wishlist
Tags: patch

yhsm-keystore-unlock kept showing me the error message "YubiHSM did
not respond to command YSM_SYSTEM_INFO_QUERY" which led me to believe that
I did something wrong during the setup of the HSM. But after some
digging it turned out that udev had assigned the YubiHSM to
/dev/ttyACM1

How about the attached patch to point users into the right direction?

Cheers,
        Moritz
--- python-pyhsm-1.0.4l.orig/utils/yhsm-keystore-unlock	2015-08-24 17:09:24.000000000 +0200
+++ python-pyhsm-1.0.4l/utils/yhsm-keystore-unlock	2015-12-10 17:10:15.770872863 +0100
@@ -128,6 +128,8 @@
                     print "OK\n"
     except pyhsm.exception.YHSM_Error, e:
         sys.stderr.write("ERROR: %s\n" % (e.reason))
+        if e.reason == "YubiHSM did not respond to command YSM_SYSTEM_INFO_QUERY":
+            sys.stderr.write("Please check whether your YubiHSM is really at " + args.device + ", you can specify an alternate device using the option -D")
         return 1
 
     return 0

Reply via email to