How does des encrypt a plaintext




















Since the creation of DES, many other algorithms recipes for changing data have emerged which are based on design principles similar to DES. Once you understand the basic transformations that take place in DES, you will find it easy to follow the steps involved in these more recent algorithms. But first a bit of history of how DES came about is appropriate, as well as a look toward the future.

The notice explained why encryption was an important issue. Over the last decade, there has been an accelerating increase in the accumulations and communication of digital data by government, industry and by other organizations in the private sector. It is now common to find data transmissions which constitute funds transfers of several million dollars, purchase or sale of securities, warrants for arrests or arrest and conviction records being communicated between law enforcement agencies, airline reservations and ticketing representing investment and value both to the airline and passengers, and health and patient care records transmitted among physicians and treatment centers.

The increasing volume, value and confidentiality of these records regularly transmitted and stored by commercial and government agencies has led to heightened recognition and concern over their exposures to unauthorized access and use. This misuse can be in the form of theft or defalcations of data records representing money, malicious modification of business inventories or the interception and misuse of confidential information about people.

The need for protection is then apparent and urgent. It is recognized that encryption otherwise known as scrambling, enciphering or privacy transformation represents the only means of protecting such data during transmission and a useful means of protecting the content of data stored on various media, providing encryption of adequate strength can be devised and validated and is inherently integrable into system architecture.

The National Bureau of Standards solicits proposed techniques and algorithms for computer data encryption. The Bureau also solicits recommended techniques for implementing the cryptographic function: for generating, evaluating, and protecting cryptographic keys; for maintaining files encoded under expiring keys; for making partial updates to encrypted files; and mixed clear and encrypted data to permit labelling, polling, routing, etc.

The Bureau in its role for establishing standards and aiding government and industry in assessing technology, will arrange for the evaluation of protection methods in order to prepare guidelines. NBS waited for the responses to come in.

DES was quickly adopted for non-digital media, such as voice-grade public telephone lines. Meanwhile, the banking industry, which is the largest user of encryption outside government, adopted DES as a wholesale banking standard. ANSI X3. Each group of four bits makes up a hexadecimal, or base 16, number.

Binary "" is equal to the hexadecimal number "1", binary "" is equal to the hexadecimal number "8", "" is equal to the hexadecimal number "9", "" is equal to the hexadecimal number "A", and "" is equal to the hexadecimal number "F". DES works by encrypting groups of 64 message bits, which is the same as 16 hexadecimal numbers.

To do the encryption, DES uses "keys" where are also apparently 16 hexadecimal numbers long, or apparently 64 bits long. However, every 8th key bit is ignored in the DES algorithm, so that the effective key size is 56 bits. But, in any case, 64 bits 16 hexadecimal digits is the round number upon which DES is organized.

For example, if we take the plaintext message "", and encrypt it with the DES key "0EEA6D0D73", we end up with the ciphertext "".

This example is neat and orderly because our plaintext was exactly 64 bits long. The same would be true if the plaintext happened to be a multiple of 64 bits.

But most messages will not fall into this category. They will not be an exact multiple of 64 bits that is, an exact multiple of 16 hexadecimal numbers. For example, take the message "Your lips are smoother than vaseline". This plaintext message is 38 bytes 76 hexadecimal digits long. So this message must be padded with some extra bytes at the tail end for the encryption.

Once the encrypted message has been decrypted, these extra bytes are thrown away. There are, of course, different padding schemes--different ways to add extra bytes. Here we will just add 0s at the end, so that the total message is a multiple of 8 bytes or 16 hexadecimal digits, or 64 bits.

Note here that the first 72 hexadecimal digits represent the English message, while "0D" is hexadecimal for Carriage Return, and "0A" is hexadecimal for Line Feed, showing that the message file has terminated.

This is the secret code that can be transmitted or stored. Decrypting the ciphertext restores the original message "Your lips are smoother than vaseline". Think how much better off Bill Clinton would be today, if Monica Lewinsky had used encryption on her Pentagon computer! How DES Works in Detail DES is a block cipher --meaning it operates on plaintext blocks of a given size bits and returns ciphertext blocks of the same size.

Each block of 64 bits is divided into two blocks of 32 bits each, a left half block L and a right half R. This division is only used in certain operations. However, there are many available providers to choose from, but selecting one is the essential initial step in implementation. Once you decide on a provider, you must choose whether to have a random secret key generated by the KeyGenerator or create a key yourself, using a plaintext or byte array. You can find a testing procedure that will do the trick using the recurrence relation found on GitHub.

There will always be room for the DES algorithm in cryptography because it was the foundation for subsequent encryption algorithms. If you understand the origins of data encryption, you will consequently have an easier time grasping the basics of current encryption methods. After having gone through and understanding what is DES, let us look into ways to improve our cybersecurity skills.

Encryption is just one aspect of cybersecurity. There is so much to learn in this vast field beginning, and the more you know, the more marketable a candidate you become when looking for a career in the field. One can never possess too much knowledge!

To that end, Simplilearn offers an impressive variety of cybersecurity-related courses for your benefit. The program features a half-dozen courses that will impart the necessary foundational, intermediate and advanced security skills for you to become a cybersecurity expert.

The right 32 bits in the current step are computed XORing the left 32 bits of the previous step with the result of the f function. This will result in a final block L 16 R To calculate f , we first expand each block R n-1 from 32 bits to 48 bits. This is done by using a selection table that repeats some of the bits in R n This selection table E has a 32 bit input block R n-1 and a 48 bit output block. Let E be such that the 48 bits of its output, written as 8 blocks of 6 bits each, are obtained by selecting the bits in its inputs in order according to the following table:.

In our example we can get E R 0 from R 0 as follows:. We have not yet finished calculating the function f. To this point we have expanded R n-1 from 32 bits to 48 bits, using the selection table, and XORed the result with the key K n. We now have 48 bits, that will be used as addresses for the " S boxes ". An S box takes as input 6 bits and gives 4 bits output that will replace the 6 bits input. We have 8 groups of 6 bits B i , which will then be transformed in 8 groups of 4 bits, for a total of 32 bits.

The first and last bits of B represent in base 2 a number in the decimal range 0 to 3 binary 00 to Let that number be i. The 4 bits in the middle of B represent in base 2 a number in the decimal range 0 to 15 binary to Let that number be j.

Look up in the table the number in the i -th row and j -th column. It is a number in the range 0 to 15 and is uniquely represented by a 4 bit block. That block is the output S 1 B of S 1 for the input B. This is row 1.



0コメント

  • 1000 / 1000