(Lianja) Example: Crypt2.AddPfxSourceBd method
Demonstrates how to call the AddPfxSourceBd method.
loCrypt = createobject("CkCrypt2")
llSuccess = .F.
// Do public-key decryption (RSA)
loCrypt.CryptAlgorithm = "pki"
// ...
// ...
// ...
loBdPfx = createobject("CkBinData")
llSuccess = loBdPfx.LoadFile("c:/my_pfx_files/a.pfx")
// ...
lcPfxPassword = "secret1"
llSuccess = loCrypt.AddPfxSourceBd(loBdPfx,lcPfxPassword)
if (llSuccess = .F.) then
? loCrypt.LastErrorText
release loCrypt
release loBdPfx
return
endif
// Add as many as PFX sources as desired...
llSuccess = loBdPfx.LoadFile("c:/my_pfx_files/b.pfx")
lcPfxPassword = "secret2"
llSuccess = loCrypt.AddPfxSourceBd(loBdPfx,lcPfxPassword)
if (llSuccess = .F.) then
? loCrypt.LastErrorText
release loCrypt
release loBdPfx
return
endif
// ...
// ...
release loCrypt
release loBdPfx
|