{"id":247,"date":"2018-07-23T09:43:06","date_gmt":"2018-07-23T09:43:06","guid":{"rendered":"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/?post_type=chapter&#038;p=247"},"modified":"2018-12-27T11:26:52","modified_gmt":"2018-12-27T11:26:52","slug":"advanced-encryption-standardpart1","status":"publish","type":"chapter","link":"https:\/\/ebooks.inflibnet.ac.in\/csp11\/chapter\/advanced-encryption-standardpart1\/","title":{"rendered":"Advanced Encryption Standard(part1)"},"content":{"raw":"<div><span style=\"float: right\"><a href=\"https:\/\/youtu.be\/fJhVQez6Zis\" target=\"_blank\" rel=\"noopener\"><img src=\"http:\/\/epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/2018\/11\/download.png\" alt=\"epgp books\" width=\"75px\" height=\"75px;\" \/><\/a>\r\n<\/span><\/div>\r\n&nbsp;\r\n\r\n&nbsp;\r\n\r\n&nbsp;\r\n\r\n<strong>AES (Part 1)<\/strong>\r\n\r\n&nbsp;\r\n<p style=\"text-align: justify\">Availability of advanced computing systems make ease to break the ciphers that we have discussed so far. A replacement of DES was needed because of small key size. Triple DES is too slow because we have to run 48 rounds effectively. So it is not a good solution. The Advanced Encryption Standard (AES) is a successor of many algorithms which are later proved to be vulnerable. The AES algorithm is a symmetric encryption algorithm which uses a single key for both encryption and decryption process. AES is also the official encryption used by the government of United States of America and Canada. It is used for both encryption of data in transit (data uploading and downloading) and for data at rest (Data in Hard Drive and other storage devices). Though they will use a 256 bit encryption key to encrypt the data.<\/p>\r\n&nbsp;\r\n<div>\r\n<p style=\"text-align: justify\">In 1997, National Institute for Standards and Technology send out for an open call for ciphers. Private key symmetric block cipher ,128-bit data, 128\/192\/256-bit keys ,Stronger &amp; faster than Triple-DES ,Provide full specification &amp; design details ,Both C and Java implementations were NIST\u2019s requirements for the AES candidate submissions. In fact, two set of criteria evolved. When NIST issued its original request for candidate\u00a0algorithm\u00a0 nominations\u00a0 in\u00a0\u00a0 1997,\u00a0 the\u00a0\u00a0 request\u00a0 stated\u00a0 that\u00a0\u00a0\u00a0 candidate algorithms would be compared based on the factors shown in Stallings Table5.1, which were used to evaluate field of 15 candidates to select shortlist of 5. These had categories of security, cost, and algorithm &amp; implementation characteristics. The\u00a0 final\u00a0 criteria\u00a0 evolved\u00a0 during\u00a0 the evaluation process, and were used to select Rijndael from that short-list and different categories of: general security, ease of software &amp; hardware implementation,\u00a0 implementation\u00a0 attacks,\u00a0 &amp;\u00a0 flexibility\u00a0 (in\u00a0 en\/decrypt,keying, other factors).<\/p>\r\n\r\n<\/div>\r\nThe AES shortlist of 5 ciphers as:\r\n<ul>\r\n \t<li>MARS (IBM) - complex, fast, high security margin<\/li>\r\n<\/ul>\r\n<ul>\r\n \t<li>RC6 (USA) - v. simple, v. fast, low security margin<\/li>\r\n<\/ul>\r\n<ul>\r\n \t<li>Rijndael (Belgium) - clean, fast, good security margin<\/li>\r\n<\/ul>\r\n<ul>\r\n \t<li>Serpent (Euro) - slow, clean, v. high security margin<\/li>\r\n<\/ul>\r\n<ul>\r\n \t<li>Twofish (USA) - complex, v. fast, high security margin<\/li>\r\n<\/ul>\r\n<p style=\"text-align: justify\">Note mix of commercial (MARS, RC6, Twofish) verses academic (Rijndael, Serpent) proposals, sourced from various countries.<\/p>\r\n&nbsp;\r\n<p style=\"text-align: justify\">All were thought to be good \u2013 it came down to the best balance of attributes to meet criteria, in particular the balance between speed, security &amp; flexibility.<\/p>\r\n&nbsp;\r\n<p style=\"text-align: justify\">Rijndael was selected as the AES in Oct-2000. It was designed by Vincent Rijmen and Joan Daemen in Belgium and issued as FIPS PUB 197 standard in Nov-2001 .AES isaAn <strong>iterative<\/strong> rather than <strong>Feistel<\/strong> cipher.ie, processes data as block of 4 columns of 4 bytes (128 bits) and operates on entire data block in every round .<\/p>\r\n&nbsp;\r\n\r\n<strong>Rounds in AES<\/strong>\r\n<ul>\r\n \t<li>Rounds are (almost) identical\r\n<ul>\r\n \t<li>First and last round are a little different<\/li>\r\n<\/ul>\r\n<\/li>\r\n<\/ul>\r\n<img class=\"alignnone size-full wp-image-248\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-4.png\" alt=\"\" width=\"528\" height=\"337\" \/>\r\n<p style=\"text-align: justify\">The input to the AES encryption and decryption algorithms is a single 128-bit block, depicted in FIPS PUB 197, as a square matrix of bytes .This block is copied into the State array, which is modified at each stage of encryption or decryption. After the final stage, State is copied to an output.<\/p>\r\n&nbsp;\r\n\r\nThe key is expanded into 44\/52\/60 lots of 32-bit words (see later), with 4 used in each round.\r\n\r\n&nbsp;\r\n<p style=\"text-align: justify\">The data computation then consists of an \u201cadd round key\u201d step, then 9\/11\/13 rounds with all 4 steps, and a final 10th\/12th\/14th step of byte subs + mix cols + add round key. This can be viewed as alternating XOR key &amp; scramble data bytes operations. All of the steps are easily reversed, and can be efficiently implemented using XOR\u2019s &amp; table lookups.<\/p>\r\n&nbsp;\r\n\r\n<img class=\"size-full wp-image-249 aligncenter\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-5.png\" alt=\"\" width=\"536\" height=\"412\" \/>\r\n\r\nThe above figure shows the overall structure of AES.\r\n\r\n&nbsp;\r\n\r\n<img class=\"size-full wp-image-250 alignleft\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-6.png\" alt=\"\" width=\"181\" height=\"214\" \/>\r\n\r\n&nbsp;\r\n\r\n&nbsp;\r\n\r\n&nbsp;\r\n\r\nData block viewed as 4-by-4 table of bytes and it is represented as 4 by 4 matrix of 8-bit bytes. Key is expanded to array of 32 bits words\r\n\r\n&nbsp;\r\n\r\n&nbsp;\r\n\r\n&nbsp;\r\n\r\n&nbsp;\r\n\r\n&nbsp;\r\n\r\nData Unit\r\n\r\n<img class=\"alignnone size-full wp-image-251\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-7.png\" alt=\"\" width=\"576\" height=\"399\" \/>\r\n\r\nThe above figure shows the data unit. Block to state transformation is done as shown in figure below.\r\n\r\n<img class=\"alignnone size-full wp-image-259\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-8.png\" alt=\"\" width=\"548\" height=\"320\" \/>\r\n<div>\r\n\r\nNow we are going see how the plaintext is converted to state.\r\n\r\n<\/div>\r\n<img class=\"alignnone size-full wp-image-261\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-9.png\" alt=\"\" width=\"568\" height=\"223\" \/>\r\n<ul>\r\n \t<li>Details of Each Round.<\/li>\r\n<\/ul>\r\n<p style=\"text-align: justify\">Each round consists of four operations namely SubBytes, ShiftRows , MixColumns, Add Round key as shown in figure.<\/p>\r\n<img class=\"alignnone size-full wp-image-262\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-10.png\" alt=\"\" width=\"435\" height=\"404\" \/>\r\n<div>\r\n<p style=\"text-align: justify\">Now discuss each of the four stages used in AES. The Substitute bytes stage uses an S-box to perform a byte-by-byte substitution of the block. There is a single 8-bit wide S-box used on every byte. This S-box is a permutation of all 256 8-bit values, constructed using a transformation which treats the values as polynomials in GF(28) \u2013 however it is fixed, so really only need to know the table when implementing. Decryption\u00a0<span style=\"text-align: initial;font-size: 1em\">requires the inverse of the table. These tables are given in Stallings Table 4.5.<\/span><\/p>\r\n\r\n<\/div>\r\n<p style=\"text-align: justify\">The table was designed to be resistant to known cryptanalytic attacks. Specifically, the Rijndael developers sought a design that has a low correlation between input bits and output bits, with the property that the output cannot be described as a simple mathematical function of the input, with no fixed points and no \u201copposite fixed points\u201d.<\/p>\r\n&nbsp;\r\n<ul>\r\n \t<li><strong>SubBytes: Byte Substitution<\/strong><\/li>\r\n<\/ul>\r\nThe SubBytes and InvSubBytes transformations are inverses of each other.\r\n\r\n&nbsp;\r\n\r\n<img class=\"alignnone size-full wp-image-263\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-11.png\" alt=\"\" width=\"551\" height=\"428\" \/>\r\n<div>\r\n<p style=\"text-align: justify\">A simple substitution of each byte provide a confusion. Uses one S-box of 16x16 bytes containing a permutation of all 256 8-bit values. Each byte of state is replaced by byte indexed by row (left 4-bits) &amp; column (right 4-bits).<\/p>\r\n\r\n<\/div>\r\nFor eg. byte {95} is replaced by byte in row 9 column 5 which has value {2A}\r\n\r\n&nbsp;\r\n\r\nThe SubBytes operation involves 16 independent byte-to-byte transformations.\r\n\r\n<img class=\"alignnone size-full wp-image-264\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-12.png\" alt=\"\" width=\"572\" height=\"329\" \/>\r\n\r\nInterpret the byte as two hexadecimal digits <em>xy<\/em> .Software implementation, use row (<em>x<\/em>) and column (<em>y<\/em>) as lookup pointer.\r\n\r\nIe, S<sub>1,1<\/sub> = xy<sub>16<\/sub>\r\n\r\nSubByte table is implements by table lookup as shown below.\r\n\r\n<img class=\"alignnone size-full wp-image-265\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-13.png\" alt=\"\" width=\"582\" height=\"352\" \/>\r\n\r\nThe InvSubByte table is:\r\n\r\n&nbsp;\r\n\r\n<img class=\"alignnone size-full wp-image-266\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-14.png\" alt=\"\" width=\"565\" height=\"344\" \/>\r\n\r\nThe following gives a sample of SubByte and InvSubByte operations.\r\n\r\n<img class=\"alignnone size-full wp-image-267\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-15.png\" alt=\"\" width=\"585\" height=\"167\" \/>\r\n\r\n&nbsp;\r\n\r\n<strong>Summary<\/strong>\r\n\r\n&nbsp;\r\n\r\nWe studied:\r\n\r\n&nbsp;\r\n\r\n\u2013\u00a0 the AES selection process\r\n\r\n\u2013\u00a0 the details of Rijndael \u2013 the AES cipher\r\n\r\n\u2013\u00a0 looked at the steps in each round\r\n\r\n\u2013\u00a0 the key expansion\r\n\r\n\u2013\u00a0 implementation aspects\r\n\r\n<table>\r\n<tbody>\r\n<tr>\r\n<td><strong>you can view video on Advanced Encryption Standard(part1)<\/strong><\/td>\r\n<td><a href=\"https:\/\/youtu.be\/fJhVQez6Zis\" target=\"_blank\" rel=\"noopener\"><img class=\"alignnone wp-image-120\" src=\"http:\/\/epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/2018\/11\/download.png\" alt=\"\" width=\"36\" height=\"36\" \/><\/a><\/td>\r\n<\/tr>\r\n<\/tbody>\r\n<\/table>\r\n\r\n<img class=\"alignnone size-full wp-image-268\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/Capture-47.jpg\" alt=\"\" width=\"672\" height=\"429\" \/>","rendered":"<div><span style=\"float: right\"><a href=\"https:\/\/youtu.be\/fJhVQez6Zis\" target=\"_blank\" rel=\"noopener\"><img decoding=\"async\" src=\"http:\/\/epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/2018\/11\/download.png\" alt=\"epgp books\" width=\"75px\" height=\"75px;\" \/><\/a><br \/>\n<\/span><\/div>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p><strong>AES (Part 1)<\/strong><\/p>\n<p>&nbsp;<\/p>\n<p style=\"text-align: justify\">Availability of advanced computing systems make ease to break the ciphers that we have discussed so far. A replacement of DES was needed because of small key size. Triple DES is too slow because we have to run 48 rounds effectively. So it is not a good solution. The Advanced Encryption Standard (AES) is a successor of many algorithms which are later proved to be vulnerable. The AES algorithm is a symmetric encryption algorithm which uses a single key for both encryption and decryption process. AES is also the official encryption used by the government of United States of America and Canada. It is used for both encryption of data in transit (data uploading and downloading) and for data at rest (Data in Hard Drive and other storage devices). Though they will use a 256 bit encryption key to encrypt the data.<\/p>\n<p>&nbsp;<\/p>\n<div>\n<p style=\"text-align: justify\">In 1997, National Institute for Standards and Technology send out for an open call for ciphers. Private key symmetric block cipher ,128-bit data, 128\/192\/256-bit keys ,Stronger &amp; faster than Triple-DES ,Provide full specification &amp; design details ,Both C and Java implementations were NIST\u2019s requirements for the AES candidate submissions. In fact, two set of criteria evolved. When NIST issued its original request for candidate\u00a0algorithm\u00a0 nominations\u00a0 in\u00a0\u00a0 1997,\u00a0 the\u00a0\u00a0 request\u00a0 stated\u00a0 that\u00a0\u00a0\u00a0 candidate algorithms would be compared based on the factors shown in Stallings Table5.1, which were used to evaluate field of 15 candidates to select shortlist of 5. These had categories of security, cost, and algorithm &amp; implementation characteristics. The\u00a0 final\u00a0 criteria\u00a0 evolved\u00a0 during\u00a0 the evaluation process, and were used to select Rijndael from that short-list and different categories of: general security, ease of software &amp; hardware implementation,\u00a0 implementation\u00a0 attacks,\u00a0 &amp;\u00a0 flexibility\u00a0 (in\u00a0 en\/decrypt,keying, other factors).<\/p>\n<\/div>\n<p>The AES shortlist of 5 ciphers as:<\/p>\n<ul>\n<li>MARS (IBM) &#8211; complex, fast, high security margin<\/li>\n<\/ul>\n<ul>\n<li>RC6 (USA) &#8211; v. simple, v. fast, low security margin<\/li>\n<\/ul>\n<ul>\n<li>Rijndael (Belgium) &#8211; clean, fast, good security margin<\/li>\n<\/ul>\n<ul>\n<li>Serpent (Euro) &#8211; slow, clean, v. high security margin<\/li>\n<\/ul>\n<ul>\n<li>Twofish (USA) &#8211; complex, v. fast, high security margin<\/li>\n<\/ul>\n<p style=\"text-align: justify\">Note mix of commercial (MARS, RC6, Twofish) verses academic (Rijndael, Serpent) proposals, sourced from various countries.<\/p>\n<p>&nbsp;<\/p>\n<p style=\"text-align: justify\">All were thought to be good \u2013 it came down to the best balance of attributes to meet criteria, in particular the balance between speed, security &amp; flexibility.<\/p>\n<p>&nbsp;<\/p>\n<p style=\"text-align: justify\">Rijndael was selected as the AES in Oct-2000. It was designed by Vincent Rijmen and Joan Daemen in Belgium and issued as FIPS PUB 197 standard in Nov-2001 .AES isaAn <strong>iterative<\/strong> rather than <strong>Feistel<\/strong> cipher.ie, processes data as block of 4 columns of 4 bytes (128 bits) and operates on entire data block in every round .<\/p>\n<p>&nbsp;<\/p>\n<p><strong>Rounds in AES<\/strong><\/p>\n<ul>\n<li>Rounds are (almost) identical\n<ul>\n<li>First and last round are a little different<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-248\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-4.png\" alt=\"\" width=\"528\" height=\"337\" srcset=\"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-4.png 528w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-4-300x191.png 300w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-4-65x41.png 65w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-4-225x144.png 225w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-4-350x223.png 350w\" sizes=\"auto, (max-width: 528px) 100vw, 528px\" \/><\/p>\n<p style=\"text-align: justify\">The input to the AES encryption and decryption algorithms is a single 128-bit block, depicted in FIPS PUB 197, as a square matrix of bytes .This block is copied into the State array, which is modified at each stage of encryption or decryption. After the final stage, State is copied to an output.<\/p>\n<p>&nbsp;<\/p>\n<p>The key is expanded into 44\/52\/60 lots of 32-bit words (see later), with 4 used in each round.<\/p>\n<p>&nbsp;<\/p>\n<p style=\"text-align: justify\">The data computation then consists of an \u201cadd round key\u201d step, then 9\/11\/13 rounds with all 4 steps, and a final 10th\/12th\/14th step of byte subs + mix cols + add round key. This can be viewed as alternating XOR key &amp; scramble data bytes operations. All of the steps are easily reversed, and can be efficiently implemented using XOR\u2019s &amp; table lookups.<\/p>\n<p>&nbsp;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-249 aligncenter\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-5.png\" alt=\"\" width=\"536\" height=\"412\" srcset=\"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-5.png 536w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-5-300x231.png 300w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-5-65x50.png 65w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-5-225x173.png 225w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-5-350x269.png 350w\" sizes=\"auto, (max-width: 536px) 100vw, 536px\" \/><\/p>\n<p>The above figure shows the overall structure of AES.<\/p>\n<p>&nbsp;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-250 alignleft\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-6.png\" alt=\"\" width=\"181\" height=\"214\" srcset=\"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-6.png 181w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-6-65x77.png 65w\" sizes=\"auto, (max-width: 181px) 100vw, 181px\" \/><\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>Data block viewed as 4-by-4 table of bytes and it is represented as 4 by 4 matrix of 8-bit bytes. Key is expanded to array of 32 bits words<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>Data Unit<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-251\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-7.png\" alt=\"\" width=\"576\" height=\"399\" srcset=\"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-7.png 576w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-7-300x208.png 300w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-7-65x45.png 65w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-7-225x156.png 225w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-7-350x242.png 350w\" sizes=\"auto, (max-width: 576px) 100vw, 576px\" \/><\/p>\n<p>The above figure shows the data unit. Block to state transformation is done as shown in figure below.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-259\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-8.png\" alt=\"\" width=\"548\" height=\"320\" srcset=\"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-8.png 548w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-8-300x175.png 300w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-8-65x38.png 65w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-8-225x131.png 225w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-8-350x204.png 350w\" sizes=\"auto, (max-width: 548px) 100vw, 548px\" \/><\/p>\n<div>\n<p>Now we are going see how the plaintext is converted to state.<\/p>\n<\/div>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-261\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-9.png\" alt=\"\" width=\"568\" height=\"223\" srcset=\"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-9.png 568w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-9-300x118.png 300w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-9-65x26.png 65w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-9-225x88.png 225w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-9-350x137.png 350w\" sizes=\"auto, (max-width: 568px) 100vw, 568px\" \/><\/p>\n<ul>\n<li>Details of Each Round.<\/li>\n<\/ul>\n<p style=\"text-align: justify\">Each round consists of four operations namely SubBytes, ShiftRows , MixColumns, Add Round key as shown in figure.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-262\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-10.png\" alt=\"\" width=\"435\" height=\"404\" srcset=\"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-10.png 435w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-10-300x279.png 300w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-10-65x60.png 65w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-10-225x209.png 225w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-10-350x325.png 350w\" sizes=\"auto, (max-width: 435px) 100vw, 435px\" \/><\/p>\n<div>\n<p style=\"text-align: justify\">Now discuss each of the four stages used in AES. The Substitute bytes stage uses an S-box to perform a byte-by-byte substitution of the block. There is a single 8-bit wide S-box used on every byte. This S-box is a permutation of all 256 8-bit values, constructed using a transformation which treats the values as polynomials in GF(28) \u2013 however it is fixed, so really only need to know the table when implementing. Decryption\u00a0<span style=\"text-align: initial;font-size: 1em\">requires the inverse of the table. These tables are given in Stallings Table 4.5.<\/span><\/p>\n<\/div>\n<p style=\"text-align: justify\">The table was designed to be resistant to known cryptanalytic attacks. Specifically, the Rijndael developers sought a design that has a low correlation between input bits and output bits, with the property that the output cannot be described as a simple mathematical function of the input, with no fixed points and no \u201copposite fixed points\u201d.<\/p>\n<p>&nbsp;<\/p>\n<ul>\n<li><strong>SubBytes: Byte Substitution<\/strong><\/li>\n<\/ul>\n<p>The SubBytes and InvSubBytes transformations are inverses of each other.<\/p>\n<p>&nbsp;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-263\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-11.png\" alt=\"\" width=\"551\" height=\"428\" srcset=\"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-11.png 551w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-11-300x233.png 300w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-11-65x50.png 65w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-11-225x175.png 225w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-11-350x272.png 350w\" sizes=\"auto, (max-width: 551px) 100vw, 551px\" \/><\/p>\n<div>\n<p style=\"text-align: justify\">A simple substitution of each byte provide a confusion. Uses one S-box of 16&#215;16 bytes containing a permutation of all 256 8-bit values. Each byte of state is replaced by byte indexed by row (left 4-bits) &amp; column (right 4-bits).<\/p>\n<\/div>\n<p>For eg. byte {95} is replaced by byte in row 9 column 5 which has value {2A}<\/p>\n<p>&nbsp;<\/p>\n<p>The SubBytes operation involves 16 independent byte-to-byte transformations.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-264\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-12.png\" alt=\"\" width=\"572\" height=\"329\" srcset=\"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-12.png 572w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-12-300x173.png 300w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-12-65x37.png 65w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-12-225x129.png 225w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-12-350x201.png 350w\" sizes=\"auto, (max-width: 572px) 100vw, 572px\" \/><\/p>\n<p>Interpret the byte as two hexadecimal digits <em>xy<\/em> .Software implementation, use row (<em>x<\/em>) and column (<em>y<\/em>) as lookup pointer.<\/p>\n<p>Ie, S<sub>1,1<\/sub> = xy<sub>16<\/sub><\/p>\n<p>SubByte table is implements by table lookup as shown below.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-265\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-13.png\" alt=\"\" width=\"582\" height=\"352\" srcset=\"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-13.png 582w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-13-300x181.png 300w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-13-65x39.png 65w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-13-225x136.png 225w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-13-350x212.png 350w\" sizes=\"auto, (max-width: 582px) 100vw, 582px\" \/><\/p>\n<p>The InvSubByte table is:<\/p>\n<p>&nbsp;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-266\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-14.png\" alt=\"\" width=\"565\" height=\"344\" srcset=\"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-14.png 565w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-14-300x183.png 300w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-14-65x40.png 65w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-14-225x137.png 225w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-14-350x213.png 350w\" sizes=\"auto, (max-width: 565px) 100vw, 565px\" \/><\/p>\n<p>The following gives a sample of SubByte and InvSubByte operations.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-267\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/2-15.png\" alt=\"\" width=\"585\" height=\"167\" srcset=\"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-15.png 585w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-15-300x86.png 300w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-15-65x19.png 65w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-15-225x64.png 225w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/2-15-350x100.png 350w\" sizes=\"auto, (max-width: 585px) 100vw, 585px\" \/><\/p>\n<p>&nbsp;<\/p>\n<p><strong>Summary<\/strong><\/p>\n<p>&nbsp;<\/p>\n<p>We studied:<\/p>\n<p>&nbsp;<\/p>\n<p>\u2013\u00a0 the AES selection process<\/p>\n<p>\u2013\u00a0 the details of Rijndael \u2013 the AES cipher<\/p>\n<p>\u2013\u00a0 looked at the steps in each round<\/p>\n<p>\u2013\u00a0 the key expansion<\/p>\n<p>\u2013\u00a0 implementation aspects<\/p>\n<table>\n<tbody>\n<tr>\n<td><strong>you can view video on Advanced Encryption Standard(part1)<\/strong><\/td>\n<td><a href=\"https:\/\/youtu.be\/fJhVQez6Zis\" target=\"_blank\" rel=\"noopener\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-120\" src=\"http:\/\/epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/2018\/11\/download.png\" alt=\"\" width=\"36\" height=\"36\" \/><\/a><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-268\" src=\"http:\/\/csp11.epgpbooks.inflibnet.ac.in\/wp-content\/uploads\/sites\/55\/2018\/07\/Capture-47.jpg\" alt=\"\" width=\"672\" height=\"429\" srcset=\"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/Capture-47.jpg 672w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/Capture-47-300x192.jpg 300w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/Capture-47-65x41.jpg 65w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/Capture-47-225x144.jpg 225w, https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-content\/uploads\/sites\/55\/2018\/07\/Capture-47-350x223.jpg 350w\" sizes=\"auto, (max-width: 672px) 100vw, 672px\" \/><\/p>\n","protected":false},"author":3,"menu_order":18,"template":"","meta":{"pb_show_title":"on","pb_short_title":"","pb_subtitle":"","pb_authors":[],"pb_section_license":""},"chapter-type":[],"contributor":[],"license":[],"class_list":["post-247","chapter","type-chapter","status-publish","hentry"],"part":3,"_links":{"self":[{"href":"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-json\/pressbooks\/v2\/chapters\/247","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-json\/pressbooks\/v2\/chapters"}],"about":[{"href":"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-json\/wp\/v2\/types\/chapter"}],"author":[{"embeddable":true,"href":"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-json\/wp\/v2\/users\/3"}],"version-history":[{"count":13,"href":"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-json\/pressbooks\/v2\/chapters\/247\/revisions"}],"predecessor-version":[{"id":569,"href":"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-json\/pressbooks\/v2\/chapters\/247\/revisions\/569"}],"part":[{"href":"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-json\/pressbooks\/v2\/parts\/3"}],"metadata":[{"href":"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-json\/pressbooks\/v2\/chapters\/247\/metadata\/"}],"wp:attachment":[{"href":"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-json\/wp\/v2\/media?parent=247"}],"wp:term":[{"taxonomy":"chapter-type","embeddable":true,"href":"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-json\/pressbooks\/v2\/chapter-type?post=247"},{"taxonomy":"contributor","embeddable":true,"href":"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-json\/wp\/v2\/contributor?post=247"},{"taxonomy":"license","embeddable":true,"href":"https:\/\/ebooks.inflibnet.ac.in\/csp11\/wp-json\/wp\/v2\/license?post=247"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}