Rebex
Products Downloads Buy Support Contact
Show / Hide Table of Contents

SymmetricKeyAlgorithm Class

Namespace: Rebex.Security.Cryptography
Assembly: Rebex.Common.dll (version 7.0.9147)

Represents a symmetric cipher algorithm.

Syntax
public class SymmetricKeyAlgorithm : IDisposable
Inheritance
Object
SymmetricKeyAlgorithm
Implements
IDisposable
Inherited Members
Object.Equals(Object)
Object.Equals(Object, Object)
Object.GetHashCode()
Object.GetType()
Object.MemberwiseClone()
Object.ReferenceEquals(Object, Object)
Object.ToString()

Constructors

Name Description
SymmetricKeyAlgorithm(SymmetricKeyAlgorithmId)

Creates an instance of SymmetricKeyAlgorithmId for the specified algorithm.

Properties

Name Description
Algorithm

Gets algorithm ID.

BlockSize

Gets or sets the desired block size in bits.

EffectiveKeySize

Gets or sets the desired effective key size in bits.

KeySize

Gets or sets the desired key size in bits.

Mode

Gets or sets the desired block cipher mode.

Padding

Gets or sets the desired block cipher padding mode.

Methods

Name Description
CreateDecryptor()

Creates a decryptor object for this algorithm based on the currently set parameters.

CreateEncryptor()

Creates an encryptor object for this algorithm based on the currently set parameters.

DeriveIV(DeriveBytes)

Derives an initialization vector (of BlockSize length) using the specified generator.

DeriveKey(DeriveBytes)

Derives a key (of KeySize length) using the specified generator.

Dispose()

Disposes the object.

GenerateIV()

Generates a initialization vector (of BlockSize length).

GenerateKey()

Generates a random key (of KeySize length).

GetIV()

Gets the current initialization vector.

GetKey()

Gets the current key.

IsSupported(SymmetricKeyAlgorithmId)

Gets a value indicating whether the specified algorithm is supported.

SetIV(Byte[])

Sets the current initialization vector to the specified value.

SetKey(Byte[])

Sets the current key to the specified value and changes the KeySize accordingly.

ToSymmetricAlgorithm()

Creates a symmetric algorithm object for this algorithm based on the currently set parameters.

In This Article
  • Constructors
  • Properties
  • Methods
© REBEX ČR s.r.o. Back to top
Privacy policy
Manage cookies