Chilkat HOME ASP Visual Basic VB.NET C# Visual C++ C MFC Delphi FoxPro Java Perl PHP Python Ruby SQL Server VBScript
|
Read File, Encrypt in Memory, Save File
This example is in response to this customer question: CkCrypt2 crypt; crypt.UnlockComponent("30-day trial"); crypt.put_CryptAlgorithm("aes"); crypt.put_KeyLength(128); CkByteData secretKey; crypt.GenerateSecretKey("myPassword",secretKey); crypt.put_SecretKey(secretKey); // Load the contents of a file into memory. CkByteData dataToEncrypt; dataToEncrypt.loadFile("chilkatDude.jpg"); // Encrypt it... CkByteData encryptedData; crypt.EncryptBytes(dataToEncrypt,encryptedData); // Save the encrypted data to a file. encryptedData.saveFile("encryptedDude.dat");
|
Need a specific example? Send a request to support@chilkatsoft.com
© 2000-2008 Chilkat Software, Inc. All Rights Reserved.