没有合适的资源?快使用搜索试试~ 我知道了~
首页DES加密算法流程解析
DES加密算法流程解析
![](https://csdnimg.cn/release/wenkucmsfe/public/img/star.98a08eaa.png)
详细解析了DES加密算法的流程,对于想要了解并且自己实现DES算法的人很有帮助
资源详情
资源推荐
![](https://csdnimg.cn/release/download_crawler_static/4740047/bg1.jpg)
The DES Algorithm Illustrated
by J. Orlin Grabbe
The DES (Data Encryption Standard) algorithm is the most widely
used encryption algorithm in the world. For many years, and
among many people, "secret code making" and DES have been
synonymous. And despite the recent coup by the Electronic
Frontier Foundation in creating a $220,000 machine to crack DES-
encrypted messages, DES will live on in government and banking
for years to come through a life- extending version called
"triple-DES."
How does DES work? This article explains the various steps
involved in DES-encryption, illustrating each step by means of a
simple example. 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 National Bureau of Standards Coaxes the
Genie from the Bottle
On May 15, 1973, during the reign of Richard Nixon, the National
Bureau of Standards (NBS) published a notice in the Federal
Register soliciting proposals for cryptographic algorithms to
protect data during transmission and storage. 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. The contents of
these communicated and stored data often have very
significant value and/or sensitivity. 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
![](https://csdnimg.cn/release/download_crawler_static/4740047/bg2.jpg)
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. It received none until
August 6, 1974, three days before Nixon's resignation, when IBM
submitted a candidate that it had developed internally under the
name LUCIFER. After evaluating the algorithm with the help of
the National Security Agency (NSA), the NBS adopted a
modification of the LUCIFER algorithm as the new Data Encryption
Standard (DES) on July 15, 1977.
DES was quickly adopted for non-digital media, such as voice-
grade public telephone lines. Within a couple of years, for
example, International Flavors and Fragrances was using DES to
protect its valuable formulas transmitted over the phone ("With
Data Encryption, Scents Are Safe at IFF," Computerworld 14, No.
21, 95 (1980).)
Meanwhile, the banking industry, which is the largest user of
encryption outside government, adopted DES as a wholesale
banking standard. Standards for the wholesale banking industry
are set by the American National Standards Institute (ANSI).
ANSI X3.92, adopted in 1980, specified the use of the DES
algorithm.
Some Preliminary Examples of DES
DES works on bits, or binary numbers--the 0s and 1s common to
![](https://csdnimg.cn/release/download_crawler_static/4740047/bg3.jpg)
digital computers. Each group of four bits makes up a
hexadecimal, or base 16, number. Binary "0001" is equal to the
hexadecimal number "1", binary "1000" is equal to the
hexadecimal number "8", "1001" is equal to the hexadecimal
number "9", "1010" is equal to the hexadecimal number "A", and
"1111" 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
"8787878787878787", and encrypt it with the DES key
"0E329232EA6D0D73", we end up with the ciphertext
"0000000000000000". If the ciphertext is decrypted with the same
secret DES key "0E329232EA6D0D73", the result is the original
plaintext "8787878787878787".
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).
The plaintext message "Your lips are smoother than vaseline" is,
in hexadecimal,
"596F7572206C6970 732061726520736D 6F6F746865722074
68616E2076617365 6C696E650D0A".
(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.) We then pad this message with some 0s on
the end, to get a total of 80 hexadecimal digits:
"596F7572206C6970 732061726520736D 6F6F746865722074
68616E2076617365 6C696E650D0A0000".
If we then encrypt this plaintext message 64 bits (16
hexadecimal digits) at a time, using the same DES key
剩余14页未读,继续阅读
![rar](https://img-home.csdnimg.cn/images/20210720083606.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
安全验证
文档复制为VIP权益,开通VIP直接复制
![](https://csdnimg.cn/release/wenkucmsfe/public/img/green-success.6a4acb44.png)