SymmetricAlgorithm: CreateEncryptor

CreateEncryptor

When implemented by a class, creates a symmetric encryptor object with the specified Key property and initialization vector (IV).



 Public Function CreateEncryptor(
	  Optional ByRef RgbKey As Variant,
	  Optional ByRef RgbIV As Variant ) As ICryptoTransform

Parameters

RgbKey
[ByRef] Optional. Variant. The secret key to use for the symmetric algorithm.
RgbIV
[ByRef] Optional. Variant. The initialization vector to use for the symmetric algorithm.

Return Values

ICryptoTransform -  A symmetric encryptor object.

Remarks

Use the CreateDecryptor overload with the same parameters to decrypt the result of this method.

Exceptions

ExceptionCondition
ArgumentExceptionOnly RgbKey or RgbIV was specified.

See Also

Project CorLib Overview

Class SymmetricAlgorithm Overview

CreateDecryptor