CryptoSys PKI Pro Manual

Cipher.FileDecrypt Method (String, String, String, String, CipherAlgorithm, Mode)

Decrypt a file passing key and IV as hex strings.

Syntax

[C#]
public static int FileDecrypt(
	string fileOut,
	string fileIn,
	string keyHex,
	string ivHex,
	CipherAlgorithm cipherAlg,
	Mode mode
)
[VB.NET]
Public Shared Function FileDecrypt ( _
	fileOut As String, _
	fileIn As String, _
	keyHex As String, _
	ivHex As String, _
	cipherAlg As CipherAlgorithm, _
	mode As Mode _
) As Integer

Parameters

fileOut
Name of output file to be created or overwritten
fileIn
Name of input file, in binary format, padded with PKCS5 padding if required.
keyHex
Hex-encoded key of exact length
ivHex
Hex-encoded IV or "" for ECB mode
cipherAlg
Type: CipherAlgorithm
Cipher Algorithm
mode
Type: Mode
Cipher Mode

Return Value

0 if successful or non-zero error code

Remarks

fileOut and fileIn must not be the same. The output file is in binary format.

[Contents] [Index]

[PREV: Cipher.FileDecrypt Method (String, String, Byte, Byte, CipherAlgorithm, Mode, Padding, Cipher.Opts)...]   [Contents]   [Index]   
   [NEXT: Cipher.FileEncrypt Method (String, String, Byte, Byte, CipherAlgorithm, Mode)...]

Copyright © 2004-21 D.I. Management Services Pty Ltd. All rights reserved. Generated 2021-10-01T09:03:20Z.