Content deleted Content added
→Performance: Source doesn't mention that CPU, or the specifics for any CPU. Rather, the throughput of 'multiple GB/s' is reasonably inferred from the source in that the benchmark results themselves are in the multiple GB/s and require AES encryption. Tags: Mobile edit Mobile web edit |
→External links: demo link added |
||
(67 intermediate revisions by 46 users not shown) | |||
Line 1:
{{
{{Infobox block cipher
| name = Advanced Encryption Standard{{break}}(Rijndael)
Line 16:
| cryptanalysis = Attacks have been published that are computationally faster than a full [[brute-force attack]], though none as of 2023 are computationally feasible.<ref name="aesbc">{{cite web |url=http://research.microsoft.com/en-us/projects/cryptanalysis/aesbc.pdf |archive-url=https://web.archive.org/web/20160306104007/http://research.microsoft.com/en-us/projects/cryptanalysis/aesbc.pdf |archive-date=March 6, 2016 |title=Biclique Cryptanalysis of the Full AES |access-date=May 1, 2019 |url-status=dead |df=mdy-all}}</ref>
For AES-128, the key can be recovered with a [[computational complexity]] of 2<sup>126.1</sup> using the [[biclique attack]]. For biclique attacks on AES-192 and AES-256, the computational complexities of 2<sup>189.7</sup> and 2<sup>254.4</sup> respectively apply. [[Related-key attack]]s can break AES-
Another attack was blogged<ref name="Bruce Schneier">{{cite web |url=http://www.schneier.com/blog/archives/2009/07/another_new_aes.html |title=Another New AES Attack |author=Bruce Schneier |date=2009-07-30 |work=Schneier on Security, A blog covering security and security technology |access-date=2010-03-11 |url-status=live |archive-url=https://web.archive.org/web/20091005183132/http://www.schneier.com/blog/archives/2009/07/another_new_aes.html |archive-date=2009-10-05}}</ref> and released as a [[preprint]]<ref>{{cite web |url=https://eprint.iacr.org/2009/374 |title=Key Recovery Attacks of Practical Complexity on AES Variants With Up To 10 Rounds |author=Alex Biryukov |author2=Orr Dunkelman |author3=Nathan Keller |author4=Dmitry Khovratovich |author5=Adi Shamir |date=2009-08-19 |access-date=2010-03-11 |archive-url=https://web.archive.org/web/20100128050656/http://eprint.iacr.org/2009/374 |archive-date=28 January 2010 |url-status=live}}</ref> in 2009. This attack is against AES-256 that uses only two related keys and 2<sup>39</sup> time to recover the complete 256-bit key of a 9-round version, or 2<sup>45</sup> time for a 10-round version with a stronger type of related subkey attack, or 2<sup>70</sup> time for an 11-round version.
}}
The '''Advanced Encryption Standard''' ('''AES'''), also known by its original name '''Rijndael''' ({{IPA
AES is a variant of the Rijndael [[block cipher]]<ref name="Rijndael-ammended.pdf">{{cite web |url=http://csrc.nist.gov/archive/aes/rijndael/Rijndael-ammended.pdf#page=1 |title=AES Proposal: Rijndael |last1=Daemen |first1=Joan |last2=Rijmen |first2=Vincent |date=March 9, 2003 |publisher=National Institute of Standards and Technology |page=1 |access-date=21 February 2013 |url-status=live |archive-url=https://web.archive.org/web/20130305143117/http://csrc.nist.gov/archive/aes/rijndael/Rijndael-ammended.pdf#page=1 |archive-date=5 March 2013}}</ref> developed by two [[Belgium|Belgian]] cryptographers, [[Joan Daemen]] and [[Vincent Rijmen]], who submitted a proposal<ref name="Rijndaelv2">{{cite web |url=http://csrc.nist.gov/CryptoToolkit/aes/rijndael/Rijndael.pdf |url-status=dead |archive-url=https://web.archive.org/web/20070203204845/https://csrc.nist.gov/CryptoToolkit/aes/rijndael/Rijndael.pdf |archive-date=February 3, 2007 |title=AES Proposal: Rijndael |author=Joan Daemen and Vincent Rijmen |date=September 3, 1999}}</ref> to NIST during the [[Advanced Encryption Standard process|AES selection process]].<ref>{{Cite news |title=U.S. Selects a New Encryption Technique |
AES has been adopted by the [[Federal government of the United States|U.S. government]]. It supersedes the [[Data Encryption Standard]] (DES),<ref>{{cite news |url=http://www.findarticles.com/p/articles/mi_m0IKZ/is_3_107?pnum=2&opg=90984479 |title=NIST reports measurable success of Advanced Encryption Standard |work=Journal of Research of the National Institute of Standards and Technology |first=Harold B. |last=Westlund |date=2002 |url-status=dead |archive-url=https://web.archive.org/web/20071103105501/http://findarticles.com/p/articles/mi_m0IKZ/is_3_107?pnum=2&opg=90984479 |archive-date=2007-11-03}}</ref> which was published in 1977. The algorithm described by AES is a [[symmetric-key algorithm]], meaning the same key is used for both encrypting and decrypting the data.
Line 125:
AES has 10 rounds for 128-bit keys, 12 rounds for 192-bit keys, and 14 rounds for 256-bit keys.
By 2006, the best known attacks were on 7 rounds for 128-bit keys, 8 rounds for 192-bit keys, and 9 rounds for 256-bit keys.<ref name="improved">[[John Kelsey (cryptanalyst)|John Kelsey]], [[Stefan Lucks]], [[Bruce Schneier]], [[Mike Stay]], [[David A. Wagner|David Wagner]], and [[Doug Whiting]], ''Improved Cryptanalysis of Rijndael'', [[Fast Software Encryption]], 2000 pp213–230 {{cite web |title=Academic: Improved Cryptanalysis of Rijndael - Schneier on Security |url=http://www.schneier.com/paper-rijndael.html |url-status=live |archive-url=https://web.archive.org/web/20070223215007/http://www.schneier.com/paper-rijndael.html |archive-date=2007-02-23 |access-date=2007-03-06}}</ref>▼
=== Known attacks ===
For cryptographers, a [[cryptanalysis|cryptographic]] "break" is anything faster than a [[brute-force attack]]{{px2}}{{mdash}}{{
The key space increases by a factor of 2 for each additional bit of key length, and if every possible value of the key is equiprobable; this translates into a doubling of the average brute-force key search time with every additional bit of key length. This implies that the effort of a brute-force search increases exponentially with key length. Key length in itself does not imply security against attacks, since there are ciphers with very long keys that have been found to be vulnerable.
Line 137 ⟶ 135:
During the AES selection process, developers of competing algorithms wrote of Rijndael's algorithm "we are concerned about [its] use ... in security-critical applications."<ref name="rijndael-algebraic">
{{cite conference |author=Niels Ferguson |author-link=Niels Ferguson |author2=Richard Schroeppel |author2-link=Richard Schroeppel |author3=Doug Whiting |title=A simple algebraic representation of Rijndael |book-title=Proceedings of Selected Areas in Cryptography, 2001, Lecture Notes in Computer Science |pages=103–111 |publisher=[[Springer-Verlag]] |date=2001 |url=http://www.macfergus.com/pub/rdalgeq.html |format=PDF/[[PostScript]] |access-date=2006-10-06 |archive-url=https://web.archive.org/web/20061104080748/http://www.macfergus.com/pub/rdalgeq.html |archive-date=4 November 2006 |citeseerx=10.1.1.28.4921}}</ref> In October 2000, however, at the end of the AES selection process, [[Bruce Schneier]], a developer of the competing algorithm [[Twofish]], wrote that while he thought successful academic attacks on Rijndael would be developed someday, he "did not believe that anyone will ever discover an attack that will allow someone to read Rijndael traffic."<ref>Bruce Schneier, [http://www.schneier.com/crypto-gram-0010.html AES Announced] {{webarchive|url=https://web.archive.org/web/20090201005720/http://www.schneier.com/crypto-gram-0010.html |date=2009-02-01 }}, October 15, 2000</ref>
▲By 2006, the best known attacks were on 7 rounds for 128-bit keys, 8 rounds for 192-bit keys, and 9 rounds for 256-bit keys.<ref name="improved">[[John Kelsey (cryptanalyst)|John Kelsey]], [[Stefan Lucks]], [[Bruce Schneier]], [[Mike Stay]], [[David A. Wagner|David Wagner]], and [[Doug Whiting]], ''Improved Cryptanalysis of Rijndael'', [[Fast Software Encryption]], 2000 pp213–230 {{cite web |title=Academic: Improved Cryptanalysis of Rijndael - Schneier on Security |url=http://www.schneier.com/paper-rijndael.html |url-status=live |archive-url=https://web.archive.org/web/20070223215007/http://www.schneier.com/paper-rijndael.html |archive-date=2007-02-23 |access-date=2007-03-06}}</ref>
Until May 2009, the only successful published attacks against the full AES were [[side-channel attack]]s on some specific implementations. In 2009, a new [[related-key attack]] was discovered that exploits the simplicity of AES's key schedule and has a complexity of 2<sup>119</sup>. In December 2009 it was improved to 2<sup>99.5</sup>.<ref name=relkey /> This is a follow-up to an attack discovered earlier in 2009 by [[Alex Biryukov]], [[Dmitry Khovratovich]], and Ivica Nikolić, with a complexity of 2<sup>96</sup> for one out of every 2<sup>35</sup> keys.<ref>{{cite book |volume=5677 |chapter=Distinguisher and Related-Key Attack on the Full AES-256 |last1=Nikolić |first1=Ivica |title=Advances in Cryptology - CRYPTO 2009 |date=2009 |publisher=Springer Berlin / Heidelberg |isbn=978-3-642-03355-1 |pages=231–249 |doi=10.1007/978-3-642-03356-8_14 |series=Lecture Notes in Computer Science}}</ref> However, related-key attacks are not of concern in any properly designed cryptographic protocol, as a properly designed protocol (i.e., implementational software) will take care not to allow related keys, essentially by [[Related-key attack#Preventing related-key attacks|constraining]] an attacker's means of selecting keys for relatedness.
Another attack was blogged by Bruce Schneier<ref name="Bruce Schneier">{{cite web |url=http://www.schneier.com/blog/archives/2009/07/another_new_aes.html |title=Another New AES Attack |author=Bruce Schneier |date=2009-07-30 |work=Schneier on Security, A blog covering security and security technology |access-date=2010-03-11 |url-status=live |archive-url=https://web.archive.org/web/20091005183132/http://www.schneier.com/blog/archives/2009/07/another_new_aes.html |archive-date=2009-10-05}}</ref>
on July 30, 2009, and released as a [[preprint]]<ref>{{cite web |url=http://eprint.iacr.org/2009/374 |title=Key Recovery Attacks of Practical Complexity on AES Variants With Up To 10 Rounds |author=Alex Biryukov |author2=Orr Dunkelman |author3=Nathan Keller |author4=Dmitry Khovratovich |author5=Adi Shamir |date=2009-08-19 |access-date=2010-03-11 |archive-url=https://web.archive.org/web/20100128050656/http://eprint.iacr.org/2009/374 |archive-date=28 January 2010 |url-status=live}}</ref>
on August 3, 2009. This new attack, by Alex Biryukov, [[Orr Dunkelman]], [[Nathan Keller]], Dmitry Khovratovich, and [[Adi Shamir]], is against AES-256 that uses only two related keys and 2<sup>39</sup> time to recover the complete 256-bit key of a 9-round version, or 2<sup>45</sup> time for a 10-round version with a stronger type of related subkey attack, or 2<sup>70</sup> time for an 11-round version. 256-bit AES uses 14 rounds, so these attacks are not effective against full AES.
The practicality of these attacks with stronger related keys has been criticized,<ref>{{Cite book |title=On Some Symmetric Lightweight Cryptographic Designs |last=Agren |first=Martin |publisher=Dissertation, Lund University |year=2012 |pages=38–39}}</ref> for instance, by the paper on chosen-key-relations-in-the-middle attacks on AES-128 authored by Vincent Rijmen in 2010.<ref>{{cite journal |url=http://eprint.iacr.org/2010/337.pdf |title=Practical-Titled Attack on AES-128 Using Chosen-Text Relations |author=Vincent Rijmen |date=2010 |journal=IACR Cryptology ePrint Archive |url-status=live |archive-url=https://web.archive.org/web/20100702184311/http://eprint.iacr.org/2010/337.pdf |archive-date=2010-07-02}}</ref>
In November 2009, the first [[known-key distinguishing attack]] against a reduced 8-round version of AES-128 was released as a preprint.<ref>{{cite
This known-key distinguishing attack is an improvement of the rebound, or the start-from-the-middle attack, against AES-like permutations, which view two consecutive rounds of permutation as the application of a so-called Super-S-box. It works on the 8-round version of AES-128, with a time complexity of 2<sup>48</sup>, and a memory complexity of 2<sup>32</sup>. 128-bit AES uses 10 rounds, so this attack is not effective against full AES-128.
The first [[key-recovery attack]]s on full AES were by Andrey Bogdanov, Dmitry Khovratovich, and Christian Rechberger, and were published in 2011.<ref>{{
This is a very small gain, as a 126-bit key (instead of 128 bits) would still take billions of years to brute force on current and foreseeable hardware. Also, the authors calculate the best attack using their technique on AES with a 128-bit key requires storing 2<sup>88</sup> bits of data. That works out to about 38 trillion terabytes of data, which was more than all the data stored on all the computers on the planet in 2016.<ref>{{cite web |author=Jeffrey Goldberg |title=AES Encryption isn't Cracked |url=https://blog.agilebits.com/2011/08/18/aes-encryption-isnt-cracked/ |access-date=30 December 2014 |url-status=dead |archive-url=https://web.archive.org/web/20150108165723/https://blog.agilebits.com/2011/08/18/aes-encryption-isnt-cracked/ |archive-date=8 January 2015 |date=2011-08-18}}</ref> A paper in 2015 later improved the space complexity to 2<sup>56</sup> bits,<ref name=":0"/> which is 9007 terabytes (while still keeping a time complexity of approximately 2<sup>126
According to the [[Edward Snowden#Surveillance disclosures|Snowden documents]], the NSA is doing research on whether a cryptographic attack based on [[Kendall tau rank correlation coefficient|tau statistic]] may help to break AES.<ref>{{cite news |url=http://www.spiegel.de/international/germany/inside-the-nsa-s-war-on-internet-security-a-1010361.html |title=Prying Eyes: Inside the NSA's War on Internet Security |
At present, there is no known practical attack that would allow someone without knowledge of the key to read data encrypted by AES when correctly implemented.{{cn|date=September 2024}}
=== Side-channel attacks ===
Line 161:
[[Side-channel attack]]s do not attack the cipher as a [[black box]], and thus are not related to cipher security as defined in the classical context, but are important in practice. They attack implementations of the cipher on hardware or software systems that inadvertently leak data. There are several such known attacks on various implementations of AES.
In April 2005, [[Daniel J. Bernstein|D. J. Bernstein]] announced a cache-timing attack that he used to break a custom server that used [[OpenSSL]]'s AES encryption.<ref name="bernstein_timing">{{cite web |url=http://cr.yp.to/papers.html#cachetiming |title=Index of formal scientific papers |publisher=Cr.yp.to |access-date=2008-11-02 |url-status=live |archive-url=https://web.archive.org/web/20080917042758/http://cr.yp.to/papers.html#cachetiming |archive-date=2008-09-17}}</ref> The attack required over 200 million chosen plaintexts.<ref>{{cite web |url=http://www.schneier.com/blog/archives/2005/05/aes_timing_atta_1.html |title=AES Timing Attack |author=Bruce Schneier |date=17 May 2005 |access-date=2007-03-17 |archive-url=https://web.archive.org/web/20070212015727/http://www.schneier.com/blog/archives/2005/05/aes_timing_atta_1.html |archive-date=12 February 2007 |url-status=live}}</ref> The custom server was designed to give out as much timing information as possible (the server reports back the number of machine cycles taken by the encryption operation). However, as Bernstein pointed out, "reducing the precision of the server's timestamps, or eliminating them from the server's responses, does not stop the attack: the client simply uses round-trip timings based on its local clock, and compensates for the increased noise by averaging over a larger number of samples."<ref name="bernstein_timing" />
In October 2005, Dag Arne Osvik, [[Adi Shamir]] and [[Eran Tromer]] presented a paper demonstrating several cache-timing attacks against the implementations in AES found in OpenSSL and Linux's <code>dm-crypt</code> partition encryption function.<ref>{{cite
In December 2009 an attack on some hardware implementations was published that used [[differential fault analysis]] and allows recovery of a key with a complexity of 2<sup>32</sup>.<ref>{{cite journal |url=http://eprint.iacr.org/2009/581.pdf |title=A Diagonal Fault Attack on the Advanced Encryption Standard |author=Dhiman Saha |author2=Debdeep Mukhopadhyay |author3=Dipanwita RoyChowdhury|author3-link=Dipanwita Roy Chowdhury |access-date=2009-12-08 |journal=IACR Cryptology ePrint Archive |archive-url=https://web.archive.org/web/20091222070135/http://eprint.iacr.org/2009/581.pdf |archive-date=22 December 2009 |url-status=live}}</ref>
In November 2010 Endre Bangerter, David Gullasch and Stephan Krenn published a paper which described a practical approach to a "near real time" recovery of secret keys from AES-128 without the need for either cipher text or plaintext. The approach also works on AES-128 implementations that use compression tables, such as OpenSSL.<ref>{{cite journal |url=http://eprint.iacr.org/2010/594.pdf |title=Cache Games – Bringing Access-Based Cache Attacks on AES to Practice |author=Endre Bangerter |author2=David Gullasch |author3=Stephan Krenn |name-list-style=amp |date=2010 |journal=IACR Cryptology ePrint Archive |url-status=live |archive-url=https://web.archive.org/web/20101214092512/http://eprint.iacr.org/2010/594.pdf |archive-date=2010-12-14}}</ref> Like some earlier attacks, this one requires the ability to run unprivileged code on the system performing the AES encryption, which may be achieved by malware infection far more easily than commandeering the root account.<ref>{{cite web |url=http://news.ycombinator.com/item?id=1937902 |title=Breaking AES-128 in realtime, no ciphertext required |publisher=Hacker News |access-date=2012-12-23 |url-status=live |archive-url=https://web.archive.org/web/20111003193004/http://news.ycombinator.com/item?id=1937902 |archive-date=2011-10-03}}</ref>
In March 2016,
Many modern CPUs have built-in [[AES instruction set|hardware instructions for AES]], which protect against timing-related side-channel attacks.<ref>{{cite
=== Quantum attacks ===
AES-256 is considered to be [[
== NIST/CSEC validation ==
Line 185:
The Cryptographic Algorithm Validation Program (CAVP)<ref>{{cite web |url=http://csrc.nist.gov/groups/STM/cavp/index.html |title=NIST.gov – Computer Security Division – Computer Security Resource Center |publisher=Csrc.nist.gov |access-date=2012-12-23 |url-status=live |archive-url=https://web.archive.org/web/20130102044410/http://csrc.nist.gov/groups/STM/cavp/index.html |archive-date=2013-01-02}}</ref> allows for independent validation of the correct implementation of the AES algorithm. Successful validation results in being listed on the NIST validations page.<ref>{{cite web |url=http://csrc.nist.gov/groups/STM/cmvp/documents/140-1/140val-all.htm |title=Validated FIPS 140-1 and FIPS 140-2 Cryptographic Modules |url-status=dead |archive-url=https://web.archive.org/web/20141226152243/http://csrc.nist.gov/groups/STM/cmvp/documents/140-1/140val-all.htm |archive-date=2014-12-26 |access-date=2014-06-26}}</ref> This testing is a pre-requisite for the FIPS 140-2 module validation. However, successful CAVP validation in no way implies that the cryptographic module implementing the algorithm is secure. A cryptographic module lacking FIPS 140-2 validation or specific approval by the NSA is not deemed secure by the US Government and cannot be used to protect government data.<ref name="cnss.gov"/>
FIPS 140-2 validation is challenging to achieve both technically and fiscally.<ref name="openssl">{{cite web |author=OpenSSL, openssl@openssl.org |url=http://openssl.org/docs/fips/fipsnotes.html |title=OpenSSL's Notes about FIPS certification |publisher=Openssl.org |access-date=2012-12-23 |url-status=dead |archive-url=https://web.archive.org/web/20130102203126/http://www.openssl.org/docs/fips/fipsnotes.html |archive-date=2013-01-02}}</ref> There is a standardized battery of tests as well as an element of source code review that must be passed over a period of a few weeks. The cost to perform these tests through an approved laboratory can be significant (e.g., well over
== Test vectors ==
Line 195:
On a [[Pentium Pro]], AES encryption requires 18 clock cycles per byte (cpb),<ref>{{cite web |url=http://www.schneier.com/paper-aes-performance.pdf |title=Performance Comparisons of the AES submissions |last1=Schneier |first1=Bruce |last2=Kelsey |first2=John |last3=Whiting |first3=Doug |last4=Wagner |first4=David |last5=Hall |first5=Chris |last6=Ferguson |first6=Niels |date=1999-02-01 |access-date=2010-12-28 |url-status=live |archive-url=https://web.archive.org/web/20110622084238/http://www.schneier.com/paper-aes-performance.pdf |archive-date=2011-06-22}}</ref> equivalent to a throughput of about 11 MiB/s for a 200 MHz processor.
On [[Intel Core]] and [[AMD Ryzen]] CPUs supporting [[AES instruction set|AES-NI instruction set]] extensions, throughput can be multiple GiB/s.<ref>{{cite web |url=https://www.vortez.net/articles_pages/amd_ryzen_7_1700x_review,7.html |title=AMD Ryzen 7 1700X Review}}</ref> On
== Implementations ==
Line 202:
== See also ==
*[[
*[[Disk encryption]]
*[[Whirlpool (hash function)|Whirlpool]] – hash function created by Vincent Rijmen and Paulo S. L. M. Barreto
Line 208:
== Notes ==
<references group="note" />
== References ==
Line 221 ⟶ 220:
== External links ==
*{{cite web |title=256bit key – 128bit block – AES |work=Cryptography – 256 bit Ciphers: Reference source code and submissions to international cryptographic designs contests |publisher=EmbeddedSW |url=http://embeddedsw.net/Cipher_Reference_Home.html}}
*{{cite journal |title=Advanced Encryption Standard (AES) |date=26 November 2001 |journal=Federal Information Processing Standards |id=197 |url=
* [http://csrc.nist.gov/archive/aes/rijndael/wsdindex.html AES algorithm archive information – (old, unmaintained)]
*{{cite web |title=Part 3: Block ciphers |date=2010-12-15 |work=Information technology – Security techniques – Encryption algorithms |publisher=ISO |edition=2nd |id=ISO/IEC 18033-3:2010(E) |url=https://webstore.iec.ch/preview/info_isoiec18033-3%7Bed2.0%7Den.pdf |archive-url=https://ghostarchive.org/archive/20221009/https://webstore.iec.ch/preview/info_isoiec18033-3%7Bed2.0%7Den.pdf |archive-date=2022-10-09 |url-status=live}}
* [http://www.formaestudio.com/rijndaelinspector/archivos/Rijndael_Animation_v4_eng.swf Animation of Rijndael] – AES deeply explained and animated using Flash (by Enrique Zabala / University ORT / Montevideo / Uruguay). This animation (in English, Spanish, and German) is also part of [[CrypTool|CrypTool 1]] (menu Indiv. Procedures → Visualization of Algorithms → AES).
* [https://formaestudio.com/rijndaelinspector/archivos/Rijndael_Animation_v4_eng-html5.html HTML5 Animation of Rijndael] – Same Animation as above made in HTML5.
* [https://infsec.de/aes-in-excel-eng/ AES Demo in Excel] - Example implementation and demonstration in Excel (without macros) by Tim Wambach.
{{Cryptography navbox | block}}
Line 231:
[[Category:Advanced Encryption Standard]]
[[Category:Cryptography]]
[[Category:Belgian inventions]]
|