喜欢
克莫拉兹
我不知道这里面有什么函数。
为了它的价值-我这样做的方式是使用一个外部的COM DLL为我进行加密/解密。
当然,您需要获取/创建这样一个DLL,以便在安装时使用和部署它。
(我使用纯installscript安装-不是msi)
function STRING Encryption(bEncrypt,sInput)
STRING sEncryptionKey, sResult;
OBJECT oEncryption;
begin
try
// create encryption key
sEncryptionKey = "key";
// create COM object
set oEncryption = CoCreateObject("Encryption");
if (IsObject(oEncryption)) then
// set encryption key
oEncryption.Initialize(sEncryptionKey);
if (bEncrypt = TRUE) then
sResult = oEncryption.Encode(sInput);
else
sResult = oEncryption.Decode(sInput);
endif;
endif;
// free object
set oEncryption = NOTHING;
catch
sResult = "";
endcatch;
return sResult;
end;
希望这有任何帮助。