Problem Exporting ZPK

Jul 14, 2011 at 7:12 PM


I am attempting to export a ZPK which is failing with the following exception.

System.Exception: Invalid value [;0U602A83E33EE7267B427417A80506E] for field [ZMK].   at ThalesSim.Core.Message.XML.MessageParser.Parse(Message msg, MessageFields fields, MessageKeyValuePairs& KVPairs, String& result)   at ThalesSim.Core.HostCommands.BuildIn.ExportKey_A8.AcceptMessage(Message msg)   at ThalesSim.Core.ThalesMain.WCMessageArrived(WorkerClient sender, Byte[]& b, Int32 len)

It appears the optional delimiter and ZMK/TMK flag are causing the issue.  When I remove them as a test the command works fine.  Unfortunately, I cannot permanently remove them since the command works fine against our HSM.  Any suggestions?

Here is the message..



Jul 14, 2011 at 11:23 PM

You're working with a PayShield 9000. The command is coded for an HSM 8000 and that's the problem. The HSM 8000 doesn't have the optional semicolon and ZMK/TMK flag.

If this is a custom command you've coded yourself and you can alter the program sending the command to the HSM, it's safe to omit the semicolon and the ZMK/TMK flag after the semicolon if you know you'll always be sending 0 as the ZMK/TMK flag. With a value of ZMK/TMK flag set always to 0, the simulator's A8 behavior will be exactly the same as that of the PayShield 9000.

If you might want to specify a value of 1 in the future for ZMK/TMK, then the current implementation of A8 will not work for you.

If you want to specify a value for the ZMK/TMK flag but it will always be zero, you can alter the contents of the ExportKey_A8.xml host definition file. Just add another field with any name after Key Type and specify a length of 2. This will instruct the simulator to parse the semicolon and the ZMK/TMK flag but ignore their values.

Let me know how this works for you.

Jul 15, 2011 at 3:36 PM

Hi Nick,

I updated ExportKey_A8.xml as you suggested.  Everything works fine for what I need now.

Thanks for your quick response.