InMemorySymmetricSecurityKey.GetEncryptionTransform(String, Byte[]) 方法

定義

取得轉換,這個轉換會使用指定的密碼編譯演算法來加密 XML。

public:
 override System::Security::Cryptography::ICryptoTransform ^ GetEncryptionTransform(System::String ^ algorithm, cli::array <System::Byte> ^ iv);
public override System.Security.Cryptography.ICryptoTransform GetEncryptionTransform (string algorithm, byte[] iv);
override this.GetEncryptionTransform : string * byte[] -> System.Security.Cryptography.ICryptoTransform
Public Overrides Function GetEncryptionTransform (algorithm As String, iv As Byte()) As ICryptoTransform

參數

algorithm
String

加密 XML 的密碼編譯演算法。

iv
Byte[]

Byte 陣列,其中包含指定之演算法的初始化向量 (IV)。

傳回

表示加密轉換的 ICryptoTransform

例外狀況

不支援 algorithm。 支援的演算法為 TripleDesEncryptionAes128EncryptionAes192EncryptionAes256Encryption

備註

使用表示在 SecurityAlgorithms 類別中之加密演算法的欄位來指定此演算法。

適用於