This README provides an overview of the Data Encryption Standard (DES) algorithm, its key schedule and encryption rounds.
The Data Encryption Standard (DES) is a symmetric-key algorithm for the encryption of digital data. Developed in the 1970s, DES became a widely adopted standard for secure communications. Although superseded by more modern algorithms (like AES), DES remains an excellent educational tool to learn about block ciphers and Feistel networks.
-
Block size: 64 bits
-
Key size: 64 bits (56 bits used; 8 bits for parity)
-
Rounds: 16 Feistel rounds
At a high level, DES encryption consists of:
-
Initial Permutation (IP)
-
16 rounds of the Feistel function
-
Final Permutation (IP-1)
The DES key schedule generates 16 round keys (48 bits each) from the original 64-bit key.

-
Input: 64-bit key (including parity bits)
-
Output: 56-bit key (parity bits dropped, bits permuted)
-
Split the 56-bit result into two 28-bit halves: C and D.
-
Perform circular left shifts on each half according to the DES shift schedule:
| Round | Shifts |
|---|---|
| 1, 2, 9, 16 | 1 bit |
| All others | 2 bits |
-
Input: 56-bit concatenation of shifted C/D
-
Output: 48-bit round key
Each round applies the following steps:
-
Expand the right half (32 → 48 bits)
-
XOR with the round key
-
Substitute via 8 S-boxes (48 → 32 bits)
-
Permutate (P-box)
-
Swap halves (except after final round)
-
FIPS PUB 46-3: Data Encryption Standard
-
Schneier, B. (1996). Applied Cryptography
-
Data Encryption Standard (DES): Key Schedule and Decryption by Christof Paar



