What is DES Encryption: How It Works?

1 Star2 Stars3 Stars4 Stars5 Stars (2 votes, average: 5.00 out of 5)
loadingLoading...
DES Encryption

Learn the basics of cybersecurity with Data Encryption Standard in this beginner friendly guide

Managing your cyber security has gotten more complicated with each advancement in the field. While a simple cyclic cipher was an excellent encryption tool in Ancient Greece, today it has become hard to keep yourself secure even with some advanced encryption tools.

To understand how cybersecurity may evolve in the future, it is important to understand which developments have driven it forward till date. Even with all these improvements, the thing that’s remained constant is the fact that encryption is still our primary means of defense against unauthorized use of data. To understand it further, let’s explore it in detail.

What is Encryption?

Encryption is the foundation of cryptography. It is the process that converts readable information (plaintext) into scrambled bits of data (ciphertext) to prevent any unauthorized parties from reading it. To reverse this process, a certain key is required which allows decrypting the ciphertext into the original plaintext.

The key is present only with the designated parties and must therefore be kept secure. However, not all forms of encryption excel at doing so.

Let’s look at the two primary classifications of encryption and how they handle key security.

Types of Encryption: Symmetric and Asymmetric

Encryption is broadly classified as symmetric and asymmetric, with the latter being a newer and more secure method.

During symmetric encryption, the client and server share a common key for encrypting and decrypting messages, and this key is shared across the network prior to the encryption. This leaves the key vulnerable to attacks such as man-in-the-middle attack where it can be intercepted and used for decryption.

On the other hand, asymmetric encryption uses separate keys for encrypting and decrypting the information. The key that encrypts the information is called the public key and this is shared across the network, whereas the key that’s used for decrypting is called the private key, and this is never shared across the network.

Data Encryption Standard (DES): A Relic in Cyber Security

While symmetric encryption does possess a very obvious flaw, it was very widely used before the creation of asymmetric encryption algorithms. One of the most widely used algorithms for symmetric encryption was known as the DES algorithm or the Data Encryption Standard algorithm.

As discussed above, this used a single key for both encryption and decryption, and this key was shared between the sender and receiver across the network. After both parties possessed the key, the encryption of messages began. Today, it has been replaced by the AES or Advanced Encryption Standard.

Features of the DES Algorithm

Before we get into the details of how the DES algorithm worked, it is important to understand a few key features that it used. These are:

  • Block Cipher: Block ciphers mean that the entire data blocks were encrypted using a key instead of encrypting single bits. In the case of DES, the algorithm divided the given data into blocks of 64-bits each and then encrypted the blocks. This was more secure than the encryption of each bit as that allowed brute force methods to crack the key more easily.
  • Multiple Rounds of Encryption: To avoid unauthorized access, the DES used multiple layers of encryption that reached a total number of 16. In each layer, the blocks were either encrypted individually as a part of a node or connected to previous blocks. For the decryption of the ciphertext, it was essential to follow the same steps in reverse.
  • 64-bit Key: Unlike most other symmetric encryption methods, DES used a 64-bit key. Out of these, 56 bits was the effective length of the key while the remaining 8 bits were used for checks. During the 16 encryption rounds, the algorithm generated 16 subkeys, with each subkey being 48 bits.
  • Replacement & Permutation: The algorithm would define the sequence of permutations and replacements during the encryption process. This would prevent patterns from emerging that would make keys easier to crack.

How Did the DES Algorithm Work?

The DES Algorithm required a security provider in order to work. Security managers would choose the right security provider on the basis of the language used such as Python, C, or Java.

After the security provider was added, the key generator would generate a random key and begin the process of encryption. The DES would also test the generated encryption for vulnerabilities, and then implement it in the network.

What Makes DES Unsafe?

While the simple fact that DES used symmetric encryption is enough to declare it unsafe, it was considered as such even before asymmetric encryption methods were invented.

The primary flaw that made professionals doubt the safety of the DES algorithm was the fact that it used a 56-bit key. Using basic permutation, you can calculate the possible keys that can be generated using 56-bits and this number was close to 72 quadrillion.

While the number seems incredible, with the power of modern machines, a dedicated attacker can crack the key. Moreover, there were rumors of the National Security Agency (NSA) getting involved to make the algorithm weaker and more unsecure for the purposes of mass surveillance.

AES Vs. DES: A New Dawn

In modern network security, the AES standard has completely replaced DES for providing our security. Here are some major differences between the two:

DES EncryptionAES Encryption
Uses a single key for encryption and decryption.Uses separate keys for encryption and decryption.
The key is 64 bits and the effective key length is 56 bits.Keys can be up to 256 bits long.
Obsolete.Used in modern systems and network security.

What Keeps DES Relevant Today?

Due to its security flaws, DES encryption is not used anymore in modern systems. However, it was a major tool for security during its time and is still relevant for academic reasons. Most modern cybersecurity algorithms are complex at their fundamental levels, and DES serves as a stepping stone to understanding them.

During academic training of cybersecurity aspirants, instructors often explain cryptography methods using DES. Moreover, it is also used in teaching the fundamentals of attacking methods since it is easier to attack DES than AES. Therefore, the algorithm still serves an important role in cyber security today.

Final Thoughts

DES may be an inefficient security algorithm, however it was an important tool in the evolution of cryptography. Without seeing the evident flaws in it, cybersecurity professionals wouldn’t have incorporated features such as 256-bit keys in AES and other modern encryption algorithms. Therefore, learning it serves as an important step in understanding the fundamentals of data security.

Janki Mehta

Janki Mehta is a Cyber-Security Enthusiast who constantly updates herself with new advancements in the Web/Cyber Security niche. Along with theoretical knowledge, she also implements her practical expertise in day-to-day tasks and helps others to protect themselves from threats.