Kerchoffs’ principle on Cryptography’s strength
If keys are:
Then it has no importance that the encryption and decryption algos are keps secret.
It is better that those algos are public so that they can be widely studied and weaknesses are identified and fixed.
Secret key / symmetric cryptography

EX-OR function
The ideal confusion operator.
If the input is random the output will be equally random.

DES
Triple DES (3DES, TDES)
Double DES
Meet-in-the-Middle attack
IDEA
RC{2,4}
RC2 was published as RFC-2268 in 1998, 8 to 1024 bits keys (usually 64bits), 64b datablock.
RC4 reverse engineered (ARCFOUR).
Application of block algorithms to data blocks of size != algorithm’s block size.
ECB
Electronic Code Book

CBC
Cipher Block Chaining

Padding
Notes:

CTS
Ciphertext Stealing
In CBC the tail of the second-to-last block got xored with the padding of the last block, so we have it.

CTR
Counter mode

Symmetric stream algorithms

Salsa20, ChaCha20
Symmetric stream algorithms invented by DJ Bernstein
128 or 256 bit keys
Symmetric encryption

Length of cryptographic keys in relation with security

DES challenges
IETF changed all RFC advising not to use DES, but 3DES.
AES
US competition called for selecting a new symmetric algorithm.
AES (Advanced Ecryption Standard)
5 finalists, RIJNDAEL won in 2000, published in 2001 a FIPS-197 => AES = RIJNDAEL.
Gradually being adopted since 2010, encryption algos are like wine, the bests are the one that ages.
Public key criptography

Digital Signature

Confidentiality without a shared secret
