Encrypt(DataProtectionStore,Byte[]) Method
Specifies which key store to use (User or Machine)
The plain, or unencrypted, bytes to encrypt
Encrypts a byte array
Syntax
'Declaration
Public Overloads Shared Function Encrypt( _
ByVal _keyStore_ As DataProtectionStore, _
ByVal _plainBytes_() As Byte _
) As Byte()
public static byte[] Encrypt(
DataProtectionStore _keyStore_,
Byte[] _plainBytes_
)
Parameters
keyStore
Specifies which key store to use (User or Machine)
plainBytes
The plain, or unencrypted, bytes to encrypt
Return Value
A byte array representing the encrypted version of the original plainBytes payload
Remarks
** WARNING**: The encryption produced by this class is only usable from the machine on which the encryption occurred. The encrypted text cannot be used by a different computer.
Requirements
Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server family