The recent need to use DES encryption data, to require des encrypted data for symmetric encryption, after research, found some problems:1.DES symmetric ECB mode encrypted data, length must be a multiple of 82. Encrypted data, first transcoding after
First, IntroductionDES is a common type of symmetric encryption, all called Data Encryption Standard, which is the encryption standards, is a key encryption using the block algorithm. The key length is 64 bits (bit), and the key that exceeds the
DES (Data Encryption Standard) is a group symmetric cipher algorithm . des employs a 64-bit packet length and a 56-bit key length , which takes 64-bit inputs through a series of transformations to get 64-bit output. Decryption uses the same steps
For example, there is a 21-bit byte array which is divided into three blocks. If there are not enough 8 bytes, add 0x00 and perform DES encryption on the three blocks:
The encrypted three pieces of data are the data encrypted by the ECB.
Recently busy with Android and iOS projects, write the android des ECB mode encryption and decryption (related connection: http://blog.csdn.net/vipa1888/article/details/8086037), and return to the IOS above, because I recently started to study IOS
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.