<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Reserved fields in sealed data in Intel® Software Guard Extensions (Intel® SGX)</title>
    <link>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Reserved-fields-in-sealed-data/m-p/1141355#M2273</link>
    <description>&lt;P&gt;Hello,&amp;nbsp;&lt;SPAN style="font-size: 1em;"&gt;I have a question about the "reserved" fields in the struct&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="font-size: 1em;"&gt;sgx_key_request_t as follow:&lt;/SPAN&gt;&lt;/P&gt;

&lt;DIV&gt;
	&lt;PRE class="brush:cpp;"&gt;typedef struct _key_request_t {
uint16_t key_name;
uint16_t key_policy;
sgx_isv_svn_t isv_svn;
uint16_t reserved1;
sgx_cpu_svn_t cpu_svn;
sgx_attributes_t attribute_mask;
sgx_key_id_t key_id;
sgx_misc_select_t misc_mask;
uint8_t reserved2[436];
} sgx_key_request_t&lt;/PRE&gt;
&lt;/DIV&gt;

&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;

&lt;DIV&gt;&lt;SPAN style="font-size: 13.008px;"&gt;In the &lt;A href="https://download.01.org/intel-sgx/linux-2.1.3/docs/Intel_SGX_Developer_Reference_Linux_2.1.3_Open_Source.pdf"&gt;developer reference&lt;/A&gt;, reserved fields are defined for future use and must be set to zero. More precisely, what is the future use and why are the sizes of the two fields fixed as 2 and 436 bytes ?&lt;/SPAN&gt;&lt;/DIV&gt;

&lt;DIV&gt;&lt;SPAN style="font-size: 13.008px;"&gt;So the seal and unseal is not very appropriate for data with small size ( int, double.....) because the size of struct sgx_sealed_data_t is huge due to these fields. Are they here for some security purpose ?&lt;/SPAN&gt;&lt;/DIV&gt;

&lt;DIV&gt;&lt;SPAN style="font-size: 13.008px;"&gt;I don't know if it's possible to define my own version of seal and unseal by deleting them in the source code. Or if there is a better solution. Thank you in advance.&lt;/SPAN&gt;&lt;/DIV&gt;

&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;

&lt;DIV&gt;&lt;SPAN style="font-size: 13.008px;"&gt;Simon&lt;/SPAN&gt;&lt;/DIV&gt;</description>
    <pubDate>Fri, 15 Jun 2018 13:07:53 GMT</pubDate>
    <dc:creator>liu__simon</dc:creator>
    <dc:date>2018-06-15T13:07:53Z</dc:date>
    <item>
      <title>Reserved fields in sealed data</title>
      <link>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Reserved-fields-in-sealed-data/m-p/1141355#M2273</link>
      <description>&lt;P&gt;Hello,&amp;nbsp;&lt;SPAN style="font-size: 1em;"&gt;I have a question about the "reserved" fields in the struct&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="font-size: 1em;"&gt;sgx_key_request_t as follow:&lt;/SPAN&gt;&lt;/P&gt;

&lt;DIV&gt;
	&lt;PRE class="brush:cpp;"&gt;typedef struct _key_request_t {
uint16_t key_name;
uint16_t key_policy;
sgx_isv_svn_t isv_svn;
uint16_t reserved1;
sgx_cpu_svn_t cpu_svn;
sgx_attributes_t attribute_mask;
sgx_key_id_t key_id;
sgx_misc_select_t misc_mask;
uint8_t reserved2[436];
} sgx_key_request_t&lt;/PRE&gt;
&lt;/DIV&gt;

&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;

&lt;DIV&gt;&lt;SPAN style="font-size: 13.008px;"&gt;In the &lt;A href="https://download.01.org/intel-sgx/linux-2.1.3/docs/Intel_SGX_Developer_Reference_Linux_2.1.3_Open_Source.pdf"&gt;developer reference&lt;/A&gt;, reserved fields are defined for future use and must be set to zero. More precisely, what is the future use and why are the sizes of the two fields fixed as 2 and 436 bytes ?&lt;/SPAN&gt;&lt;/DIV&gt;

&lt;DIV&gt;&lt;SPAN style="font-size: 13.008px;"&gt;So the seal and unseal is not very appropriate for data with small size ( int, double.....) because the size of struct sgx_sealed_data_t is huge due to these fields. Are they here for some security purpose ?&lt;/SPAN&gt;&lt;/DIV&gt;

&lt;DIV&gt;&lt;SPAN style="font-size: 13.008px;"&gt;I don't know if it's possible to define my own version of seal and unseal by deleting them in the source code. Or if there is a better solution. Thank you in advance.&lt;/SPAN&gt;&lt;/DIV&gt;

&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;

&lt;DIV&gt;&lt;SPAN style="font-size: 13.008px;"&gt;Simon&lt;/SPAN&gt;&lt;/DIV&gt;</description>
      <pubDate>Fri, 15 Jun 2018 13:07:53 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Reserved-fields-in-sealed-data/m-p/1141355#M2273</guid>
      <dc:creator>liu__simon</dc:creator>
      <dc:date>2018-06-15T13:07:53Z</dc:date>
    </item>
    <item>
      <title>edit: The reserved2 field is</title>
      <link>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Reserved-fields-in-sealed-data/m-p/1141356#M2274</link>
      <description>&lt;P&gt;edit: The reserved2 field is supposed to keep the data alignment of the sgx_key_request_t of 512 bytes. So a new question comes to me: why should we use data alignment here and can we change the size of alignment? Thank you!&lt;/P&gt;</description>
      <pubDate>Tue, 19 Jun 2018 12:20:53 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Reserved-fields-in-sealed-data/m-p/1141356#M2274</guid>
      <dc:creator>liu__simon</dc:creator>
      <dc:date>2018-06-19T12:20:53Z</dc:date>
    </item>
  </channel>
</rss>

