<?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 That makes sense. in Intel® Software Guard Extensions (Intel® SGX)</title>
    <link>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Loading-Sealed-Data-to-an-Enclave/m-p/1164056#M2979</link>
    <description>&lt;P&gt;That makes sense.&lt;/P&gt;

&lt;P&gt;Thanks.&lt;/P&gt;

&lt;P&gt;Nazmus&lt;BR /&gt;
	&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 15 Aug 2017 18:23:21 GMT</pubDate>
    <dc:creator>Nazmus_S_</dc:creator>
    <dc:date>2017-08-15T18:23:21Z</dc:date>
    <item>
      <title>Loading Sealed Data to an Enclave</title>
      <link>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Loading-Sealed-Data-to-an-Enclave/m-p/1164052#M2975</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 1em;"&gt;According to the developer and reference guide, generally data sealed by an enclave resides in the disk. I went through the&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="font-size: 1em;"&gt;sample codes, and saw many use cases of data sealing. However, I could not find any example where the sealed data is loaded from the disk to an enclave. Can anyone discuss the detailed procedure of loading sealed data from the disk to an enclave?&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;Another thing is, if I seal a file of size say, 120 MB to disk, is the sealed file visible in the file system?&lt;/P&gt;

&lt;P&gt;Thanks.&lt;/P&gt;

&lt;P&gt;Nazmus&lt;/P&gt;</description>
      <pubDate>Wed, 09 Aug 2017 01:42:20 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Loading-Sealed-Data-to-an-Enclave/m-p/1164052#M2975</guid>
      <dc:creator>Nazmus_S_</dc:creator>
      <dc:date>2017-08-09T01:42:20Z</dc:date>
    </item>
    <item>
      <title>Hi：</title>
      <link>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Loading-Sealed-Data-to-an-Enclave/m-p/1164053#M2976</link>
      <description>&lt;P&gt;Hi：&lt;BR /&gt;
	Actually the sgx_seal_data() is encrypt function using AES, and the key is generated automatically(according to your cpu and certificate used to sign the enclave). The sample doesn't include the code to write the result to disk. But it’s easy to do this. You can just make an Ocall and use the file IO function&amp;nbsp;to&amp;nbsp;achieve this.&lt;/P&gt;

&lt;P&gt;Regards&lt;/P&gt;

&lt;P&gt;you&lt;/P&gt;</description>
      <pubDate>Tue, 15 Aug 2017 01:18:10 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Loading-Sealed-Data-to-an-Enclave/m-p/1164053#M2976</guid>
      <dc:creator>you_w_</dc:creator>
      <dc:date>2017-08-15T01:18:10Z</dc:date>
    </item>
    <item>
      <title>Hi You.</title>
      <link>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Loading-Sealed-Data-to-an-Enclave/m-p/1164054#M2977</link>
      <description>&lt;P&gt;Hi You.&lt;/P&gt;

&lt;P&gt;Thanks a lot for your response.&lt;/P&gt;

&lt;P&gt;So based on my understanding, at&amp;nbsp; first, we seal (apparently, which means encrypting) the sensitive data,&amp;nbsp; write the sealed/encrypted data to a text file (via OCALL), and then save this text file to the disk. So, this file containing sealed data, will be stored in the untrusted memory, and will be visible in the filesystem.&lt;/P&gt;

&lt;P&gt;My concern is: in the context of an SGX-enabled cloud server, where the server is administered by a semi-honest administrator, is there is any major security threat on client's sensitive data. If so, what are the required steps that an application developer should follow to minimize the threat ?&lt;/P&gt;

&lt;P&gt;Thanks.&lt;/P&gt;

&lt;P&gt;Nazmus&lt;/P&gt;</description>
      <pubDate>Tue, 15 Aug 2017 03:55:37 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Loading-Sealed-Data-to-an-Enclave/m-p/1164054#M2977</guid>
      <dc:creator>Nazmus_S_</dc:creator>
      <dc:date>2017-08-15T03:55:37Z</dc:date>
    </item>
    <item>
      <title>Hi Nazmus：</title>
      <link>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Loading-Sealed-Data-to-an-Enclave/m-p/1164055#M2978</link>
      <description>&lt;P&gt;&lt;SPAN style="font-size: 12px;"&gt;Hi&amp;nbsp;Nazmus：&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 12px;"&gt;The sealed file is visible in the file system. Such a administrator can access that file but can't get useful information from that file. But he or she can destroy the sealed file by modify or delete &amp;nbsp;it. Now I have no idea about this.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 12px;"&gt;Kind regards&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 12px;"&gt;you&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 15 Aug 2017 06:25:51 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Loading-Sealed-Data-to-an-Enclave/m-p/1164055#M2978</guid>
      <dc:creator>you_w_</dc:creator>
      <dc:date>2017-08-15T06:25:51Z</dc:date>
    </item>
    <item>
      <title>That makes sense.</title>
      <link>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Loading-Sealed-Data-to-an-Enclave/m-p/1164056#M2979</link>
      <description>&lt;P&gt;That makes sense.&lt;/P&gt;

&lt;P&gt;Thanks.&lt;/P&gt;

&lt;P&gt;Nazmus&lt;BR /&gt;
	&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 15 Aug 2017 18:23:21 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Loading-Sealed-Data-to-an-Enclave/m-p/1164056#M2979</guid>
      <dc:creator>Nazmus_S_</dc:creator>
      <dc:date>2017-08-15T18:23:21Z</dc:date>
    </item>
    <item>
      <title>Hi Nazmus:</title>
      <link>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Loading-Sealed-Data-to-an-Enclave/m-p/1164057#M2980</link>
      <description>&lt;P&gt;Hi&amp;nbsp;Nazmus:&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 13.008px;"&gt;You can refer this code from&amp;nbsp;&lt;/SPAN&gt;&lt;A href="https://github.com/hyperledger/sawtooth-core/tree/master/consensus/poet/sgx/sawtooth_poet_sgx/libpoet_bridge" style="font-size: 13.008px;"&gt;https://github.com/hyperledger/sawtooth-core/tree/master/consensus/poet/sgx/sawtooth_poet_sgx/libpoet_bridge&lt;/A&gt;&lt;SPAN style="font-size: 13.008px;"&gt;.&lt;/SPAN&gt;&lt;/P&gt;

&lt;PRE class="brush:cpp;"&gt; class SealedData
 {
        public:
            void Load(
                const std::string&amp;amp; fileName,
                size_t sealedSize
                );
            void Save();
            void Clear();

            uint8_t* Data() { return &amp;amp;this-&amp;gt;data[0]; }; 
            size_t Length() { return this-&amp;gt;data.size(); }; 
        private:
            std::string fileName;
            std::vector&amp;lt;uint8_t&amp;gt; data;
  };&lt;/PRE&gt;

&lt;PRE class="brush:cpp;"&gt;void SealedData::Load(
            const std::string&amp;amp; fileName,
            size_t sealedLength
            )
        {
            this-&amp;gt;fileName = fileName;
            std::ifstream stateFile(this-&amp;gt;fileName, std::ios::binary);
            if(stateFile.good()) {
                this-&amp;gt;data.clear();
                this-&amp;gt;data.assign(
                    std::istreambuf_iterator&amp;lt;char&amp;gt;(stateFile), 
                    std::istreambuf_iterator&amp;lt;char&amp;gt;());
                stateFile.close();

                // if we have the wrong amount of data
                if (sealedLength != data.size()) {
                    // throw it away and start over
                    // in the future we will want a function 
                    // to convert the states if the versions
                    // change.
                    this-&amp;gt;data.resize(sealedLength);
                    ZeroV(this-&amp;gt;data);
                }
            } else {
                this-&amp;gt;data.resize(sealedLength);
                ZeroV(this-&amp;gt;data);
            }
        }// SealedData::Load

        // XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
        void SealedData::Save()
        {
            std::ofstream output(this-&amp;gt;fileName, std::ios::binary );

            std::copy( 
                this-&amp;gt;data.begin(), 
                this-&amp;gt;data.end(),
                std::ostreambuf_iterator&amp;lt;char&amp;gt;(output));
            output.close();
        } // SealedData::Save

        // XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
        void SealedData::Clear()
        {
            ZeroV(this-&amp;gt;data);
            this-&amp;gt;data.clear();
            remove(this-&amp;gt;fileName.c_str());
        } // SealedData::Clear
&lt;/PRE&gt;

&lt;P&gt;Regards&lt;/P&gt;

&lt;P&gt;you&lt;/P&gt;</description>
      <pubDate>Wed, 16 Aug 2017 03:15:06 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Loading-Sealed-Data-to-an-Enclave/m-p/1164057#M2980</guid>
      <dc:creator>you_w_</dc:creator>
      <dc:date>2017-08-16T03:15:06Z</dc:date>
    </item>
    <item>
      <title>Hi You.</title>
      <link>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Loading-Sealed-Data-to-an-Enclave/m-p/1164058#M2981</link>
      <description>&lt;P&gt;Hi You.&lt;/P&gt;

&lt;P&gt;Thanks a lot for sharing this. Very useful.&lt;/P&gt;

&lt;P&gt;Nazmus&lt;/P&gt;</description>
      <pubDate>Wed, 16 Aug 2017 17:41:07 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Software-Guard-Extensions/Loading-Sealed-Data-to-an-Enclave/m-p/1164058#M2981</guid>
      <dc:creator>Nazmus_S_</dc:creator>
      <dc:date>2017-08-16T17:41:07Z</dc:date>
    </item>
  </channel>
</rss>

