SymmetricAlgorithm: GenerateKey

GenerateKey

When implemented ba a class, generates a random key (Key) to use for the algorithm.



 Public Sub GenerateKey ( )

Remarks

In general, there is no reason to use this method, because CreateEncryptor() automatically generates both an initialization vector and a key. However, you may want to use the GenerateKey() method to reuse a symmetric algorithm instance with a different key.

See Also

Project CorLib Overview

Class SymmetricAlgorithm Overview