AutoIt
AutoIt
Example: Crypt2.EncryptSb method
Demonstrates how to call the EncryptSb method.Chilkat AutoIt Downloads
Local $bSuccess = False
$oCrypt = ObjCreate("Chilkat.Crypt2")
$oBdEncrypted = ObjCreate("Chilkat.BinData")
$oSbPlainText = ObjCreate("Chilkat.StringBuilder")
$oSbPlainText.Append("Text to be encrypted")
; ...
; Set the secret key ...
; Set properties such as CryptAlgorithm, CipherMode, PaddingScheme, KeyLength
; Set the IV if needed ...
; ...
$oCrypt.Charset = "utf-8"
$bSuccess = $oCrypt.EncryptSb($oSbPlainText,$oBdEncrypted)
If ($bSuccess = False) Then
ConsoleWrite($oCrypt.LastErrorText & @CRLF)
Exit
EndIf