Cipher Block Chaining (CBC) | Cryptography
By Serene Ch'ng Khoo Chern and Jamie Yeoh Zi-Yi
Course CSCI361 Cryptography and Secure Applications
This video is about Cipher Block Chaining mode also known as CBC. CBC is a mode of operation for a block cipher. It uses a chaining mechanism that causes the encryption of a block of plain text and decryption of a block of cipher text to depend on all the preceding cipher text blocks. CBC mode produces different cipher text blocks even if plain text blocks are the same.
Before the encryption takes place, the plain text is split into blocks of fixed sizes depending on the size of the required input block for the type of encryption chosen. In the case where the block does not fulfil the required size, padding will be used.
The example used in this video has a plain text size of 160 bits and the encryption standard chosen is Data Encryption Standard (DES). DES requires an input block with size 64 bits and key of 64 bits which results in an output block of 64 bits. Hence, the plain text is split into 3 blocks, with the first 2 blocks having the size of 64 bits and the last block being 32 bits. This requires the last block to be padded with another 32 bits to fulfil 64 bits. This block is then treated like all the other blocks.
In the encryption process, the first block of plain text is first XOR-ed with an initialization vector, IV, of a certain length. The length is depending on the type of encryption chosen, similar to the size of the plain text blocks. So, in this example, it will be 64 bits. IV is used because the previous block does not exist. The IV is not secret but it is advisable for it to be unpredictable.
After the block is XOR-ed, the block is encrypted with an encryption method of choice. As mentioned before, this example is using DES. DES requires a key of 64 bits. After the encryption is completed, the output or cipher block is fed back to the next step. It is imperative to note that the plain text block, IV, input block and output block is of the same size, in this case, it is 64 bits.
For the following block of plain text, it is XOR-ed with the cipher block of the previous step instead of the initialization vector. This step is repeated for the remaining blocks of plain text.
Basically, in cipher block chaining, each plain text block is XOR-ed with the immediate previous cipher text block, and then encrypted.
As for the decryption process, the first block of the cipher text is decrypted with the same encryption standard used for encryption. In this example, it is the DES decryption and the same key used for encryption earlier will be used to decrypt now.
Then, the output from the DES will be XOR-ed with the same initialization vector used when it was encrypted. This would result in the first block of plain text.
As for the following block of cipher text, the block is first decrypted using DES with the same key and then XOR-ed with the cipher text block from the text of the previous block. This step is repeated for the remaining blocks of cipher text. However, if padding was used during encryption, the padding is removed only when the last block of cipher text is decrypted into plain text.
Что делает видео по-настоящему запоминающимся? Наверное, та самая атмосфера, которая заставляет забыть о времени. Когда вы заходите на RUVIDEO, чтобы посмотреть онлайн «Cipher Block Chaining (CBC) | Cryptography», вы рассчитываете на нечто большее, чем просто загрузку плеера. И мы это понимаем. Контент такого уровня заслуживает того, чтобы его смотрели в HD 1080, без дрожания картинки и бесконечного буферизации.
Честно говоря, Rutube сегодня — это кладезь уникальных находок, которые часто теряются в общем шуме. Мы же вытаскиваем на поверхность самое интересное. Будь то динамичный экшн, глубокий разбор темы от любимого автора или просто уютное видео для настроения — всё это доступно здесь бесплатно и без лишних формальностей. Никаких «заполните анкету, чтобы продолжить». Только вы, ваш экран и качественный поток.
Если вас зацепило это видео, не забудьте взглянуть на похожие материалы в блоке справа. Мы откалибровали наши алгоритмы так, чтобы они подбирали контент не просто «по тегам», а по настроению и смыслу. Ведь в конечном итоге, онлайн-кинотеатр — это не склад файлов, а место, где каждый вечер можно найти свою историю. Приятного вам отдыха на RUVIDEO!
Видео взято из открытых источников Rutube. Если вы правообладатель, обратитесь к первоисточнику.