All wodCrypt (12) wodSSH (10) wodSFTP (23) wodSSHServer (1) wodSSHTunnel (11) wodSSHpackage wodSFTPdll wodSSH.NET (10) wodSFTP.NET (24) wodFtpDLX.NET (22) wodWebServer.NET (10) wodAppUpdate (13) wodHttpDLX (8) wodFtpDLX (22) wodTelnetDLX wodFTPServer (3) wodWebServer (10) wodVPN wodXMPP (13) | All ** [Visual Basic] ** [C#] ** [VB.NET] ** Decrypt file
VB code
'Declare wodCrypt ActiveX component. Dim wodCrypt1 As wodCryptCom Set wodCrypt1 = New wodCryptCom 'Declare wodCrypt file blob. 'FileBlob is needed when we work with files in wodCrypt. Dim srcfile As New FileBlob Dim destfile As New FileBlob 'Load file we want to decrypt. srcfile.FileName = "c:\somefile_enc.exe" 'Specify where decrypted file will be saved. destfile.FileName = "c:\somefile.exe" 'We need to use same setting when we encrypt file in order to decrypt it correctly. wodCrypt1.Optimized = True wodCrypt1.Type = AES256 wodCrypt1.SecretKey = "WeOnlyDo!" 'Finally we can decrypt file using Decrypt Method. wodCrypt1.Decrypt srcfile, destfile VB.NET code
'Declare wodCrypt ActiveX component. Dim wodCrypt1 As New WODCRYPTCOMLib.wodCryptCom 'Declare wodCrypt file blob. 'FileBlob is needed when we work with files in wodCrypt. Dim srcfile As New WODCRYPTCOMLib.FileBlob Dim destfile As New WODCRYPTCOMLib.FileBlob 'Load file we want to decrypt. srcfile.Filename = "c:\somefile_enc.exe" 'Specify where decrypted file will be saved. destfile.Filename = "c:\somefile.exe" 'We need to use same setting when we encrypt file in order to decrypt it correctly. wodCrypt1.Optimized = True wodCrypt1.type = WODCRYPTCOMLib.CryptoTypes.AES256 wodCrypt1.SecretKey = "WeOnlyDo!" 'Finally we can decrypt file using Decrypt Method. wodCrypt1.Decrypt(srcfile, destfile) C# code
//Declare wodCrypt ActiveX component. WODCRYPTCOMLib.wodCryptCom wodCrypt1 = new WODCRYPTCOMLib.wodCryptCom(); //Declare wodCrypt file blob. //FileBlob is needed when we work with files in wodCrypt. WODCRYPTCOMLib.FileBlob srcfile = new WODCRYPTCOMLib.FileBlob(); WODCRYPTCOMLib.FileBlob destfile = new WODCRYPTCOMLib.FileBlob(); //Load file we want to decrypt. srcfile.Filename = "c:\\somefile_enc.exe"; //Specify where encrypted file will be saved. destfile.Filename = "c:\\somefile.exe"; //We need to use same setting when we encrypt file in order to decrypt it correctly. wodCrypt1.Optimized = true; wodCrypt1.type = WODCRYPTCOMLib.CryptoTypes.AES256; wodCrypt1.SecretKey = "WeOnlyDo!"; //Finally we can decrypt file using Decrypt Method. wodCrypt1.Decrypt((WODCRYPTCOMLib.Blob)srcfile, (WODCRYPTCOMLib.Blob)destfile); |