RC2 RC2 RC2 RC2 Class

定义

表示 RC2 算法的所有实现都必须从中派生的基类。Represents the base class from which all implementations of the RC2 algorithm must derive.

public ref class RC2 abstract : System::Security::Cryptography::SymmetricAlgorithm
[System.Runtime.InteropServices.ComVisible(true)]
public abstract class RC2 : System.Security.Cryptography.SymmetricAlgorithm
type RC2 = class
    inherit SymmetricAlgorithm
Public MustInherit Class RC2
Inherits SymmetricAlgorithm
继承
派生
属性

注解

备注

较新的对称加密算法,高级加密标准 (AES),这是可用。A newer symmetric encryption algorithm, Advanced Encryption Standard (AES), is available. 请考虑使用Aes算法,而不是其派生的类RC2类。Consider using the Aes algorithm and its derived classes instead of the RC2 class. 使用RC2仅为与旧版应用程序和数据兼容。Use RC2 only for compatibility with legacy applications and data.

构造函数

RC2() RC2() RC2() RC2()

初始化 RC2 的新实例。Initializes a new instance of RC2.

字段

BlockSizeValue BlockSizeValue BlockSizeValue BlockSizeValue

表示加密操作的块大小(以位为单位)。Represents the block size, in bits, of the cryptographic operation.

(Inherited from SymmetricAlgorithm)
EffectiveKeySizeValue EffectiveKeySizeValue EffectiveKeySizeValue EffectiveKeySizeValue

表示 RC2 算法使用的机密密钥的有效大小(以位为单位)。Represents the effective size of the secret key used by the RC2 algorithm in bits.

FeedbackSizeValue FeedbackSizeValue FeedbackSizeValue FeedbackSizeValue

表示加密操作的反馈大小(以位为单位)。Represents the feedback size, in bits, of the cryptographic operation.

(Inherited from SymmetricAlgorithm)
IVValue IVValue IVValue IVValue

表示对称算法的初始化向量 (IV)。Represents the initialization vector (IV) for the symmetric algorithm.

(Inherited from SymmetricAlgorithm)
KeySizeValue KeySizeValue KeySizeValue KeySizeValue

表示对称算法使用的密钥的大小(以位为单位)。Represents the size, in bits, of the secret key used by the symmetric algorithm.

(Inherited from SymmetricAlgorithm)
KeyValue KeyValue KeyValue KeyValue

表示对称算法的密钥。Represents the secret key for the symmetric algorithm.

(Inherited from SymmetricAlgorithm)
LegalBlockSizesValue LegalBlockSizesValue LegalBlockSizesValue LegalBlockSizesValue

指定对称算法支持的块大小(以位为单位)。Specifies the block sizes, in bits, that are supported by the symmetric algorithm.

(Inherited from SymmetricAlgorithm)
LegalKeySizesValue LegalKeySizesValue LegalKeySizesValue LegalKeySizesValue

指定对称算法支持的密钥大小(以位为单位)。Specifies the key sizes, in bits, that are supported by the symmetric algorithm.

(Inherited from SymmetricAlgorithm)
ModeValue ModeValue ModeValue ModeValue

表示对称算法中使用的密码模式。Represents the cipher mode used in the symmetric algorithm.

(Inherited from SymmetricAlgorithm)
PaddingValue PaddingValue PaddingValue PaddingValue

表示对称算法中使用的填充模式。Represents the padding mode used in the symmetric algorithm.

(Inherited from SymmetricAlgorithm)

属性

BlockSize BlockSize BlockSize BlockSize

获取或设置加密操作的块大小(以位为单位)。Gets or sets the block size, in bits, of the cryptographic operation.

(Inherited from SymmetricAlgorithm)
EffectiveKeySize EffectiveKeySize EffectiveKeySize EffectiveKeySize

获取或设置 RC2 算法使用的机密密钥的有效大小(以位为单位)。Gets or sets the effective size of the secret key used by the RC2 algorithm in bits.

FeedbackSize FeedbackSize FeedbackSize FeedbackSize

获取或设置加密操作的反馈大小(以位为单位)。Gets or sets the feedback size, in bits, of the cryptographic operation.

(Inherited from SymmetricAlgorithm)
IV IV IV IV

获取或设置对称算法的初始化向量 (IV)。Gets or sets the initialization vector (IV) for the symmetric algorithm.

(Inherited from SymmetricAlgorithm)
Key Key Key Key

获取或设置对称算法的密钥。Gets or sets the secret key for the symmetric algorithm.

(Inherited from SymmetricAlgorithm)
KeySize KeySize KeySize KeySize

获取或设置 RC2 算法使用的机密密钥的大小(以位为单位)。Gets or sets the size of the secret key used by the RC2 algorithm in bits.

LegalBlockSizes LegalBlockSizes LegalBlockSizes LegalBlockSizes

获取对称算法支持的块大小(以位为单位)。Gets the block sizes, in bits, that are supported by the symmetric algorithm.

(Inherited from SymmetricAlgorithm)
LegalKeySizes LegalKeySizes LegalKeySizes LegalKeySizes

获取对称算法支持的密钥大小(以位为单位)。Gets the key sizes, in bits, that are supported by the symmetric algorithm.

(Inherited from SymmetricAlgorithm)
Mode Mode Mode Mode

获取或设置对称算法的运算模式。Gets or sets the mode for operation of the symmetric algorithm.

(Inherited from SymmetricAlgorithm)
Padding Padding Padding Padding

获取或设置对称算法中使用的填充模式。Gets or sets the padding mode used in the symmetric algorithm.

(Inherited from SymmetricAlgorithm)

方法

Clear() Clear() Clear() Clear()

释放 SymmetricAlgorithm 类使用的所有资源。Releases all resources used by the SymmetricAlgorithm class.

(Inherited from SymmetricAlgorithm)
Create() Create() Create() Create()

创建加密对象的实例以执行 RC2 算法。Creates an instance of a cryptographic object to perform the RC2 algorithm.

Create(String) Create(String) Create(String) Create(String)

创建加密对象的实例以执行 RC2 算法的指定实现。Creates an instance of a cryptographic object to perform the specified implementation of the RC2 algorithm.

CreateDecryptor() CreateDecryptor() CreateDecryptor() CreateDecryptor()

用当前的 Key 属性和初始化向量 (IV) 创建对称解密器对象。Creates a symmetric decryptor object with the current Key property and initialization vector (IV).

(Inherited from SymmetricAlgorithm)
CreateDecryptor(Byte[], Byte[]) CreateDecryptor(Byte[], Byte[]) CreateDecryptor(Byte[], Byte[]) CreateDecryptor(Byte[], Byte[])

当在派生类中重写时,用指定的 Key 属性和初始化向量 (IV) 创建对称解密器对象。When overridden in a derived class, creates a symmetric decryptor object with the specified Key property and initialization vector (IV).

(Inherited from SymmetricAlgorithm)
CreateEncryptor() CreateEncryptor() CreateEncryptor() CreateEncryptor()

用当前的 Key 属性和初始化向量 (IV) 创建对称加密器对象。Creates a symmetric encryptor object with the current Key property and initialization vector (IV).

(Inherited from SymmetricAlgorithm)
CreateEncryptor(Byte[], Byte[]) CreateEncryptor(Byte[], Byte[]) CreateEncryptor(Byte[], Byte[]) CreateEncryptor(Byte[], Byte[])

当在派生类中重写时,用指定的 Key 属性和初始化向量 (IV) 创建对称加密器对象。When overridden in a derived class, creates a symmetric encryptor object with the specified Key property and initialization vector (IV).

(Inherited from SymmetricAlgorithm)
Dispose() Dispose() Dispose() Dispose()

释放 SymmetricAlgorithm 类的当前实例所使用的所有资源。Releases all resources used by the current instance of the SymmetricAlgorithm class.

(Inherited from SymmetricAlgorithm)
Dispose(Boolean) Dispose(Boolean) Dispose(Boolean) Dispose(Boolean)

释放由 SymmetricAlgorithm 占用的非托管资源,还可以另外再释放托管资源。Releases the unmanaged resources used by the SymmetricAlgorithm and optionally releases the managed resources.

(Inherited from SymmetricAlgorithm)
Equals(Object) Equals(Object) Equals(Object) Equals(Object)

确定指定的对象是否等于当前对象。Determines whether the specified object is equal to the current object.

(Inherited from Object)
GenerateIV() GenerateIV() GenerateIV() GenerateIV()

当在派生类中重写时,生成用于该算法的随机初始化向量 (IV)。When overridden in a derived class, generates a random initialization vector (IV) to use for the algorithm.

(Inherited from SymmetricAlgorithm)
GenerateKey() GenerateKey() GenerateKey() GenerateKey()

当在派生类中重写时,生成用于该算法的随机密钥 (Key)。When overridden in a derived class, generates a random key (Key) to use for the algorithm.

(Inherited from SymmetricAlgorithm)
GetHashCode() GetHashCode() GetHashCode() GetHashCode()

作为默认哈希函数。Serves as the default hash function.

(Inherited from Object)
GetType() GetType() GetType() GetType()

获取当前实例的 TypeGets the Type of the current instance.

(Inherited from Object)
MemberwiseClone() MemberwiseClone() MemberwiseClone() MemberwiseClone()

创建当前 Object 的浅表副本。Creates a shallow copy of the current Object.

(Inherited from Object)
ToString() ToString() ToString() ToString()

返回表示当前对象的字符串。Returns a string that represents the current object.

(Inherited from Object)
ValidKeySize(Int32) ValidKeySize(Int32) ValidKeySize(Int32) ValidKeySize(Int32)

确定指定的密钥大小对当前算法是否有效。Determines whether the specified key size is valid for the current algorithm.

(Inherited from SymmetricAlgorithm)

显式界面实现

IDisposable.Dispose() IDisposable.Dispose() IDisposable.Dispose() IDisposable.Dispose()

释放由 SymmetricAlgorithm 占用的非托管资源,还可以另外再释放托管资源。Releases the unmanaged resources used by the SymmetricAlgorithm and optionally releases the managed resources.

(Inherited from SymmetricAlgorithm)

适用于

另请参阅