A message to be encrypted (known as
plaintext) is transformed by the use of a function
(or algorithm) parameterised by a key.
Traditionally, the same key is used for exncryption and decryption,
thus:
The security of the ciphertext depends on two factors:
The nature of the encryption method, or algorithm. It is
nowadays generally agreed that open publication of details of the
algorithm is a Good Thing.
The secrecy of the key. Current opinion is that, given a
suitably powerful encryption algorithm, the security of the system
should depend entirely on:
keeping the key secret, and
the length (usually measured in bits) of the key itself, which
is usually a very good indicator of the work
factor required to crack the ciphertext by trying every
possible key in turn -- called an exhaustive
search or brute force attack.