SymmetricAlgorithm.GetCiphertextLengthEcb(Int32, PaddingMode) メソッド

定義

指定されたパディング モードと ECB モードのプレーンテキスト長を持つ暗号テキストの長さを取得します。

public:
 int GetCiphertextLengthEcb(int plaintextLength, System::Security::Cryptography::PaddingMode paddingMode);
public int GetCiphertextLengthEcb (int plaintextLength, System.Security.Cryptography.PaddingMode paddingMode);
member this.GetCiphertextLengthEcb : int * System.Security.Cryptography.PaddingMode -> int
Public Function GetCiphertextLengthEcb (plaintextLength As Integer, paddingMode As PaddingMode) As Integer

パラメーター

plaintextLength
Int32

プレーンテキストの長さ (バイト単位)。

paddingMode
PaddingMode

プレーンテキストをアルゴリズムのブロック サイズに埋め込むのに使用されるパディング モード。

戻り値

Int32

パディングを含む暗号テキストの長さ (バイト単位)。

例外

plaintextLength は負の値です。

または

plaintextLength 埋め込みが大きすぎて符号付き 32 ビット整数として表す場合。

または

paddingMode は有効なパディング モードではありません。

BlockSize は正の整数ではありません。

または

BlockSize はバイトの整数ではありません。 8 で割り切れる必要があります。

パディング モード None が使用されましたが plaintextLength 、ブロックの合計数ではありません。

適用対象