<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Moritz Eckert on Medium]]></title>
        <description><![CDATA[Stories by Moritz Eckert on Medium]]></description>
        <link>https://medium.com/@m1ghtym0?source=rss-d6041a5cf3aa------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*nZpr9N04qUlwYc4LKXlzsw.jpeg</url>
            <title>Stories by Moritz Eckert on Medium</title>
            <link>https://medium.com/@m1ghtym0?source=rss-d6041a5cf3aa------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 22 Nov 2026 05:16:42 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@m1ghtym0/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Reproducible Builds for Confidential Computing]]></title>
            <link>https://medium.com/@m1ghtym0/reproducible-builds-for-confidential-computing-909b906d2056?source=rss-d6041a5cf3aa------2</link>
            <guid isPermaLink="false">https://medium.com/p/909b906d2056</guid>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[confidential-computing]]></category>
            <category><![CDATA[supply-chain-security]]></category>
            <category><![CDATA[security]]></category>
            <category><![CDATA[reproducible-builds]]></category>
            <dc:creator><![CDATA[Moritz Eckert]]></dc:creator>
            <pubDate>Thu, 27 Jul 2023 12:44:07 GMT</pubDate>
            <atom:updated>2023-07-28T14:20:47.459Z</atom:updated>
            <content:encoded><![CDATA[<h4>Closing the Gaps in Supply Chain Security</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*DBE_Sgni1yJHItaaeURQlA.png" /></figure><h3>Why supply chain security matters</h3><p>In today’s interconnected world, software development relies heavily on third-party dependencies and components. However, using these components introduces a significant risk to the security and integrity of software supply chains. Malicious actors can exploit vulnerabilities in these components to gain unauthorized access to sensitive data or to execute unauthorized code on targeted systems. The recent <a href="https://www.businessinsider.com/solarwinds-hack-explained-government-agencies-cyber-security-2020-12">SolarWinds attack</a> is a prime example of how a supply chain attack can have far-reaching consequences.</p><p>To address these concerns, there is an increasing focus on supply chain security, which involves ensuring the security and integrity of software components throughout their entire lifecycle, from development to deployment.</p><p>One of the popular topics in the context of supply chain security is reproducible builds. “Reproducible” means repeating the build with the same inputs results in a bit-for-bit identical output. Reproducible builds guarantee that multiple parties can independently build and verify software components, ensuring that the resulting binaries are consistent and free from tampering or malicious code.</p><h3>How to protect against supply chain attacks</h3><p>Different solutions have been developed to help organizations identify and track vulnerabilities in their software components and dependencies, allowing them to prioritize and manage their security patches and updates.</p><p>A software Bill of Materials (SBOM) records all the software components and dependencies used in a particular software product. SBOMs provide critical visibility into the software supply chain, allowing organizations to track and manage software components and vulnerabilities. We have published <a href="https://blog.edgeless.systems/generating-sboms-for-confidential-kubernetes-is-easier-than-you-think-296bb5a55610">dedicated blog posts</a> on SBOMs and how we integrate them into our supply chain security.</p><p>An additional approach to protecting against supply chain attacks is implementing the Supply Chain Levels for Software Artifacts (SLSA) framework. SLSA is a set of best practices and recommendations resulting from a cross-industry collaboration by organizations including Google and The Linux Foundation, for ensuring the security and integrity of software components throughout their entire lifecycle, from development to deployment. You can learn more about SLSA in the official <a href="https://slsa.dev/spec/v1.0/">documentation</a>.</p><h3>Why reproducible builds matter for confidential computing</h3><p>In confidential computing, reproducible builds play a crucial role in the semantic verification of remote attestation statements. Using reproducible builds, organizations can verify that their confidential computing environments are running on trusted software components, free from hidden vulnerabilities or malicious code. Further, they can verify that precisely their intended workload is running before sharing data with it.</p><h3>Reproducible builds and containers</h3><p>Containers have become popular for building, packaging, and deploying software applications. However, they also introduce new challenges and risks for supply chain security. Containers typically rely on multiple layers of dependencies, including base images, application code, and third-party libraries. These dependencies can be vulnerable to attacks, and malicious actors can exploit these vulnerabilities to gain access or execute unauthorized code.</p><p>For these reasons, it’s essential to implement robust supply chain security measures for containers. One approach is to use container image signing, which involves signing the container image with a digital signature to verify its authenticity and integrity. This ensures that only trusted container images are used in production and helps prevent supply chain attacks.</p><p>However, container signing is not enough regarding remote attestation in confidential computing. It would still mean trusting the signing party. The semantic attestation requires that the container is also built reproducibly. That way we can actually verify the containers based on the sources.</p><h3>Bringing it all together with Constellation</h3><p>Combining all these measures, we can provide gap-free supply chain security for our confidential Kubernetes platform <a href="https://github.com/edgelesssys/constellation">Constellation</a>. By generating SBOMs, implementing SLSA, and ensuring reproducible builds for our images, containers, and binaries, Constellation provides confidential computing-grade protection against the risks of supply chain attacks. In the following, we describe how we implement reproducible builds in practice using <a href="https://bazel.build/">Bazel</a>.</p><h4>Bazel</h4><p>Bazel is a powerful and flexible build system that has gained popularity recently for its ability to manage large, complex software projects. Developed and open-sourced by Google, Bazel is designed to handle software builds in a distributed, parallel, and incremental way, making it an excellent tool for large-scale software development. Bazel is designed to support reproducible builds by default, making it an ideal choice for us.</p><p>One of the key features of Bazel is its built-in caching system. Bazel stores build artifacts in a cache and can reuse previously built artifacts for future builds, enabling the same build to produce identical outputs across different environments. This is particularly important in a distributed development environment, where developers may work on different machines and operating systems.</p><p>Bazel also supports sandboxing, where builds are executed in a controlled and isolated environment, ensuring that builds are not affected by external factors such as system libraries or environment variables. This helps to ensure that builds are reproducible across different development environments.</p><p>In addition, Bazel provides deterministic builds by default, meaning that the same build inputs will always produce the same outputs. Bazel uses a content-based addressing system to ensure that build artifacts are uniquely identified by their content rather than by their location or time of creation. This ensures that builds are consistent and reproducible, regardless of the built environment or timing.</p><p>Bazel’s support for containerization is built on its existing build infrastructure, enabling developers to define container images as a build target like they define other build targets.</p><p>Overall, Bazel’s built-in caching, sandboxing, containerization support, and deterministic builds make it an excellent tool for Constellation’s reproducible builds.</p><h4>Reproduce a Constellation build</h4><p>We now walk through the steps of locally reproducing a specific Constellation version’s build. You can find detailed descriptions and instructions in the <a href="https://github.com/edgelesssys/constellation/blob/main/dev-docs/workflows/build-test-run.md">build and test documentation</a>.</p><p>Make sure you have the <a href="https://github.com/edgelesssys/constellation/blob/main/dev-docs/workflows/build-test-run.md#build">build dependencies</a> installed.</p><ol><li>Download the sources at the right version in this case v2.9.0</li></ol><pre>git clone https://github.com/edgelesssys/constellation.git &amp;&amp; cd constellation<br>git fetch --all --tags<br>git checkout tags/v2.9.0</pre><p>2. Build the release. For the sake of this demo, we build the CLI and the Constellation service containers</p><pre>bazel build //cli:cli_enterprise_linux_amd64<br>bazel build //bazel/release:container_sums</pre><p>3. Verify the official CLI release matches our local build</p><pre>mkdir build &amp;&amp; cd build<br>cp ../bazel-bin/cli/cli_enterprise_linux_amd64.<br>wget https://github.com/edgelesssys/constellation/releases/download/v2.9.0/constellation-linux-amd64<br>sha256sum ./constellation-linux-amd64<br># ca657e7552ef4c7c2aba1e7b2fbf7e7ab2dbb07fb3e56918e3ece15f6c6c1dc0  ./constellation-linux-amd64<br>sha256sum ./cli_enterprise_linux_amd64<br># ca657e7552ef4c7c2aba1e7b2fbf7e7ab2dbb07fb3e56918e3ece15f6c6c1dc0  ./cli_enterprise_linux_amd64</pre><p>4. Verify the containers running inside Constellation match our local build</p><pre>chmod u+x ./constellation-linux-amd64<br>./constellation-linux-amd64 config generate &lt;your_cloud&gt;<br># Fill in cloud provider specific information, see the docs for more info https://docs.edgeless.systems/constellation/workflows/config<br>./constellation-linux-amd64 create -c 1 -w 2<br>./constellation-linux-amd64 init<br>export KUBECONFIG=&quot;$PWD/constellation-admin.conf&quot;<br>kubectl get pods -n kube-system -l &#39;k8s-app in (join-service,key-service,verification-service)&#39; -o=jsonpath=&#39;{range .items[*]}{.metadata.name}{&quot;: &quot;}{.status.containerStatuses[0].imageID}{&quot;\n&quot;}{end}&#39;<br># join-service-tjxpc: ghcr.io/edgelesssys/constellation/join-service@sha256:6783eddfe541bad769461935b0d7b08e9891cc6a94a4398969bb5d22c17b18c2<br># key-service-48zx7: ghcr.io/edgelesssys/constellation/key-service@sha256:74ad2ee200cca87057d78f8eec64815bf10e1c33c084c568b011851a32a5e7f9<br># verification-service-5h5jt: ghcr.io/edgelesssys/constellation/verification-service@sha256:707123efc4e7fac1c34f35007ab687ac917d24f53bcd5e06244bcd4f569f14a9<br>kubectl get pods -n kube-system -l app.kubernetes.io/name=constellation-operator -o=jsonpath=&#39;{range .items[*]}{.metadata.name}{&quot;: &quot;}{.status.containerStatuses[1].imageID}{&quot;\n&quot;}{end}&#39;<br># constellation-operator-controller-manager-6ddcd74c5b-wbvxd: ghcr.io/edgelesssys/constellation/node-operator@sha256:a34d20bf823fd308c87e40705dc124969760d6d0810f23dc19a313607ab232ff<br>cat ../bazel-bin/bazel/release/container_sums.sha256<br># 6783eddfe541bad769461935b0d7b08e9891cc6a94a4398969bb5d22c17b18c2  ghcr.io/edgelesssys/constellation/join-service:v2.9.0<br># 74ad2ee200cca87057d78f8eec64815bf10e1c33c084c568b011851a32a5e7f9  ghcr.io/edgelesssys/constellation/key-service:v2.9.0<br># 707123efc4e7fac1c34f35007ab687ac917d24f53bcd5e06244bcd4f569f14a9  ghcr.io/edgelesssys/constellation/verification-service:v2.9.0</pre><p>Comparing the hashes, you should see your local builds matching the released CLI and deployed services.</p><h3>Conclusion</h3><p>In this blog post, we have seen the critical role that reproducible builds play in ensuring the security and trustworthiness of software supply chains, particularly in the context of confidential computing. By ensuring that software artifacts are consistent and free from tampering, reproducible builds help to protect against a wide range of security threats and vulnerabilities.</p><p>With its built-in support for reproducible builds, we have seen how Bazel is an excellent tool for implementing these principles into Constellation’s build pipeline in practice.</p><p>Finally, we have learned hands-on how a Constellation release can be reproduced and verified locally based on the source code.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=909b906d2056" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Bring your own key (BYOK) was a lie!]]></title>
            <link>https://medium.com/@m1ghtym0/bring-your-own-key-was-a-lie-92587d7c73ec?source=rss-d6041a5cf3aa------2</link>
            <guid isPermaLink="false">https://medium.com/p/92587d7c73ec</guid>
            <category><![CDATA[confidential-computing]]></category>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[cloud-computing]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[cloud-security]]></category>
            <dc:creator><![CDATA[Moritz Eckert]]></dc:creator>
            <pubDate>Thu, 13 Oct 2022 07:51:58 GMT</pubDate>
            <atom:updated>2022-10-13T08:17:57.470Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/498/1*mfYh8wIT8RL6j10LmL9wKA.gif" /></figure><p>Bring your own key (BYOK) is a popular term used by cloud service providers (CSPs) when it comes to cloud security features.</p><p>It allows customers to stay in control of their cryptographic keys and split the trust between the cloud provider and the key owners.</p><p>Instead of the CSP generating and controlling the keys, the customers generate and manage their own keys. Usually, they securely store them in a key management system (KMS), either in the cloud or in their physically controlled on-prem environment. Often these systems are backed by a secure hardware module (HSM) that protects the keys at rest. Finally, the customers configure which cloud services and contexts can access the keys to use them for cryptographic operations.</p><p>Sounds great so far, doesn’t it?</p><h4>So, what is the problem?</h4><p>The problem are the cryptographic operations. They are still controlled and performed by the CSP and the managed cloud services. That means, whenever keys are used to either encrypt data or as a form of authentication, they need to stay accessible to that service. Consequently, whoever has access to the service has direct access to the keys. Additionally, while the keys are in use, they are residing in plaintext in the main memory of that service. Hence, also everyone that can acquire a way into the memory of that service either virtually or physically can leak the keys from there.</p><h4>So what? I trust my cloud environment and my CSP!</h4><p>Fair enough, but then why did you split the trust in the first place using BYOK? Let’s think about the threat model here. Anyone leveraging privilege in the cloud or exploiting vulnerabilities in the isolation of cloud tenants, will inevitably gain access to the cryptographic services and eventually to your keys. So, do you trust the entire public cloud and its tenant? And why go through all that trouble of BYOK and separation of concerns?</p><h4>What is the solution?</h4><p>Fortunately, confidential computing (CC) technology can help with this. The basic idea of CC is to have the processor of a system create a highly secure environment for data processing. Such execution environments are often referred to as trusted execution environments (TEEs) in the literature. In the following, we use the term “confidential computing environment” (CCE) to refer to TEEs with specific capabilities.</p><p>CCEs have the following three defining properties:</p><p>(1) <strong>Runtime encryption</strong>: The processor keeps all the CCE’s data encrypted in the main memory. Any system component or hardware attacker attempting to read a CCE’s data directly from memory will only ever see encrypted data. Likewise, encryption prevents the modification of a CCE’s data through direct memory access.</p><p>(2) <strong>Isolation</strong>: the processor blocks software-based access to the CCE. Software like the operating system or other apps can only communicate with the CCE over specific interfaces. You can think of this as an API that the CCE exposes to the outside world.</p><p>(3) <strong>Remote attestation</strong>: on demand, the processor can issue a cryptographic certificate that proves the integrity and authenticity of a CCE and the data it produced.</p><p>Regarding BYOK, CCEs allow you to fill in the gaps and guarantee end-2-end protection of your keys:</p><p>(1) <strong>Runtime encryption</strong> ensures that keys cannot be leaked from the main memory</p><p>(2) <strong>Isolation</strong> ensures no other component or actor in the cloud environment can access the keys via an escalation of privilege or cross-tenant access</p><p>(3) <strong>Remote attestation</strong> allows for restricting the access and release of keys to CCE environments. Hardware-based attestation statements represent an unforgeable form of identity that uniquely identify CCEs based on their unique fingerprint. The KMS can verify the attestation statement and thereby, that a request genuinely comes from a specific CCE.</p><p>A great example of such an end-2-end secure environment is our open-source Confidential Kubernetes distribution, <a href="https://github.com/edgelesssys/constellation">Constellation</a>. It wraps your K8s cluster into a single CCE that is shielded from the underlying cloud infrastructure. Everything inside is always encrypted, including at runtime in memory.</p><p>Internally, the keys, secrets, and certificates managed by Kubernetes and Constellation, respectively, are protected by the properties of the CCE. In one of its upcoming <a href="https://docs.edgeless.systems/constellation/architecture/keys#user-managed-key-management">features</a>, Constellation will allow attaching common KMSs such as HashiCorp Vault or other KMIP-compatible KMS solutions. That will enable further separation of concerns so that you can keep root keys in a separate context if you want to do so.</p><p>In another example, Google released a case study of a secure key release from a KMS to a Confidential VM based on attestation statements. The concept is called <a href="https://cloud.google.com/blog/products/identity-security/ubiquitous-data-encryption-on-google-cloud">“Ubiquitous data encryption”</a>.</p><h4>Conclusion</h4><p>BYOK was a lie because it was only protecting keys at rest. When the environment in use becomes accessible to so many actors, customers lose control of their keys and identities once they are accessible to that hostile environment. “Bring your own key — share it with everyone.”</p><p>Confidential Computing fundamentally changes this by providing protection for keys in use and enabling trusted and verifiable runtime environments.</p><p>Solutions such as <a href="https://www.edgeless.systems/products/constellation/">Constellation</a> solve the shortcomings of BYOK using Confidential Computing so you can finally “Bring your own key — keep it yours”.</p><p>If you want to learn more about Confidential Computing, follow Edgeless Systems on <a href="https://www.linkedin.com/company/edgeless-systems">LinkedIn</a> and <a href="https://twitter.com/EdgelessSystems">Twitter</a>, and check our <a href="https://github.com/edgelesssys">OSS projects on GitHub</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=92587d7c73ec" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Deploying and managing data-centric confidential applications in the cloud with EdgelessDB and…]]></title>
            <link>https://medium.com/@m1ghtym0/deploying-and-managing-data-centric-confidential-applications-in-the-cloud-with-edgelessdb-and-7f6f5cd1dfe7?source=rss-d6041a5cf3aa------2</link>
            <guid isPermaLink="false">https://medium.com/p/7f6f5cd1dfe7</guid>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[kubernetes]]></category>
            <category><![CDATA[database]]></category>
            <category><![CDATA[confidential-computing]]></category>
            <category><![CDATA[cloud-computing]]></category>
            <dc:creator><![CDATA[Moritz Eckert]]></dc:creator>
            <pubDate>Wed, 22 Sep 2021 07:44:02 GMT</pubDate>
            <atom:updated>2021-09-22T09:34:34.890Z</atom:updated>
            <content:encoded><![CDATA[<h3>Deploying and managing data-centric confidential applications in the cloud with EdgelessDB and MarbleRun</h3><h4>A tutorial to easily get started with data-centric confidential computing applications.</h4><p>Kubernetes was originally designed to run stateless workloads and wasn’t built for handling stateful workloads like databases, message queues or key-value stores. However, the <a href="https://www.cncf.io/wp-content/uploads/2020/12/CNCF_Survey_Report_2020.pdf">Cloud Native Computing Foundation’s 2020 survey</a> shows that 55% of the participants use stateful applications in containers in production. This is following the new cloud computing strategy of many organizations to move their entire workloads and data to the cloud. Yet despite this comprehensive cloud-first approach, few solutions exist to bring confidential computing protection to data-centric applications.</p><p>In this tutorial, we show you how to easily get started with data-centric confidential computing applications by leveraging EdgelessDB and MarbleRun.</p><p>We recently announced <a href="https://blog.edgeless.systems/announcing-edgelessdb-the-first-confidential-database-24d412eb538d">EdgelessDB, the tailor-made SQL database for confidential computing</a>.</p><blockquote><a href="https://www.edgeless.systems/products/edgelessdb">EdgelessDB</a> is a full SQL database that runs entirely inside runtime-encrypted Intel SGX enclaves. In contrast to conventional databases, EdgelessDB ensures that all data is always encrypted — in memory at runtime as well as on disk.</blockquote><p>Another tool in our open-source technology stack is MarbleRun. <a href="https://blog.edgeless.systems/why-we-need-a-service-mesh-for-confidential-computing-part-3-3-ffc00b2c3508">With MarbleRun, your entire Kubernetes cluster becomes end-to-end encrypted and end-to-end verifiable.</a></p><blockquote><a href="https://www.edgeless.systems/products/marblerun/">MarbleRun</a> is an open-source control plane that simplifies deploying, scaling, and verifying SGX-based apps. It is designed to run on Kubernetes — whether alongside a service mesh or as a standalone service.</blockquote><p>Together they are a perfect match for protecting and managing the data flow in your confidential computing cloud application. EdgelessDB is a great fit for the confidential storage of your application and can replace your usual MySQL-compatible database. MarbleRun augments the control plane of your cluster and takes care of managing confidential microservices. Think of a service mesh for confidential computing.</p><p>For this tutorial, we created a simple data-centric application. It stores customer data in EdgelessDB centrally. Customers are added periodically by a service called <em>writer</em>. Think of an e-commerce backend. On the other end, a so-called <em>reader</em> service can access EdgelessDB for reading customer data and displaying it to clients, for example, your data analysts. In practice, you might want a privacy-preserving pipeline in between like a filter or an AI training, but for the simplicity of this demo, we show the customer data directly in a web interface. Now, EdgelessDB allows you to take control of your data access and define access policies that are enforced using confidential computing technology. MarbleRun takes care of authenticating the reader and writer services as well as EdgelessDB. It establishes secure communication channels between all components and hence ensures all customer data is always encrypted and data flow adheres to your predefined configuration. The architecture of our demo application looks like the following:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4qZ9zCjSC4B_mxDvwGVgdA.png" /><figcaption>Simple data-centric demo application. A “writer” backend service storing customer data in EdgelessDB centrally. A “reader” frontend service retrieving the data from EdgelessDB and displaying it to clients.</figcaption></figure><p>Let’s look a bit deeper into what the deployment of our application looks like in practice. EdgelessDB allows us to configure your access defining policy with a simple JSON manifest. The manifest needs to be provided to EdgelessDB at the initial start of the database. Access to the database is authenticated using TLS certificates. This leaves us with three tasks at hand. Providing EdgelessDB with the configurational manifest. Verifying and authenticating each new reader or writer instance and finally, distributing the certificates and private keys.</p><p>Here comes MarbleRun into play. (1) We can tell MarbleRun the topology of our application including configurations for EdgelessDB and our other services. (2) MarbleRun will take care of bootstrapping EdgelessDB with your policy. Further, MarbleRun will generate and manage certificates and keys for the EdgelessDB authentication. (3) Each new reader or writer service will be authenticated by MarbleRun and provided with their credentials. Finally, (4) MarbleRun allows us to get a concise attestation statement for the whole deployment, including the EdgelessDB manifest. Such a statement can be used by clients to verify the application before accessing the web interface to obtain the customers’ data.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ogqbJOhxdxks3oBhOW7UlA.png" /><figcaption>MarbleRun workflow for deploying and bootstrapping our demo application.</figcaption></figure><p>In the lifetime of this deployment, MarbleRun allows us to update, scale and, configure the individual services. We keep full control of the EdgelessDB access by initially providing our desired policy. Hence, we keep full control of our customers’ data.</p><p>Together, EdgelessDB and MarbleRun compose the simplest way of deploying and managing data-centric confidential applications in the cloud. For a full hands-on walk-through of this demo please see our <a href="https://github.com/edgelesssys/edgelessdb-marblerun-demo">GitHub repository</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7f6f5cd1dfe7" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Confidential multi-stakeholder AI]]></title>
            <link>https://medium.com/@m1ghtym0/confidential-multi-stakeholder-machine-learning-2292f842e95a?source=rss-d6041a5cf3aa------2</link>
            <guid isPermaLink="false">https://medium.com/p/2292f842e95a</guid>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[encryption]]></category>
            <category><![CDATA[tensorflow]]></category>
            <category><![CDATA[confidential-computing]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <dc:creator><![CDATA[Moritz Eckert]]></dc:creator>
            <pubDate>Wed, 21 Jul 2021 12:59:29 GMT</pubDate>
            <atom:updated>2021-09-03T14:00:54.357Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Hjq-lzxRjtGSSr_Cqgvzow.png" /></figure><p>To run AI workloads at scale, enterprises are increasingly relying on the public cloud. In this context, data security and privacy can become key concerns. In essence, today, companies need to trust the cloud service provider (CSP) with their data and AI-related intellectual property.</p><p>And there are also other parties to trust, as AI services typically have several stakeholders. Consider for example the schematic AI pipeline below: the AI model, the training data, and both the code for training and inference are often provided by different stakeholders. All these stakeholders must trust each other and the CSP with their valuable (and possibly regulated) data or intellectual property.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rRAYk0ZgTdO3rJ8FxS9lPA.png" /><figcaption>AI pipeline in the cloud</figcaption></figure><p>Confidential computing is a key technology that can solve these fundamental problems, as it enables the always-encrypted and verifiable processing of data. With it, businesses can collaborate and rely on the public cloud without losing control of their data or intellectual property. For more information refer to our post <a href="https://blog.edgeless.systems/confidential-computing-basics-benefits-and-use-cases-bdc9bb9446fd">“Confidential Computing — Basics, Benefits and Use Cases”</a>.</p><p>In this post, we will walk through the process of setting up a confidential AI inference service. We’ll showcase a multi-stakeholder scenario including the CSP, model owner, inference service provider, and users.</p><p>For this, we’ll use the open-source tools TensorFlow Serving, MarbleRun, and Graphene, which we introduce briefly now.</p><h3>TensorFlow Serving</h3><p><a href="https://www.tensorflow.org/tfx/guide/serving">TensorFlow Serving (TF Serving)</a> is one of the most popular frameworks for AI inference. TF Serving provides a consistent API for gRPC and HTTP, independent of the underlying model. It also provides an easy-to-use interface for updating and changing these models. TF Serving requires a Python execution environment.</p><h3>Graphene</h3><p>Graphene is a framework for creating confidential applications. In essence, it allows one to run almost arbitrary software in an Intel SGX enclave (which is the hardware feature that enables confidential computing). Graphene supports <a href="https://github.com/oscarlab/graphene/tree/master/Examples/tensorflow-lite">running TF Serving in SGX enclaves</a>. We are going to use their inference service enclave for this tutorial.</p><h3>MarbleRun</h3><p>Kubernetes is the de-facto standard for orchestrating workloads in the cloud. The MarbleRun framework takes care of confidential computing-specific aspects in a Kubernetes cluster, including key and identity management and attestation. We wrote a separate <a href="https://medium.com/edgelesssystems/why-we-need-a-service-mesh-for-confidential-computing-part-3-3-ffc00b2c3508">blog post that introduces the specific challenges of confidential computing workloads in the cloud and how MarbleRun addresses them</a>. In a nutshell, MarbleRun makes it easy to deploy, scale, and verify your SGX-based apps on Kubernetes. Think Istio/Consul/Linkerd for confidential computing.</p><h3>Confidential AI inference service</h3><p>The Scenario is the following: You would like to offer an AI inference service, e.g., as a SaaS offering, running on a public cloud. The model is provided by a third party. The third-party does not necessarily like to give you or the CSP direct access to their model to protect their intellectual property. Similarly, you would like to ensure the integrity of your inference service as well as keeping the input of your clients’ data confidential.</p><p>To overcome these concerns, we run the inference service inside a confidential computing enclave using Graphene and Intel SGX. To that end, we deploy TF Serving using Graphene’s example application. That way our TF Serving service is integrity protected and all data always encrypted at all times. In the second step, we deploy our service with MarbleRun on a public cloud. MarbleRun lets us easily orchestrate the deployment of our confidential service and facilitates the process of managing access to the model owner’s pre-trained model. It further simplifies all stakeholder’s verification and attestation processes.</p><p>The workflow looks like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*p-TuvHwrFzvGLyPRKHedoQ.png" /></figure><p>1. The model owner encrypts the model and uploads the encrypted model to a cloud storage</p><p>2. The administrator deploys MarbleRun with a manifest defining the topology and components of the confidential AI deployment</p><p>3. The administrator deploys the confidential AI application.</p><p>4. MarbleRun takes care of authentication and bootstrapping procedures.</p><p>5. The model owner verifies the deployment via MarbleRun and uploads the encryption key securely to the TensorFlow Serving application via MarbleRun’s secret distribution.</p><p>6. The application can decrypt the model inside the enclave via the provisioned key.</p><p>7. Clients can verify the deployment via MarbleRun and connect securely to the inference service, knowing that their data is only accessible inside the enclave and their predictions are made by the integrity-protected TensorFlow Serving application.</p><p>For a hands-on tutorial of this scenario check out our <a href="https://github.com/edgelesssys/marblerun-tensorflow-demo">GitHub repository</a>.</p><h3>Summary</h3><p>In this tutorial, we walked through a hands-on example for confidential inference. We demonstrated how a multi-stakeholder scenario can be organized with MarbleRun through a common manifest. For a production deployment, the next step would be to make the application scalable. Luckily, MarbleRun makes it easy to scale confidential workloads on K8s. Do let us know in the comments section if you’d like to read a tutorial on scaling the confidential inference app we discussed here.</p><p>Also, if you want to discuss confidential AI or other exciting confidential computing applications join our <a href="https://discord.gg/rH8QTH56JN">Discord</a> or <a href="/service/mailto:contact@edgeless.systems">get in touch</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2292f842e95a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Marblerun now supports Graphene — and thus your favorite programming language]]></title>
            <link>https://medium.com/@m1ghtym0/marblerun-now-supports-graphene-thus-your-favorite-programming-language-a8b8a36787a0?source=rss-d6041a5cf3aa------2</link>
            <guid isPermaLink="false">https://medium.com/p/a8b8a36787a0</guid>
            <category><![CDATA[trusted-computing]]></category>
            <category><![CDATA[confidential-computing]]></category>
            <category><![CDATA[cloud-native]]></category>
            <category><![CDATA[kubernetes]]></category>
            <category><![CDATA[intel-sgx]]></category>
            <dc:creator><![CDATA[Moritz Eckert]]></dc:creator>
            <pubDate>Thu, 01 Apr 2021 14:41:39 GMT</pubDate>
            <atom:updated>2021-04-01T14:42:36.399Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7cSWbLX55BVl9FIDkmBK2Q.png" /></figure><h3><strong>Marblerun now supports Graphene — and thus your favorite programming language</strong></h3><p>In our previous blog posts, we introduced <a href="https://medium.com/edgelesssystems/why-we-need-a-service-mesh-for-confidential-computing-part-3-3-ffc00b2c3508">Marblerun — the service mesh for confidential computing</a>.</p><p>In short, Marblerun augments existing service meshes as Linkerd, Istio, or Consul with features for traits of confidential computing applications.</p><p>We explained that Marblerun needs to inject its data plane directly into the application’s enclave to maintain confidentiality and integrity.</p><p>Effectively, the data plane is a small piece of code that communicates with the control plane, authenticates, and bootstraps the enclave. It provides credentials for encrypted service-to-service communication and in the future even handles mutual TLS between enclaves.</p><p>The downside of injecting code into the enclave is that we need to be compatible with the runtime in place.</p><p>Alongside Marblerun we released <a href="https://medium.com/edgelesssystems/ego-effortlessly-build-confidential-apps-in-go-dc2b1460e1bf">EGo</a>, our solution for developing Go-based confidential applications. Both EGo and Marblerun are cloud-native and written in Go. When you build your service with EGo, it automatically adds the Marblerun data plane to your enclave.</p><p>While we love the cloud-native community and believe EGo is a fantastic tool for bringing cloud-native applications into the world of confidential computing, we understand not all workloads are written in Go. Microservice architectures can be heterogeneous with components written in many different languages.</p><p>Ideally, we would like Marblerun to be agnostic of what language and runtime a service is based on, but we are not there yet. Hence, we push forward with adding support for more types of workloads and enclave runtimes.</p><p>With the latest release of Marblerun we added support for the popular <a href="https://grapheneproject.io/">Graphene library OS</a>.</p><h4><strong>What is a library OS and why is that great news for Marblerun?</strong></h4><p>In modern operating systems, applications do not interact with the operating system’s interface directly, e.g., through syscalls. Instead, they go through a layer of libraries that implement the architecture’s ABI and interact with the system interface. This acts as a compatibility layer decoupling the architecture and operating system specifics from the language and application code.</p><p>In short, a library OS uses this layer to emulate the underlying system interface. Take for example the <a href="https://www.winehq.org/">WINE project</a> that lets you run Windows applications on a Linux system.</p><p>So, what does that have to do with SGX you might ask. Unfortunately, applications do not “just work” on SGX.</p><p>SGX imposes several restrictions on enclave code that require application changes or a layer of indirection.</p><p>Some of these restrictions are motivated by security, such as disallowing system calls inside of an enclave, so that system call results can be sanitized by shielding code in the enclave before use.</p><p>Initially, it was accepted that applications needed to be refactored for SGX. However, several library OS projects emerged that implement a Linux OS computability layer within SGX.</p><p>The most popular examples probably being <a href="https://grapheneproject.io/">Graphene</a> (sponsored by Intel) and <a href="https://occlum.io/">Occlum</a> (sponsored by Ant Financial). There is also a relatively new entrant called <a href="https://github.com/deislabs/mystikos">Mystikos</a> (sponsored by Microsoft).</p><p>They all allow running unmodified applications at the expense of a larger TCB (Trusted Computing Base) and potentially performance impact. The latter is due to the indirections and the emulation of system functionalities.</p><p>In short, library OSes are great for a lift and shift approach of running existing applications unmodified inside an enclave.</p><h4><strong>What is Graphene?</strong></h4><p>Graphene started as a research project at Stony Brook University and continued as an open-source project with contributions from Intel, Golem, Invisible Things Lab (ITL) among others.</p><p>A Graphene enclave consists of the unmodified application code, a chroot file system, and the library OS.</p><p>The central piece of a Graphene project is the so-called manifest. A small text file that describes how the application makes up the enclave and contains several SGX-related configuration parameters. Most notably the entry point of the enclave inside the filesystem.</p><h4><strong>Where does Marblerun fit in there?</strong></h4><p>When evaluating how we can integrate Graphene with Marblerun, remember that so far we injected our data plane as a small piece of code directly into your application. It runs before the actual application code, authenticates with the control plane, bootstraps the enclave, and calls the application’s main function. You would typically call this a “PreMain” approach.</p><p>Mapping this to Graphene, we would like to keep the actual application unmodified and have as few changes as possible in the project.</p><p>To that end, we add our PreMain code as an additional artifact to Graphene’s filesystem. Next, we configure Graphene to invoke our PreMain as new the entry point of the enclave and subsequently have the PreMain transfer execution to the actual application. This is possible because Graphene supports multi-process enclaves. Notably, we also support single-process mode for a quicker launch.</p><p>For further technical details please refer to the Marblerun <a href="https://www.marblerun.sh/docs/tasks/build-service-graphene/">documentation</a>.</p><p>If you are looking for a hands-on example, check out our <a href="https://github.com/edgelesssys/marblerun/tree/master/samples/graphene-hello">“Hello World” sample on GitHub</a>.</p><p>You can also find a more mature example of an <a href="https://www.marblerun.sh/docs/examples/graphene.md">nginx</a> webserver running as Marble in a confidential service mesh.</p><h4>Summary</h4><p>Marblerun takes care of all confidential computing-related tasks in microservice architectures — so that you don’t have to. With support for Graphene, Marblerun now supports heterogeneous applications built with the likes of Python or Node.js. Of course, it does not stop there. We are close to supporting Occlum-based workloads and there is more to come. Confidential computing is just lifting off and Marblerun is the cloud-native framework that gets you on board!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a8b8a36787a0" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to deploy SGX apps on Kubernetes [mini tutorial]]]></title>
            <link>https://medium.com/@m1ghtym0/how-to-deploy-sgx-apps-on-kubernetes-mini-tutorial-59d7faa9bd76?source=rss-d6041a5cf3aa------2</link>
            <guid isPermaLink="false">https://medium.com/p/59d7faa9bd76</guid>
            <category><![CDATA[golang]]></category>
            <category><![CDATA[kubernetes]]></category>
            <category><![CDATA[confidential-computing]]></category>
            <category><![CDATA[trusted-computing]]></category>
            <category><![CDATA[intel-sgx]]></category>
            <dc:creator><![CDATA[Moritz Eckert]]></dc:creator>
            <pubDate>Wed, 03 Mar 2021 20:32:52 GMT</pubDate>
            <atom:updated>2021-03-12T11:24:11.769Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/999/1*EoBXFNyCwIbkmutajJEEdg.png" /></figure><p>Secure enclaves and Confidential Computing (CC) are the talk of the town — at least in the cloud-security community. Intel’s SGX processors in particular have made it possible to execute code in a Trusted Execution Environment (TEE) and thus guarantee encryption even during processing in the CPU — verification included. But of course, for Confidential Computing to catch on, apps have to be built that run on processors like Intel-SGX. And, of course, these apps need to be deployed in a scalable way. That’s why this tutorial is about how to easily deploy SGX apps on Kubernetes.</p><h4><strong>Step 1: Having a Kubernetes cluster that exposes SGX to your apps</strong></h4><p>First of all, you will need Kubernetes nodes with SGX-capable CPUs. The way Kubernetes handles “special devices” as SGX is through so-called “device plugins”. Multiple SGX device plugins exist for Kubernetes, e.g.:</p><ul><li><a href="https://intel.github.io/intel-device-plugins-for-kubernetes/cmd/sgx_plugin/README.html">Intel</a></li><li><a href="https://github.com/Azure/aks-engine/blob/master/docs/topics/sgx.md">Azure</a></li></ul><p>Once you’ve equipped a node with such a device plugin, they provide you with a mechanism to expose the SGX device to your containers.</p><h4><strong>Step 2: Building SGX apps for Kubernetes and accessing SGX resources</strong></h4><p>In the next step, you will need to bundle your enclave into a container and write the Kubernetes resource definitions. The most common language for cloud-native applications is probably Golang. There is a good <a href="https://github.com/edgelesssys/emojivoto">example</a> for a confidential microservice application based on the <a href="http://www.ego.dev/">EGo framework</a>, which uses the Azure device plugin for exposing SGX to the containers.</p><h4><strong>Step 3: Managing attestation, sealing, etc. for your SGX app</strong></h4><p>Probably the most interesting point, when deploying SGX apps on Kubernetes, is SGX-specific orchestration. While Kubernetes handles all the general orchestration, SGX-specific task as remote-attestation, migration, and secrets management of your deployments need to be handled separately. The Marblerun service mesh addresses those tasks, namely:</p><ul><li><a href="https://marblerun.sh/docs/features/attestation/">Attestation of your services</a></li><li><a href="https://marblerun.sh/docs/features/recovery/">Migration and Recovery</a></li><li><a href="https://marblerun.sh/docs/features/secrets-management/">Secrets Management</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=59d7faa9bd76" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>