This document describes the QDLPlgCipherAgent class of the QDLPluginEncryptionPS plugin for Xojo/RealStudio.This abstract class defines basic
properties and behaviors of an object performing encryption and/or decryption of data as designed in this plugin.
In cryptography, a cipher (or cypher) is an algorithm for performing encryption or decryption,
a series of well–defined steps that can be followed as a procedure. An alternative, less common term is encipherment.
To encipher or encode is to convert information from plain text into cipher or code. In non–technical usage, a 'cipher' is the same thing as a
'code'; however, the concepts are distinct in cryptography. In classical cryptography, ciphers were distinguished from codes (src.
Wikipedia).
The operation of a cipher usually depends on a piece of auxiliary information, called a
(or, in traditional NSA parlance, a cryptovariable). The encrypting procedure is varied depending on the key, which changes the detailed
operation of the algorithm. A key must be selected before using a cipher to encrypt a message. Without knowledge of the key,
it should be extremely difficult, if not impossible, to decrypt the resulting ciphertext into readable plaintext. At time, the
QDLPluginEncryptionPS plugin provides support for symmetric key algorithms only, that is algorithms using
the same key for both encryption and decryption.
The QDLPlgCipherAgent class has, in turn, two subclasses that define abstract support for
and
based ciphers.
Type:Class
Abstract:Yes
Hierarchy:→
Availability:QDLPluginEncryptionPS 1.0 or later
Console Safe
is expected to return a human–readable string descriptive of the encryption algorithm implemented.
is expected to specify if the given encryption algorithm uses an initialization block(in cryptography,
an initialization vector (IV) or starting variable (SV) is a fixed–size input to a cryptographic primitive).
Traditional such as
do not support an explicit IV as input.
For , the use of an IV is
described by so–called
.
is expected to specify the maximum number of bits (not bytes) that can be used to create the
. Noteworthy, it is possible to
provide keys with lengths exceeding this value but, in any case, the portion of the key that will be effectively used during the encryption/decryption process
will equal the value of this property.
allows to set the secret key used during the encryption and decryption of the input data. As rule of thumb, if this property has not been set, the
cipher object will be .
The key must be long enough so that an attacker cannot try all possible combinations. A key length of 80 bits is generally considered the minimum for
strong security with symmetric encryption algorithms. 128–bit keys are commonly used and considered very strong.
is expected to encrypt the passed block of data using the algorithm implemented by the concrete instance in use and the specified
. The input data stay untouched.
is expected to decrypt the passed block of data using the algorithm implemented by the concrete instance in use. The specified
has to be the same as encryption time.
The input data stay untouched.
is expected to encrypt the binary data contained into the input file
fIn using the algorithm implemented by the concrete instance in use and write
them out to the destination file
fOut. If the destination file already exists, it will be overwritten with the new data.
The input file stays untouched.
is expected to decrypt the binary data contained into the input file
fIn using the algorithm implemented by the concrete instance in use and write
them out to the destination file
fOut. If the destination file already exists, it will be overwritten with the new data. The specified
has to be the same as encryption time.
The input file stays untouched.