<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.yobi.be/index.php?action=history&amp;feed=atom&amp;title=NSC_Writeups</id>
	<title>NSC Writeups - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.yobi.be/index.php?action=history&amp;feed=atom&amp;title=NSC_Writeups"/>
	<link rel="alternate" type="text/html" href="https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;action=history"/>
	<updated>2026-05-22T15:16:17Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.43.8</generator>
	<entry>
		<id>https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=10550&amp;oldid=prev</id>
		<title>PhilippeTeuwen: /* Structure */</title>
		<link rel="alternate" type="text/html" href="https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=10550&amp;oldid=prev"/>
		<updated>2024-02-07T18:26:00Z</updated>

		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;Structure&lt;/span&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 18:26, 7 February 2024&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 19:&lt;/td&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 19:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==Structure==&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==Structure==&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Image:NSC2013.png|800px]]&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Image:NSC2013.png|800px]]&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-empty diff-side-deleted&quot;&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;The drawing depicts the detail of the computation of one AES round, more precisely just the first byte of the state (and the three next, depending on the same 4 input bytes).&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;The drawing depicts the detail of the computation of one AES round, more precisely just the first byte of the state (and the three next, depending on the same 4 input bytes).&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;The first and last rounds are different:&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;The first and last rounds are different:&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;

&lt;!-- diff cache key mediawiki-mw_:diff:1.41:old-10039:rev-10550:wikidiff2=table:1.14.1:bc2a06be --&gt;
&lt;/table&gt;</summary>
		<author><name>PhilippeTeuwen</name></author>
	</entry>
	<entry>
		<id>https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=10039&amp;oldid=prev</id>
		<title>PhilippeTeuwen at 22:26, 3 May 2016</title>
		<link rel="alternate" type="text/html" href="https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=10039&amp;oldid=prev"/>
		<updated>2016-05-03T22:26:33Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 22:26, 3 May 2016&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 247:&lt;/td&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 247:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt; ...&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt; ...&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* Compile and execute :) We obtain a file with the right tables in the same format as the one produced by the whitebox generator code.&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* Compile and execute :) We obtain a file with the right tables in the same format as the one produced by the whitebox generator code.&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-empty diff-side-deleted&quot;&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-empty diff-side-deleted&quot;&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==Source code==&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-empty diff-side-deleted&quot;&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;All scripts have finally been published here: https://github.com/SideChannelMarvels/Deadpool/tree/master/wbs_aes_nsc2013&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>PhilippeTeuwen</name></author>
	</entry>
	<entry>
		<id>https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=9629&amp;oldid=prev</id>
		<title>PhilippeTeuwen: /* Structure */</title>
		<link rel="alternate" type="text/html" href="https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=9629&amp;oldid=prev"/>
		<updated>2015-07-29T15:20:26Z</updated>

		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;Structure&lt;/span&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 15:20, 29 July 2015&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 40:&lt;/td&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 40:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;At the end, the binary contains those tables:&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;At the end, the binary contains those tables:&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* 3 xor tables of 256*256 values&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* 3 xor tables of 256*256 values&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* 9*16 round tables of 256 values&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* 9*16&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;*4&lt;/ins&gt; round tables of 256 values&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-empty diff-side-deleted&quot;&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* 16 final round tables of 256 values&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;A curiosity of the design when compared with classical Chow is that each round key is applied before MixCol and therefore split into 4 random shares (recombined later by the xors). So the first round tables contain already the first two round keys.&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;A curiosity of the design when compared with classical Chow is that each round key is applied before MixCol and therefore split into 4 random shares (recombined later by the xors). So the first round tables contain already the first two round keys.&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;If you want to compare with Chow, see [http://eprint.iacr.org/2013/104.pdf A Tutorial on White-box AES] by James A. Muir and zoom on this picture:&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;If you want to compare with Chow, see [http://eprint.iacr.org/2013/104.pdf A Tutorial on White-box AES] by James A. Muir and zoom on this picture:&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>PhilippeTeuwen</name></author>
	</entry>
	<entry>
		<id>https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=9454&amp;oldid=prev</id>
		<title>PhilippeTeuwen: /* Structure */</title>
		<link rel="alternate" type="text/html" href="https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=9454&amp;oldid=prev"/>
		<updated>2015-04-20T15:29:11Z</updated>

		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;Structure&lt;/span&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 15:29, 20 April 2015&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 29:&lt;/td&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 29:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* &amp;lt;math&amp;gt;T_i^1(x)=S(x \oplus \hat{k^0}[i])&amp;lt;/math&amp;gt; is similar to Chow&#039;s &amp;lt;math&amp;gt;T_i^r(x)&amp;lt;/math&amp;gt; but used only in first round&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* &amp;lt;math&amp;gt;T_i^1(x)=S(x \oplus \hat{k^0}[i])&amp;lt;/math&amp;gt; is similar to Chow&#039;s &amp;lt;math&amp;gt;T_i^r(x)&amp;lt;/math&amp;gt; but used only in first round&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* &amp;lt;math&amp;gt;S(x)&amp;lt;/math&amp;gt; is the AES SBox&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* &amp;lt;math&amp;gt;S(x)&amp;lt;/math&amp;gt; is the AES SBox&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* &amp;lt;math&amp;gt;Ty_{j,k}(x)=x\cdot MC_{j,k}&amp;lt;/math&amp;gt; is multiplication by a single element of&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt; AES&#039;&lt;/del&gt; [https://en.wikipedia.org/wiki/&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;MDS_matrix&lt;/del&gt; MDS matrix]&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* &amp;lt;math&amp;gt;Ty_{j,k}(x)=x\cdot MC_{j,k}&amp;lt;/math&amp;gt; is multiplication by a single element of [https://en.wikipedia.org/wiki/&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Rijndael_mix_columns&lt;/ins&gt; &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;AES&#039;&lt;/ins&gt;MDS matrix]&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* &amp;lt;math&amp;gt;K_{i,j}^r(x)=x \oplus \hat{k_j^r}[i]&amp;lt;/math&amp;gt; is xoring by a share j of round r key byte i.&amp;lt;br&amp;gt;There are 4 shares therefore &amp;lt;math&amp;gt;\hat{k^r}[i]=\hat{k_0^r}[i]\oplus \hat{k_1^r}[i]\oplus \hat{k_2^r}[i]\oplus \hat{k_3^r}[i]&amp;lt;/math&amp;gt;&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* &amp;lt;math&amp;gt;K_{i,j}^r(x)=x \oplus \hat{k_j^r}[i]&amp;lt;/math&amp;gt; is xoring by a share j of round r key byte i.&amp;lt;br&amp;gt;There are 4 shares therefore &amp;lt;math&amp;gt;\hat{k^r}[i]=\hat{k_0^r}[i]\oplus \hat{k_1^r}[i]\oplus \hat{k_2^r}[i]\oplus \hat{k_3^r}[i]&amp;lt;/math&amp;gt;&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* &amp;lt;math&amp;gt;B_j(x)&amp;lt;/math&amp;gt; for &amp;lt;math&amp;gt;j=0..3&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;B_j^{-1}(x)&amp;lt;/math&amp;gt; apply an intermediate encoding, a random 8-bit bijection, and its inverse&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* &amp;lt;math&amp;gt;B_j(x)&amp;lt;/math&amp;gt; for &amp;lt;math&amp;gt;j=0..3&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;B_j^{-1}(x)&amp;lt;/math&amp;gt; apply an intermediate encoding, a random 8-bit bijection, and its inverse&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>PhilippeTeuwen</name></author>
	</entry>
	<entry>
		<id>https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=9359&amp;oldid=prev</id>
		<title>PhilippeTeuwen: /* Attack */</title>
		<link rel="alternate" type="text/html" href="https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=9359&amp;oldid=prev"/>
		<updated>2015-03-01T11:01:42Z</updated>

		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;Attack&lt;/span&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 11:01, 1 March 2015&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 48:&lt;/td&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 48:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Because the internal encoding &amp;lt;math&amp;gt;X_2&amp;lt;/math&amp;gt; is the same between all rounds one may choose to attack a reduced version of AES with only 3 round keys but the problem is that the external encodings are completely unknown.&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Because the internal encoding &amp;lt;math&amp;gt;X_2&amp;lt;/math&amp;gt; is the same between all rounds one may choose to attack a reduced version of AES with only 3 round keys but the problem is that the external encodings are completely unknown.&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;I propose another attack that works against any of the intermediate rounds and doesn&#039;t require a ton of equations because... I hate math.&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;I propose another attack that works against any of the intermediate rounds and doesn&#039;t require a ton of equations because... I hate math.&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;Here attacking Round &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;2&lt;/del&gt; but any round between 2 and 9 will do.&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;Here attacking Round &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;3&lt;/ins&gt; but any round between 2 and 9 will do.&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;Let&#039;s guess the encoding of one single value &amp;lt;math&amp;gt;P=0&amp;lt;/math&amp;gt; in &amp;lt;math&amp;gt;X_2&amp;lt;/math&amp;gt;, the encoding table used between rounds.&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;Let&#039;s guess the encoding of one single value &amp;lt;math&amp;gt;P=0&amp;lt;/math&amp;gt; in &amp;lt;math&amp;gt;X_2&amp;lt;/math&amp;gt;, the encoding table used between rounds.&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;Encoding of &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; is &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt;: &amp;lt;math&amp;gt;X_2(P)=X&amp;lt;/math&amp;gt;.&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;Encoding of &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; is &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt;: &amp;lt;math&amp;gt;X_2(P)=X&amp;lt;/math&amp;gt;.&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;Try to find the corresponding key of &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;2nd&lt;/del&gt; round (so the &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;3rd&lt;/del&gt; round key):&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;Try to find the corresponding key of &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;3nd&lt;/ins&gt; round (so the &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;4rd&lt;/ins&gt; round key):&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* There are 16 groups of round tables for each round, taking 4 bytes as input and producing one byte (one round table group here is actually the 4 sub-round tables combined with the 3 xor tables)&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* There are 16 groups of round tables for each round, taking 4 bytes as input and producing one byte (one round table group here is actually the 4 sub-round tables combined with the 3 xor tables)&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* To attack one group, we fix the 4 input bytes as &amp;lt;math&amp;gt;X\!:\!X\!:\!X\!:\!X&amp;lt;/math&amp;gt; so the decoded input is supposed to be &amp;lt;math&amp;gt;0\!:\!0\!:\!0\!:\!0&amp;lt;/math&amp;gt;&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* To attack one group, we fix the 4 input bytes as &amp;lt;math&amp;gt;X\!:\!X\!:\!X\!:\!X&amp;lt;/math&amp;gt; so the decoded input is supposed to be &amp;lt;math&amp;gt;0\!:\!0\!:\!0\!:\!0&amp;lt;/math&amp;gt;&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>PhilippeTeuwen</name></author>
	</entry>
	<entry>
		<id>https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=9310&amp;oldid=prev</id>
		<title>PhilippeTeuwen: /* Attack */</title>
		<link rel="alternate" type="text/html" href="https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=9310&amp;oldid=prev"/>
		<updated>2015-02-09T22:32:02Z</updated>

		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;Attack&lt;/span&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 22:32, 9 February 2015&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 182:&lt;/td&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 182:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;F0:0E F1:1B F2:17 F3:FA F4:2E F5:D9 F6:8D F7:AB F8:0F F9:D0 FA:1F FB:FE FC:A1 FD:29 FE:8A FF:79&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;F0:0E F1:1B F2:17 F3:FA F4:2E F5:D9 F6:8D F7:AB F8:0F F9:D0 FA:1F FB:FE FC:A1 FD:29 FE:8A FF:79&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/pre&amp;gt;&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/pre&amp;gt;&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-empty diff-side-deleted&quot;&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;The full attack takes 3.1s on my laptop.&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-empty diff-side-deleted&quot;&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;Recovery of the external encodings is left as exercise for the reader ;-)&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;Recovery of the external encodings is left as exercise for the reader ;-)&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;Fun facts: if on the clear implementation we don&#039;t look for &amp;lt;math&amp;gt;0\!:\!0\!:\!0\!:\!0&amp;lt;/math&amp;gt; to &amp;lt;math&amp;gt;0&amp;lt;/math&amp;gt; but for &amp;lt;math&amp;gt;x\!:\!x\!:\!x\!:\!x&amp;lt;/math&amp;gt; to &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; where &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; is arbitrarily chosen, we still find the right round key but with a wrong &amp;lt;math&amp;gt;X_2&amp;lt;/math&amp;gt; mapping.&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;Fun facts: if on the clear implementation we don&#039;t look for &amp;lt;math&amp;gt;0\!:\!0\!:\!0\!:\!0&amp;lt;/math&amp;gt; to &amp;lt;math&amp;gt;0&amp;lt;/math&amp;gt; but for &amp;lt;math&amp;gt;x\!:\!x\!:\!x\!:\!x&amp;lt;/math&amp;gt; to &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; where &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; is arbitrarily chosen, we still find the right round key but with a wrong &amp;lt;math&amp;gt;X_2&amp;lt;/math&amp;gt; mapping.&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 187:&lt;/td&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 189:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;Thanks for your patience if you have read so far, feel free to share your thoughts with me ([https://twitter.com/doegox @doegox]).&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;Thanks for your patience if you have read so far, feel free to share your thoughts with me ([https://twitter.com/doegox @doegox]).&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;And thanks to Eloi for this great challenge and to Axel, Arnaud and Guy those who have shared their write-up!&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;And thanks to Eloi for this great challenge and to Axel, Arnaud and Guy those who have shared their write-up!&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-empty diff-side-deleted&quot;&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==Epilogue==&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==Epilogue==&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>PhilippeTeuwen</name></author>
	</entry>
	<entry>
		<id>https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=9309&amp;oldid=prev</id>
		<title>PhilippeTeuwen at 22:28, 9 February 2015</title>
		<link rel="alternate" type="text/html" href="https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=9309&amp;oldid=prev"/>
		<updated>2015-02-09T22:28:56Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 22:28, 9 February 2015&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 43:&lt;/td&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 43:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;A curiosity of the design when compared with classical Chow is that each round key is applied before MixCol and therefore split into 4 random shares (recombined later by the xors). So the first round tables contain already the first two round keys.&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;A curiosity of the design when compared with classical Chow is that each round key is applied before MixCol and therefore split into 4 random shares (recombined later by the xors). So the first round tables contain already the first two round keys.&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;If you want to compare with Chow, see [http://eprint.iacr.org/2013/104.pdf A Tutorial on White-box AES] by James A. Muir and zoom on this picture:&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;If you want to compare with Chow, see [http://eprint.iacr.org/2013/104.pdf A Tutorial on White-box AES] by James A. Muir and zoom on this picture:&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;[[Image:ChowAES.png|400px]]&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;[[Image:ChowAES.png|400px&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;|link=http://wiki.yobi.be/images/1/16/ChowAES.png&lt;/ins&gt;]]&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==Attack==&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==Attack==&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 146:&lt;/td&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 146:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;R3K candidate: 9BCD6D44A82E541396A30D3079A476B7&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;R3K candidate: 9BCD6D44A82E541396A30D3079A476B7&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/pre&amp;gt;&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/pre&amp;gt;&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Then it&#039;s just a matter of reversing the key scheduling of AES (yes it&#039;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt; &lt;/del&gt;s invertible) to go back to the first round key == AES key.&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Then it&#039;s just a matter of reversing the key scheduling of AES (yes it&#039;s invertible) to go back to the first round key == AES key.&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;pre&amp;gt;&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;pre&amp;gt;&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;K00: 4E5343234F707069646123B8DCE442D0&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;K00: 4E5343234F707069646123B8DCE442D0&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>PhilippeTeuwen</name></author>
	</entry>
	<entry>
		<id>https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=9308&amp;oldid=prev</id>
		<title>PhilippeTeuwen: /* Intro */</title>
		<link rel="alternate" type="text/html" href="https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=9308&amp;oldid=prev"/>
		<updated>2015-02-09T19:58:53Z</updated>

		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;Intro&lt;/span&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 19:58, 9 February 2015&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 10:&lt;/td&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 10:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;To break the challenge one has to guess what input to the white-boxed AES will produce the desired output such that MD5(nickname) == AES(serial) i.e. to revert the AES block such that serial=AES^-1(MD5(nickname)).&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;To break the challenge one has to guess what input to the white-boxed AES will produce the desired output such that MD5(nickname) == AES(serial) i.e. to revert the AES block such that serial=AES^-1(MD5(nickname)).&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;This white-box being made of look-up tables, it could be reverted step by step, round by round from output to input, but the AES key itself was left unbroken.&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;This white-box being made of look-up tables, it could be reverted step by step, round by round from output to input, but the AES key itself was left unbroken.&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;There are pointers in Shiftreduce&#039;s presentation to the BGE attack, a now classical attack against a no less classical Chow white-box AES implementation but this implementation is quite different from Chow and AFAIK Shiftreduce didn&#039;t recover the key.&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;There are pointers in Shiftreduce&#039;s presentation to the BGE attack, a now classical attack against a no less classical Chow white-box AES implementation but this implementation is quite different from Chow&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt; implementation&lt;/ins&gt; and AFAIK Shiftreduce didn&#039;t recover the key.&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Because I got curious about white-box only recently, I looked around what was publicly available and decided to investigate this one, a bit late for the competition I admit ;-)&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Because I got curious about white-box only recently, I looked around what was publicly available and decided to investigate this one, a bit late for the competition I admit ;-)&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>PhilippeTeuwen</name></author>
	</entry>
	<entry>
		<id>https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=9307&amp;oldid=prev</id>
		<title>PhilippeTeuwen: /* Intro */</title>
		<link rel="alternate" type="text/html" href="https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=9307&amp;oldid=prev"/>
		<updated>2015-02-09T19:56:31Z</updated>

		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;Intro&lt;/span&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 19:56, 9 February 2015&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 15:&lt;/td&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 15:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The advantage of starting late is that I can rely on the wonderful work published by those three people and concentrate directly on the white-box itself, sparing me the need to peel the onion at first (it would have made me crying for sure).&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The advantage of starting late is that I can rely on the wonderful work published by those three people and concentrate directly on the white-box itself, sparing me the need to peel the onion at first (it would have made me crying for sure).&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Later&lt;/del&gt;, Eloi even [http://pastebin.com/MvXpGZts published the code of his generator], very useful to study it and generate our own challenges (under Linux)!&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;After the challenge period&lt;/ins&gt;, Eloi even [http://pastebin.com/MvXpGZts published the code of his generator], very useful to study it and generate our own challenges (under Linux)!&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-empty diff-side-deleted&quot;&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==Structure==&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==Structure==&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Image:NSC2013.png|800px]]&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Image:NSC2013.png|800px]]&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>PhilippeTeuwen</name></author>
	</entry>
	<entry>
		<id>https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=9306&amp;oldid=prev</id>
		<title>PhilippeTeuwen: Created page with &quot;=Oppida/NoSuchCon challenge= ==Intro== In April 2013, Oppida [http://seclists.org/fulldisclosure/2013/Apr/133 proposed a challenge] associated with NoSuchCon 2013. &lt;br&gt;The cha...&quot;</title>
		<link rel="alternate" type="text/html" href="https://wiki.yobi.be/index.php?title=NSC_Writeups&amp;diff=9306&amp;oldid=prev"/>
		<updated>2015-02-09T19:47:46Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;=Oppida/NoSuchCon challenge= ==Intro== In April 2013, Oppida [http://seclists.org/fulldisclosure/2013/Apr/133 proposed a challenge] associated with NoSuchCon 2013. &amp;lt;br&amp;gt;The cha...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;=Oppida/NoSuchCon challenge=&lt;br /&gt;
==Intro==&lt;br /&gt;
In April 2013, Oppida [http://seclists.org/fulldisclosure/2013/Apr/133 proposed a challenge] associated with NoSuchCon 2013.&lt;br /&gt;
&amp;lt;br&amp;gt;The challenge was designed by Eloi Vanderbéken [https://twitter.com/elvanderb @elvanderb] and consisted into a PE binary embedding a white-box AES implementation. &lt;br /&gt;
&amp;lt;br&amp;gt;It was of &amp;quot;keygen-me&amp;quot; type.&lt;br /&gt;
&amp;lt;br&amp;gt;The challenge was broken by a few people and some write-ups are available:&lt;br /&gt;
* by Axel [https://twitter.com/0vercl0k @0vercl0k]: [http://0vercl0k.tuxfamily.org/bl0g/?p=253 AES Whitebox Unboxing: No Such Problem]&lt;br /&gt;
* by Arnaud [https://twitter.com/kutioo @kutioo]: [http://kutioo.blogspot.be/2013/05/nosuchcon-2013-challenge-write-up-and.html NoSuchCon 2013 challenge - Write up and Methodology]&lt;br /&gt;
* by Guy [https://twitter.com/Shiftreduce @Shiftreduce]: [http://archive.hack.lu/2013/Interactive%20deobfuscation.ppt Interactive deobfuscation (ppt)]&lt;br /&gt;
To break the challenge one has to guess what input to the white-boxed AES will produce the desired output such that MD5(nickname) == AES(serial) i.e. to revert the AES block such that serial=AES^-1(MD5(nickname)).&lt;br /&gt;
&amp;lt;br&amp;gt;This white-box being made of look-up tables, it could be reverted step by step, round by round from output to input, but the AES key itself was left unbroken.&lt;br /&gt;
&amp;lt;br&amp;gt;There are pointers in Shiftreduce&amp;#039;s presentation to the BGE attack, a now classical attack against a no less classical Chow white-box AES implementation but this implementation is quite different from Chow and AFAIK Shiftreduce didn&amp;#039;t recover the key.&lt;br /&gt;
&lt;br /&gt;
Because I got curious about white-box only recently, I looked around what was publicly available and decided to investigate this one, a bit late for the competition I admit ;-)&lt;br /&gt;
&lt;br /&gt;
The advantage of starting late is that I can rely on the wonderful work published by those three people and concentrate directly on the white-box itself, sparing me the need to peel the onion at first (it would have made me crying for sure).&lt;br /&gt;
&amp;lt;br&amp;gt;Later, Eloi even [http://pastebin.com/MvXpGZts published the code of his generator], very useful to study it and generate our own challenges (under Linux)!&lt;br /&gt;
==Structure==&lt;br /&gt;
[[Image:NSC2013.png|800px]]&lt;br /&gt;
&amp;lt;br&amp;gt;The drawing depicts the detail of the computation of one AES round, more precisely just the first byte of the state (and the three next, depending on the same 4 input bytes).&lt;br /&gt;
&amp;lt;br&amp;gt;The first and last rounds are different:&lt;br /&gt;
* First round is similar to intern rounds but the tables applying the SBox here are also applying the initial round key in a so-called TBox and the input is not encoded by &amp;lt;math&amp;gt;X_2&amp;lt;/math&amp;gt; but by a so-called external encoding &amp;lt;math&amp;gt;F&amp;lt;/math&amp;gt; to be reverted.&lt;br /&gt;
* Last round as usual doesn&amp;#039;t contain the MixColumn operation therefore is much simpler but another external encoding &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; is applied on the output.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Notations of the drawing (please forgive my lack of math strictness):&lt;br /&gt;
&amp;lt;br&amp;gt;All datapaths are 8-bit wide&lt;br /&gt;
* &amp;lt;math&amp;gt;F^{-1}(x)&amp;lt;/math&amp;gt; applies the inverse input encoding, a random 8-bit bijection&lt;br /&gt;
* &amp;lt;math&amp;gt;G(x)&amp;lt;/math&amp;gt; applies the output encoding, a random 8-bit bijection&lt;br /&gt;
* &amp;lt;math&amp;gt;T_i^1(x)=S(x \oplus \hat{k^0}[i])&amp;lt;/math&amp;gt; is similar to Chow&amp;#039;s &amp;lt;math&amp;gt;T_i^r(x)&amp;lt;/math&amp;gt; but used only in first round&lt;br /&gt;
* &amp;lt;math&amp;gt;S(x)&amp;lt;/math&amp;gt; is the AES SBox&lt;br /&gt;
* &amp;lt;math&amp;gt;Ty_{j,k}(x)=x\cdot MC_{j,k}&amp;lt;/math&amp;gt; is multiplication by a single element of AES&amp;#039; [https://en.wikipedia.org/wiki/MDS_matrix MDS matrix]&lt;br /&gt;
* &amp;lt;math&amp;gt;K_{i,j}^r(x)=x \oplus \hat{k_j^r}[i]&amp;lt;/math&amp;gt; is xoring by a share j of round r key byte i.&amp;lt;br&amp;gt;There are 4 shares therefore &amp;lt;math&amp;gt;\hat{k^r}[i]=\hat{k_0^r}[i]\oplus \hat{k_1^r}[i]\oplus \hat{k_2^r}[i]\oplus \hat{k_3^r}[i]&amp;lt;/math&amp;gt;&lt;br /&gt;
* &amp;lt;math&amp;gt;B_j(x)&amp;lt;/math&amp;gt; for &amp;lt;math&amp;gt;j=0..3&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;B_j^{-1}(x)&amp;lt;/math&amp;gt; apply an intermediate encoding, a random 8-bit bijection, and its inverse&lt;br /&gt;
* &amp;lt;math&amp;gt;X_0(x), X_1(x), X_2(x)&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;X_0^{-1}(x), X_1^{-1}(x), X_2^{-1}(x)&amp;lt;/math&amp;gt; apply an intermediate encoding, a random 8-bit bijection, and its inverse. &amp;lt;br&amp;gt;So &amp;lt;math&amp;gt;X_2(x)&amp;lt;/math&amp;gt; encodes intermediate results between rounds.&lt;br /&gt;
* &amp;lt;math&amp;gt;xor&amp;lt;/math&amp;gt; is a byte xor 2x8-bit -&amp;gt; 8-bit&lt;br /&gt;
&lt;br /&gt;
So this design makes use of 9 random substitution tables (that you don&amp;#039;t find as such in the binary but which are used during generation) and their inverse:&lt;br /&gt;
* &amp;lt;math&amp;gt;F, G, B_0, B_1, B_2, B_3, X_0, X_1, X_2&amp;lt;/math&amp;gt;&lt;br /&gt;
and the same substitutions are re-used in all rounds (otherwise the 3 large xor tables would have to be duplicated many times)&lt;br /&gt;
&amp;lt;br&amp;gt;At the end, the binary contains those tables:&lt;br /&gt;
* 3 xor tables of 256*256 values&lt;br /&gt;
* 9*16 round tables of 256 values&lt;br /&gt;
A curiosity of the design when compared with classical Chow is that each round key is applied before MixCol and therefore split into 4 random shares (recombined later by the xors). So the first round tables contain already the first two round keys.&lt;br /&gt;
&amp;lt;br&amp;gt;If you want to compare with Chow, see [http://eprint.iacr.org/2013/104.pdf A Tutorial on White-box AES] by James A. Muir and zoom on this picture:&lt;br /&gt;
&amp;lt;br&amp;gt;[[Image:ChowAES.png|400px]]&lt;br /&gt;
&lt;br /&gt;
==Attack==&lt;br /&gt;
Because the internal encoding &amp;lt;math&amp;gt;X_2&amp;lt;/math&amp;gt; is the same between all rounds one may choose to attack a reduced version of AES with only 3 round keys but the problem is that the external encodings are completely unknown.&lt;br /&gt;
&amp;lt;br&amp;gt;I propose another attack that works against any of the intermediate rounds and doesn&amp;#039;t require a ton of equations because... I hate math.&lt;br /&gt;
&amp;lt;br&amp;gt;Here attacking Round 2 but any round between 2 and 9 will do.&lt;br /&gt;
&amp;lt;br&amp;gt;Let&amp;#039;s guess the encoding of one single value &amp;lt;math&amp;gt;P=0&amp;lt;/math&amp;gt; in &amp;lt;math&amp;gt;X_2&amp;lt;/math&amp;gt;, the encoding table used between rounds.&lt;br /&gt;
&amp;lt;br&amp;gt;Encoding of &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; is &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt;: &amp;lt;math&amp;gt;X_2(P)=X&amp;lt;/math&amp;gt;.&lt;br /&gt;
&amp;lt;br&amp;gt;Try to find the corresponding key of 2nd round (so the 3rd round key):&lt;br /&gt;
* There are 16 groups of round tables for each round, taking 4 bytes as input and producing one byte (one round table group here is actually the 4 sub-round tables combined with the 3 xor tables)&lt;br /&gt;
* To attack one group, we fix the 4 input bytes as &amp;lt;math&amp;gt;X\!:\!X\!:\!X\!:\!X&amp;lt;/math&amp;gt; so the decoded input is supposed to be &amp;lt;math&amp;gt;0\!:\!0\!:\!0\!:\!0&amp;lt;/math&amp;gt;&lt;br /&gt;
* We compute the encoded output byte out and compare it with &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt;&lt;br /&gt;
** if output &amp;lt;math&amp;gt;Y \neq X&amp;lt;/math&amp;gt;, we create a new input &amp;lt;math&amp;gt;Y\!:\!X\!:\!X\!:\!X&amp;lt;/math&amp;gt; and chain executions of that group till output &amp;lt;math&amp;gt; = X&amp;lt;/math&amp;gt; so we know decoded output is &amp;lt;math&amp;gt;P=0&amp;lt;/math&amp;gt;&lt;br /&gt;
* The required number of iterations to reach an output &amp;lt;math&amp;gt; = X&amp;lt;/math&amp;gt; is then compared with a clean implementation without encodings to check which k candidates require the same number of iterations, so here going from &amp;lt;math&amp;gt;0\!:\!0\!:\!0\!:\!0&amp;lt;/math&amp;gt; to &amp;lt;math&amp;gt;0&amp;lt;/math&amp;gt;&lt;br /&gt;
Example requiring 3 iterations:&lt;br /&gt;
&amp;lt;br&amp;gt;[[Image:NSC2013_attack.png]]&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Clean group implementation:&lt;br /&gt;
&amp;lt;br&amp;gt;[[Image:NSC2013_clean.png]]&lt;br /&gt;
&lt;br /&gt;
So from each initial encoding guess we get typically something like this: (i=ith byte, n=nr of iterations)&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&amp;lt;tt&amp;gt;Hypothesis 00 is encoded as 00&lt;br /&gt;
&amp;lt;br&amp;gt;i=00 n=10 k= 12 22 63 87 C5 D7 F0 F4&lt;br /&gt;
&amp;lt;br&amp;gt;i=04 n=21 k= 05 63 F0 FA&lt;br /&gt;
&amp;lt;br&amp;gt;i=08 n=E8 k= 1E 63 6D 78 A6 FE&lt;br /&gt;
&amp;lt;br&amp;gt;i=12 n=0B k= 63&lt;br /&gt;
&amp;lt;br&amp;gt;i=01 n=64 k= 00 05 22 23 63 A2 A9 BF C5 C9 D0 DF F1&lt;br /&gt;
&amp;lt;br&amp;gt;i=05 n=7D k= 2E 63 70 97 AF&lt;br /&gt;
&amp;lt;br&amp;gt;i=09 n=1E k= 04 05 36 54 63 A6 AF B7 C0 E7 EE FA&lt;br /&gt;
&amp;lt;br&amp;gt;i=13 n=5A k= 2C 33 3B 3F 63 68 81 88 8F 94 A1 A3 AA CF DB ED F7&lt;br /&gt;
&amp;lt;br&amp;gt;i=02 n=42 k= 42 63 74 D1&lt;br /&gt;
&amp;lt;br&amp;gt;i=06 n=3D k= 63 73 A3&lt;br /&gt;
&amp;lt;br&amp;gt;i=10 n=AC k= 0D 38 44 63 A6 E9&lt;br /&gt;
&amp;lt;br&amp;gt;i=14 n=78 k= 07 1B 1E 33 45 57 61 63 68 88 8F 95 A3 AA B7 D1 DB ED F6 F7&lt;br /&gt;
&amp;lt;br&amp;gt;i=03 n=D0 k= 0E 12 22 63 87 C5 D7 D8 F0 F4 FB&lt;br /&gt;
&amp;lt;br&amp;gt;i=07 n=4A k= 02 63 8F A6&lt;br /&gt;
&amp;lt;br&amp;gt;i=11 n=100 k= 0E 57 63 76 78 A6 E5 EA&lt;br /&gt;
&amp;lt;br&amp;gt;i=15 n=E6 k= 11 33 4B 56 5A 63 6B 7A 8F 93 B1 ED&lt;br /&gt;
&amp;lt;/tt&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;Then we can take a second guess for the encoding value of &amp;lt;math&amp;gt;P=1&amp;lt;/math&amp;gt; and filter the k candidates to keep those which are compatible with those we kept.&lt;br /&gt;
&amp;lt;br&amp;gt;If no k candidates is left for one of the round key bytes, we backtrack our encoding guesses.&lt;br /&gt;
&amp;lt;br&amp;gt;Here there is already no key candidate left.&lt;br /&gt;
&amp;lt;br&amp;gt;So we backtrack and try another guess for the encoding of &amp;lt;math&amp;gt;P=0&amp;lt;/math&amp;gt; till...&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&amp;lt;tt&amp;gt;Hypothesis 00 is encoded as CE&lt;br /&gt;
&amp;lt;br&amp;gt;i=00 n=AE k= 18 63 70 72 74 77 7D 8D &amp;#039;&amp;#039;&amp;#039;9B&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=04 n=78 k= 04 05 2D 36 3F 40 46 54 63 78 89 8E 9B A6 AF B7 C0 &amp;#039;&amp;#039;&amp;#039;CD&amp;#039;&amp;#039;&amp;#039; E7 EE FA&lt;br /&gt;
&amp;lt;br&amp;gt;i=08 n=E8 k= 1E 63 &amp;#039;&amp;#039;&amp;#039;6D&amp;#039;&amp;#039;&amp;#039; 78 A6 FE&lt;br /&gt;
&amp;lt;br&amp;gt;i=12 n=F0 k= 07 1A 1B 1E 33 36 &amp;#039;&amp;#039;&amp;#039;44&amp;#039;&amp;#039;&amp;#039; 45 4C 57 5D 61 63 68 6F 88 8F 95 A3 AA B7 C5 D1 DB ED F6 F7 FC&lt;br /&gt;
&amp;lt;br&amp;gt;i=01 n=EE k= 0B 41 4E 63 76 &amp;#039;&amp;#039;&amp;#039;A8&amp;#039;&amp;#039;&amp;#039; BB CA DE EB&lt;br /&gt;
&amp;lt;br&amp;gt;i=05 n=7D k= &amp;#039;&amp;#039;&amp;#039;2E&amp;#039;&amp;#039;&amp;#039; 63 70 97 AF&lt;br /&gt;
&amp;lt;br&amp;gt;i=09 n=1E k= 04 05 36 &amp;#039;&amp;#039;&amp;#039;54&amp;#039;&amp;#039;&amp;#039; 63 A6 AF B7 C0 E7 EE FA&lt;br /&gt;
&amp;lt;br&amp;gt;i=13 n=100 k= &amp;#039;&amp;#039;&amp;#039;13&amp;#039;&amp;#039;&amp;#039; 33 45 49 57 63 8F BF C5 C7 ED&lt;br /&gt;
&amp;lt;br&amp;gt;i=02 n=47 k= 63 &amp;#039;&amp;#039;&amp;#039;96&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=06 n=3D k= 63 73 &amp;#039;&amp;#039;&amp;#039;A3&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=10 n=AC k= &amp;#039;&amp;#039;&amp;#039;0D&amp;#039;&amp;#039;&amp;#039; 38 44 63 A6 E9&lt;br /&gt;
&amp;lt;br&amp;gt;i=14 n=DF k= &amp;#039;&amp;#039;&amp;#039;30&amp;#039;&amp;#039;&amp;#039; 63 F9&lt;br /&gt;
&amp;lt;br&amp;gt;i=03 n=D8 k= 0A 12 17 22 34 4F 52 58 63 74 &amp;#039;&amp;#039;&amp;#039;79&amp;#039;&amp;#039;&amp;#039; 95 B7 C5 CF D7 E2 ED&lt;br /&gt;
&amp;lt;br&amp;gt;i=07 n=B3 k= 63 9D &amp;#039;&amp;#039;&amp;#039;A4&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=11 n=100 k= 0E 57 63 &amp;#039;&amp;#039;&amp;#039;76&amp;#039;&amp;#039;&amp;#039; 78 A6 E5 EA&lt;br /&gt;
&amp;lt;br&amp;gt;i=15 n=78 k= 07 1B 1E 33 45 57 61 63 68 88 8F 95 A3 AA &amp;#039;&amp;#039;&amp;#039;B7&amp;#039;&amp;#039;&amp;#039; D1 DB ED F6 F7&lt;br /&gt;
&amp;lt;/tt&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;(in bold I already highlight the correct key bytes that we&amp;#039;ll recover in a moment)&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&amp;lt;tt&amp;gt;Hypothesis 01 is encoded as 10&lt;br /&gt;
&amp;lt;br&amp;gt;i=00 n=28 k= 7D &amp;#039;&amp;#039;&amp;#039;9B&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=04 n=24 k= 2D &amp;#039;&amp;#039;&amp;#039;CD&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=08 n=E8 k= &amp;#039;&amp;#039;&amp;#039;6D&amp;#039;&amp;#039;&amp;#039; FE&lt;br /&gt;
&amp;lt;br&amp;gt;i=12 n=67 k= &amp;#039;&amp;#039;&amp;#039;44&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=01 n=B0 k= 63 &amp;#039;&amp;#039;&amp;#039;A8&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=05 n=7D k= &amp;#039;&amp;#039;&amp;#039;2E&amp;#039;&amp;#039;&amp;#039; 70&lt;br /&gt;
&amp;lt;br&amp;gt;i=09 n=82 k= &amp;#039;&amp;#039;&amp;#039;54&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=13 n=38 k= &amp;#039;&amp;#039;&amp;#039;13&amp;#039;&amp;#039;&amp;#039; C7&lt;br /&gt;
&amp;lt;br&amp;gt;i=02 n=48 k= &amp;#039;&amp;#039;&amp;#039;96&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=06 n=3D k= &amp;#039;&amp;#039;&amp;#039;A3&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=10 n=AC k= &amp;#039;&amp;#039;&amp;#039;0D&amp;#039;&amp;#039;&amp;#039; 38 44&lt;br /&gt;
&amp;lt;br&amp;gt;i=14 n=1C k= &amp;#039;&amp;#039;&amp;#039;30&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=03 n=6C k= &amp;#039;&amp;#039;&amp;#039;79&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=07 n=4A k= &amp;#039;&amp;#039;&amp;#039;A4&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=11 n=100 k= &amp;#039;&amp;#039;&amp;#039;76&amp;#039;&amp;#039;&amp;#039; EA&lt;br /&gt;
&amp;lt;br&amp;gt;i=15 n=44 k= 1B &amp;#039;&amp;#039;&amp;#039;B7&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;Hypothesis 02 is encoded as A0&lt;br /&gt;
&amp;lt;br&amp;gt;i=00 n=1E k= &amp;#039;&amp;#039;&amp;#039;9B&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=04 n=21 k= &amp;#039;&amp;#039;&amp;#039;CD&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=08 n=E8 k= &amp;#039;&amp;#039;&amp;#039;6D&amp;#039;&amp;#039;&amp;#039; FE&lt;br /&gt;
&amp;lt;br&amp;gt;i=12 n=E8 k= &amp;#039;&amp;#039;&amp;#039;44&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=01 n=87 k= &amp;#039;&amp;#039;&amp;#039;A8&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=05 n=36 k= &amp;#039;&amp;#039;&amp;#039;2E&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=09 n=82 k= &amp;#039;&amp;#039;&amp;#039;54&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=13 n=B3 k= &amp;#039;&amp;#039;&amp;#039;13&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=02 n=3B k= &amp;#039;&amp;#039;&amp;#039;96&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=06 n=11 k= &amp;#039;&amp;#039;&amp;#039;A3&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=10 n=35 k= &amp;#039;&amp;#039;&amp;#039;0D&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=14 n=C8 k= &amp;#039;&amp;#039;&amp;#039;30&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=03 n=2F k= &amp;#039;&amp;#039;&amp;#039;79&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=07 n=4A k= &amp;#039;&amp;#039;&amp;#039;A4&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;br&amp;gt;i=11 n=100 k= &amp;#039;&amp;#039;&amp;#039;76&amp;#039;&amp;#039;&amp;#039; EA&lt;br /&gt;
&amp;lt;br&amp;gt;i=15 n=48 k= &amp;#039;&amp;#039;&amp;#039;B7&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And so on.&lt;br /&gt;
&amp;lt;br&amp;gt;At the end only one possible key round is left so we found the round key and the complete &amp;lt;math&amp;gt;X_2&amp;lt;/math&amp;gt; mapping.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
R3K candidate: 9BCD6D44A82E541396A30D3079A476B7&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Then it&amp;#039;s just a matter of reversing the key scheduling of AES (yes it&amp;#039; s invertible) to go back to the first round key == AES key.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
K00: 4E5343234F707069646123B8DCE442D0&lt;br /&gt;
K01: 267F33A5690F43CC0D6E6074D18A22A4&lt;br /&gt;
K02: 5AEC7A9B33E339573E8D5923EF077B87&lt;br /&gt;
K03: 9BCD6D44A82E541396A30D3079A476B7  &amp;lt;=&lt;br /&gt;
K04: DAF5C4F272DB90E1E4789DD19DDCEB66&lt;br /&gt;
K05: 4C1CF7AC3EC7674DDABFFA9C476311FA&lt;br /&gt;
K06: 979EDA0CA959BD4173E647DD34855627&lt;br /&gt;
K07: 402F1614E976AB559A90EC88AE15BAAF&lt;br /&gt;
K08: 99DB6FF070ADC4A5EA3D282D44289282&lt;br /&gt;
K09: B6947CEBC639B84E2C049063682C02E1&lt;br /&gt;
K10: F1E384AE37DA3CE01BDEAC8373F2AE62&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;So the AES key is &amp;#039;&amp;#039;&amp;#039;4E5343234F707069646123B8DCE442D0&amp;#039;&amp;#039;&amp;#039; !&lt;br /&gt;
 echo 4E5343234F707069646123B8DCE442D0|xxd -r -p&lt;br /&gt;
 NSC#Oppida#&amp;lt;some_garbage&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;math&amp;gt;X_2&amp;lt;/math&amp;gt; mapping:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
00:CE 01&amp;#039;10 02:A0 03:48 04:C1 05:61 06:33 07:E4 08:6B 09:19 0A:C0 0B:E6 0C:C9 0D:6D 0E:93 0F:E1&lt;br /&gt;
10:EA 11:5F 12:13 13:EF 14:3C 15:07 16:54 17:02 18:CA 19:9F 1A:DF 1B:1E 1C:AA 1D:9B 1E:99 1F:03&lt;br /&gt;
20:DD 21:FF 22:B7 23:8F 24:37 25:EE 26:4F 27:F7 28:C5 29:81 2A:E5 2B:CF 2C:FB 2D:D5 2E:FD 2F:E3&lt;br /&gt;
30:7A 31:D3 32:41 33:C7 34:40 35:8C 36:CC 37:4C 38:26 39:30 3A:45 3B:C8 3C:F2 3D:56 3E:9D 3F:CD&lt;br /&gt;
40:D6 41:82 42:B5 43:6F 44:BB 45:1D 46:AF 47:67 48:F9 49:52 4A:6E 4B:DC 4C:BD 4D:59 4E:BA 4F:8B&lt;br /&gt;
50:18 51:22 52:7F 53:87 54:A8 55:35 56:A4 57:90 58:4D 59:57 5A:7C 5B:6C 5C:55 5D:24 5E:D8 5F:5B&lt;br /&gt;
60:C2 61:84 62:2D 63:11 64:9C 65:4E 66:28 67:68 68:F3 69:65 6A:E7 6B:89 6C:15 6D:2A 6E:01 6F:96&lt;br /&gt;
70:DE 71:C3 72:BC 73:E0 74:A3 75:63 76:E8 77:DB 78:B2 79:0D 7A:5D 7B:5A 7C:A6 7D:50 7E:F6 7F:D4&lt;br /&gt;
80:B1 81:5E 82:95 83:C4 84:78 85:4B 86:38 87:34 88:06 89:F8 8A:AE 8B:F1 8C:27 8D:71 8E:14 8F:B4&lt;br /&gt;
90:E2 91:49 92:2C 93:09 94:BE 95:7D 96:D7 97:4A 98:EC 99:70 9A:04 9B:2B 9C:92 9D:66 9E:9A 9F:32&lt;br /&gt;
A0:6A A1:97 A2:31 A3:9E A4:08 A5:3A A6:43 A7:85 A8:0C A9:91 AA:A2 AB:D1 AC:8E AD:20 AE:AC AF:A5&lt;br /&gt;
B0:39 B1:74 B2:B6 B3:16 B4:76 B5:F4 B6:3D B7:5C B8:1A B9:ED BA:51 BB:0B BC:80 BD:2F BE:1C BF:DA&lt;br /&gt;
C0:94 C1:A9 C2:12 C3:05 C4:73 C5:0A C6:53 C7:62 C8:AD C9:F5 CA:3F CB:75 CC:25 CD:77 CE:B9 CF:42&lt;br /&gt;
D0:36 D1:7E D2:EB D3:BF D4:B0 D5:E9 D6:C6 D7:98 D8:69 D9:72 DA:60 DB:B8 DC:86 DD:23 DE:47 DF:00&lt;br /&gt;
E0:88 E1:B3 E2:83 E3:FC E4:64 E5:46 E6:A7 E7:CB E8:D2 E9:58 EA:7B EB:21 EC:F0 ED:44 EE:3B EF:3E&lt;br /&gt;
F0:0E F1:1B F2:17 F3:FA F4:2E F5:D9 F6:8D F7:AB F8:0F F9:D0 FA:1F FB:FE FC:A1 FD:29 FE:8A FF:79&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;Recovery of the external encodings is left as exercise for the reader ;-)&lt;br /&gt;
&amp;lt;br&amp;gt;Fun facts: if on the clear implementation we don&amp;#039;t look for &amp;lt;math&amp;gt;0\!:\!0\!:\!0\!:\!0&amp;lt;/math&amp;gt; to &amp;lt;math&amp;gt;0&amp;lt;/math&amp;gt; but for &amp;lt;math&amp;gt;x\!:\!x\!:\!x\!:\!x&amp;lt;/math&amp;gt; to &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; where &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; is arbitrarily chosen, we still find the right round key but with a wrong &amp;lt;math&amp;gt;X_2&amp;lt;/math&amp;gt; mapping.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;Thanks for your patience if you have read so far, feel free to share your thoughts with me ([https://twitter.com/doegox @doegox]).&lt;br /&gt;
&amp;lt;br&amp;gt;And thanks to Eloi for this great challenge and to Axel, Arnaud and Guy those who have shared their write-up!&lt;br /&gt;
==Epilogue==&lt;br /&gt;
&lt;br /&gt;
Before being able to mount the attack, we had to recover the actual tables and that&amp;#039;s not that simple.&lt;br /&gt;
&amp;lt;br&amp;gt;Axel&amp;#039;s version contains the tables but still unsorted as this was not needed for him to break the challenge:&lt;br /&gt;
* Table names and positions are random&lt;br /&gt;
* Code is flattened&lt;br /&gt;
* Intermediate variables are taken in arbitrary order from a reusable pool, including output buffer&lt;br /&gt;
* Steps are calculated out of order, only order due to dependencies is preserved&lt;br /&gt;
* Half of tables are actually tables to function snippets in the original code but Axel&amp;#039;s version removed already that obfuscation layer, sigh!&lt;br /&gt;
So to rename properly the tables one needs to:&lt;br /&gt;
* Rewrite code with static single assignment (SSA) form, to be able to reorder it without conflicts&lt;br /&gt;
* Start from output buffers and rename logically intermediate values and tables&lt;br /&gt;
Detailed steps:&lt;br /&gt;
* As SSA version I took wbaes128_solve.cpp from his writeup, extracted and reordered the rounds (by hand)&lt;br /&gt;
 //ROUND1&lt;br /&gt;
 memory[2] = T_00430909[key[0x0]];&lt;br /&gt;
 memory[9] = T_004E19C5[key[0xa]];&lt;br /&gt;
 memory[10] = T_0055BF00[key[0xf]];&lt;br /&gt;
 memory[18] = TH_005D3C2C[key[0xf]];&lt;br /&gt;
 memory[20] = T16_00415EFE[memory[9]][memory[10]];&lt;br /&gt;
 etc&lt;br /&gt;
* To have something to compare with, I took the whitebox generator and replaced actual lookups by printf(), making sure all intermediate values are on SSA form too&lt;br /&gt;
 b1_0[0] = rT0[0][0][t[0][0]]&lt;br /&gt;
 b1_0[1] = rT0[0][1][t[0][5]]&lt;br /&gt;
 b1_0[2] = rT0[0][2][t[0][10]]&lt;br /&gt;
 b1_0[3] = rT0[0][3][t[0][15]]&lt;br /&gt;
 b1_0_01 = xT0[b1_0[0]][b1_0[1]]&lt;br /&gt;
 b1_0_23 = xT1[b1_0[2]][b1_0[3]]&lt;br /&gt;
 t[1][0] = xT2[b1_0_01][b1_0_23]&lt;br /&gt;
 etc&lt;br /&gt;
* Then I build a dictionary associating tables and indexes with each variable assignment from this output.&lt;br /&gt;
* Reading backward the SSA version, now I can make matches between table names:&lt;br /&gt;
 fT[0] = TH_0049CA9E&lt;br /&gt;
 fT[1] = T_00493D6C&lt;br /&gt;
 fT[2] = TH_004866A5&lt;br /&gt;
 fT[3] = T_005D1023&lt;br /&gt;
 fT[4] = T_00534D4A&lt;br /&gt;
 ...&lt;br /&gt;
 rT0[0][0] = T_00438C5E&lt;br /&gt;
 rT0[0][1] = T_005FCF50&lt;br /&gt;
 rT0[0][2] = TH_004D3B58&lt;br /&gt;
 rT0[0][3] = TH_005D3C2C&lt;br /&gt;
 ...&lt;br /&gt;
* Then based on those matches, I generate C code to copy NSC tables to aes_wbs_s struct of the wb generator code&lt;br /&gt;
 memcpy(aes.finalTable[0], TH_0049CA9E, sizeof(TH_0049CA9E));&lt;br /&gt;
 memcpy(aes.finalTable[1], T_00493D6C, sizeof(T_00493D6C));&lt;br /&gt;
 memcpy(aes.finalTable[2], TH_004866A5, sizeof(TH_004866A5));&lt;br /&gt;
 memcpy(aes.finalTable[3], T_005D1023, sizeof(T_005D1023));&lt;br /&gt;
 memcpy(aes.finalTable[4], T_00534D4A, sizeof(T_00534D4A));&lt;br /&gt;
 ...&lt;br /&gt;
 memcpy(aes.roundTables[0][0][0], T_00438C5E, sizeof(T_00438C5E));&lt;br /&gt;
 memcpy(aes.roundTables[0][0][1], T_005FCF50, sizeof(T_005FCF50));&lt;br /&gt;
 memcpy(aes.roundTables[0][0][2], TH_004D3B58, sizeof(TH_004D3B58));&lt;br /&gt;
 memcpy(aes.roundTables[0][0][3], TH_005D3C2C, sizeof(TH_005D3C2C));&lt;br /&gt;
 ...&lt;br /&gt;
* Compile and execute :) We obtain a file with the right tables in the same format as the one produced by the whitebox generator code.&lt;/div&gt;</summary>
		<author><name>PhilippeTeuwen</name></author>
	</entry>
</feed>