Explore chapters and articles related to this topic
CCA-Security and Authenticated Encryption
Published in Jonathan Katz, Yehuda Lindell, Introduction to Modern Cryptography, 2020
In our discussion of CBC-mode encryption in Section 3.6.3, we only dealt with the case where the message length was a multiple of the block length of the underlying block cipher F. If a message does not satisfy this property, it must be padded before CBC mode is applied; we refer to the result after padding as the encoded data. The padding must allow the receiver to unambiguously recover the original message from the encoded data. One popular padding scheme is defined by the PKCS #7 standard, and works as follows. Assume the original message has an integral number of bytes, and let L denote the block length (in bytes) of the block cipher F. Let b > 0 denote the number of bytes that need to be appended to the message in order to make the total length of the resulting encoded data a multiple of the block length. Then we append to the message the integer b (represented in one byte, i.e., two hexadecimal digits) repeated b times. That is, if one byte of padding is needed then the 1-byte string 0×01 (written in hexadecimal) is appended; if four bytes of padding are needed then 0×04040404 is appended; etc. (Note that b is an integer between 1 and L, inclusive—we cannot have b = 0 since this would lead to ambiguous padding. Thus, if the original message length is already a multiple of the block length, then b = L.) After padding, the encoded data is encrypted using regular CBC-mode encryption.
Message Authentication
Published in Khaleel Ahmad, M. N. Doja, Nur Izura Udzir, Manu Pratap Singh, Emerging Security Algorithms and Techniques, 2019
The Algorithm works in the following five steps: Append Padding bytesThe message is padded by a multiple of 128 bit or 16 bytes which is the block length to make it a multiple of 16 bytes.Append ChecksumThe message created in the previous step is appended by a checksum of 16 bytes. To do this, a 256-bit random permutation is used.Initialize MD bufferA new buffer already initialized to zero is used. It is a 48-byte auxiliary buffer which is used to compute digest value.Process Message in 16-byte blocksThe 256-byte permutation similar to the one used in step 2 is used here. A loop is run which permutes each byte in the auxiliary block 18 times for every 16 input bytes processed.OutputWhen all blocks have been processed, the first partial block of the auxiliary block becomes the message digest.The MD2 message digest is simple to implement and provide a fingerprint of the message. The difficulty of two messages to come up with the exactly same hash is of the order 264, and coming up with a message from message digest is 2128.
Security enhancement and analysis of images using a novel Sudoku-based encryption algorithm
Published in Journal of Information and Telecommunication, 2023
Kanaad Deshpande, Junaid Girkar, Ramchandra Mangrulkar
The second part of sixth seven is shuffling the image according to the final key. This scrambling (Y. Li et al., 2016) has been done to introduce randomness into the algorithm. Once the image has been scrambled and padded, it is ready to enter the actual encryption rounds, which involve using the n Sudoku keys. It can be noted that the padded image is encrypted; hence, the encrypted image contains extra padding when the sender communicates it to the receiver. An attempt at removing the padding shall result in data loss as the padded borders are also involved in the encryption process.