Inno configuration with IKG: access violation at address XXXXXXX in ISID.dll module

I am using the Inno Setup Key Generator (IKG). I successfully call ValidateSerialNumber

Valid := ValidateSerialNumber(ExpPath,RegName,'','','','',PrivKey,RegKey); 

While I am skipping blank lines for PrivKey and RegKey, the function returns false as expected. As soon as I pass the value of PrivKey or RegKey, I get the error message:

 Access violation at address XXXXXXX in module ISID.dll. Read of Address XXXXXX. 

Non-empty values ​​for ExpPath or RegName do not have this effect.

Function declared:

 function ValidateSerialNumber(InnoKeyFile, User, Orgn, ProdCode, HDD, MAC, PrivateKey, Serial: String): Boolean; external ' ValidateSerialNumber@files :ISID.dll stdcall'; 

What am I doing wrong?

+4
source share
1 answer

Usage most likely uses Unicode InnoSetup, and this library takes into account the ANSI version. I found some manual for this library since 2004, when InnoSetup wasn't Unicode , try using this ANSI import:

 function ValidateSerialNumber(InnoKeyFile, User, Orgn, ProdCode, HDD, MAC, PrivateKey, Serial: AnsiString): Boolean; external ' ValidateSerialNumber@files :ISID.dll stdcall'; 
+1
source

Source: https://habr.com/ru/post/1440326/


All Articles