skip to main content
10.1145/3620678.3624789acmconferencesArticle/Chapter ViewAbstractPublication PagesmodConference Proceedingsconference-collections
research-article

Cryonics: Trustworthy Function-as-a-Service using Snapshot-based Enclaves

Published:31 October 2023Publication History

ABSTRACT

Recent research has proposed the use of trusted execution environments (TEEs), such as SGX, in serverless computing to safeguard against threats from insecure system software, malicious co-located tenants, or suspicious cloud operators. However, integrating SGX, one of the most mature TEE, with serverless computing results in significant performance degradation due to the function startup latency caused by enclave creation. This performance degradation arises because SGX is not designed with serverless function startup procedures in mind, where numerous application codes, libraries, and data are re-initialized upon each function invocation. The inherent limitations of SGX contribute to significant performance degradation, whether through the addition of every page into the enclave, or the restriction of page permissions, which ultimately cause TLB flushes, context switches, and re-entering the enclave. In this paper, we first take key observations resident in the intrinsic features of the server-less function and propose Cryonics, a method of serving snapshot-based enclave that accelerates the startup time of the function instance by creating a future-proof working set of that. We consider the page locality and obsolete pages of the enclaved function instance to create a lightweight working set used for serving requests. Our evaluation shows that Cryonics achieves up to 100x outperformed startup time compared to existing cold-start-based methods and reveals the stability of the startup time.

References

  1. Istemi Ekin Akkus, Ruichuan Chen, Ivica Rimac, Manuel Stein, Klaus Satzke, Andre Beck, Paarijaat Aditya, and Volker Hilt. 2018. SAND: Towards High-Performance Serverless Computing. In Proceedings of USENIX Annual Technical Conference (ATC '18).Google ScholarGoogle Scholar
  2. Fritz Alder, N. Asokan, Arseny Kurnikov, Andrew Paverd, and Michael Steiner. 2019. S-FaaS: Trustworthy and Accountable Function-as-a-Service using Intel SGX. In Proceedings of ACM SIGSAC Conference on Cloud Computing Security Workshop (CCSW '19).Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. Sergei Arnautov, Bohdan Trach, Franz Gregor, Thomas Knauth, Andre Martin, Christian Priebe, Joshua Lind, Divya Muthukumaran, Dan O'Keeffe, Mark L Stillwell, David Goltzsche, Dave Eyers, Rüdiger Kapitza, Peter Pietzuch, and Christof Fetzer. 2016. SCONE: Secure Linux Containers with Intel SGX. In Proceedings of USENIX Symposium on Operating Systems Design and Implementation (OSDI '16).Google ScholarGoogle Scholar
  4. Ioana Baldini, Paul Castro, Kerry Chang, Perry Cheng, Stephen Fink, Vatche Ishakian, Nick Mitchell, Vinod Muthusamy, Rodric Rabbah, Aleksander Slominski, and Philippe Suter. 2017. Serverless Computing: Current Trends and Open Problems. In Research Advances in Cloud Computing.Google ScholarGoogle Scholar
  5. Andrew Baumann, Marcus Peinado, and Galen Hunt. 2014. Shielding Applications from an Untrusted Cloud with Haven. In Proceedings of USENIX Symposium on Operating Systems Design and Implementation (OSDI '14).Google ScholarGoogle Scholar
  6. Stefan Brenner and Rüdiger Kapitza. 2019. Trust more, serverless. In Proceedings of ACM International Systems and Storage Conference (SYSTOR '19).Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. J. V. Bulck, M. Minkin, O. Weisse, D. Genkin, B. Kasikci, F. Piessens, M. Silberstein, T. F. Wenisch, Y. Yarom, and R. Strackx. 2019. Foreshadow: Extracting the Keys to the Intel SGX Kingdom with Transient Out-of Order Execution. In Proceedings of USENIX Annual Technical Conference (ATC '19).Google ScholarGoogle Scholar
  8. J. V. Bulck, D. Moghimi, M. Schwarz, M. Lipp, M. Minkin, D. Genkin, Y. Yarom, B. Sunar, D. Gruss, and F. Piessens. 2020. LVI: Hijacking Transient Execution through Microarchitectural Load Value Injection. In Proceedings of 41st IEEE Symposium on Security and Privacy (S&P '20)'.Google ScholarGoogle Scholar
  9. James Cadden, Thomas Unger, Yara Awad, Han Dong, Orran Krieger, and Jonathan Appavoo. 2020. SEUSS: skip redundant paths to make serverless fast. In Proceedings of European Conference on Computer Systems (EuroSys '20).Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. Paul Castro, Vatche Isahagian, Vinod Muthusamy, and Aleksander Slominski. 2022. Hybrid Serverless Computing: Opportunities and Challenges. arXiv:2208.04213 [cs.DC]Google ScholarGoogle Scholar
  11. Sam Corcos. 2022. How to Keep Your AWS Lambda Functions Warm. Retrieved May 31, 2023 from Available:https://acloudguru.com/blog/engineering/how-to-keep-your-lambda-functions-warmGoogle ScholarGoogle Scholar
  12. Victor Costan and Srinivas Devadas. 2016. Intel SGX explained.Google ScholarGoogle Scholar
  13. Yu Ding, Ran Duan, Long Li, Yueqiang Cheng, Yulong Zhang, Tanghui Chen, Tao Wei, and Huibo Wang. 2017. POSTER: Rust SGX SDK: Towards Memory Safety in Intel SGX Enclave. In Proceedings of The ACM Conference on Computer and Communications Security (CCS '17).Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. Dong Du, Tianyi Yu, Yubin Xia, Binyu Zang, Guanglu Yan, Chenggang Qin, Qixuan Wu, and Haibo Chen. 2020. Catalyzer: Sub-millisecond startup for serverless computing with initialization-less booting. In Proceedings of 25th International Conference on Architectural Support for Programming Languages and Operating Systems (ASPLOS '20).Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. Nicolas A. Economou and Enrique E. Nissim. 2016. Getting Physical: Extreme abuse of Intel based Paging Systems. Retrieved June 4, 2023 from Available:https://www.coresecurity.com/sites/default/files/private-files/publications/2016/05/CSW2016%20-%20Getting%20Physical%20-%20Extended%20Version.pdfGoogle ScholarGoogle Scholar
  16. Xing Gao, Zhongshu Gu, Zhengfa Li, Hani Jamjoom, and Cong Wang. 2019. Houdini's Escape: Breaking the Resource Rein of Linux Control Groups. In Proceedings of the 26th ACM Conference on Computer and Communications (CCS '19).Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. David Goltzsche, Colin Wulf, Divya Muthukumaran, Konrad Rieck, Peter Pietzuch, and Rüdiger Kapitza. 2017. TrustJS: Trusted Client-side Execution of JavaScript. In European Workshop on Systems Security (EuroSec '17).Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. Google. 2022. Google Cloud Functions. Retrieved April 5, 2023 from https://cloud.google.com/functionsGoogle ScholarGoogle Scholar
  19. K. Indrasiri and D. Kuruppu. 2020. gRPC: Up and Running: Building Cloud Native Applications with Go and Java for Docker and Kubernetes. O'Reilly Media.Google ScholarGoogle Scholar
  20. Simon Johnson, Raghunandan Makaram, Amy Santoni, and Vinnie Scarlet. 2022. Supporting Intel SGX on Multi-Socket Platforms. Retrieved April 5, 2023 from Available:https://www.intel.com/content/dam/www/public/us/en/documents/whitepapers/supporting-intel-sgx-on-mulit-socket-platforms.pdfGoogle ScholarGoogle Scholar
  21. Jeongchul Kim and Kyungyong Lee. 2019. FunctionBench: A Suite of Workloads for Serverless Cloud Function Service. In Proceedings of IEEE International Conference on Cloud Computing (CLOUD '19).Google ScholarGoogle ScholarCross RefCross Ref
  22. Taehoon Kim, Joongun Park, Jaewook Woo, Seungheun Jeon, and Jaehyuk Huh. 2019. ShieldStore: Shielded In-memory Key-value Storage with SGX. In Proceedings of the The European Conference on Computer Systems (EuroSys '19).Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. Paul Kocher, Jann Horn, Anders Fogh, Daniel Genkin, Daniel Gruss, Werner Haas, Mike Hamburg, Moritz Lipp, Stefan Mangard, Thomas Prescher, Michael Schwarz, and Yuval Yarom. 2019. Spectre Attacks: Exploiting Speculative Execution. In Proceedings of 40th IEEE Symposium on Security and Privacy (S&P '19).Google ScholarGoogle ScholarCross RefCross Ref
  24. Junfeng Li, Sameer G. Kulkarni, K. K. Ramakrishnan, and Dan Li. 2019. Understanding Open Source Serverless Platforms: Design Considerations and Performance. In Proceedings of the 5th International Workshop on Serverless Computing (WoSC '19).Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. Mingyu Li, Yubin Xia, and Haibo Chen. 2021. Confidential serverless made efficient with plug-in enclaves. In Proceedings of the International Symposium on Computer Architecture (ISCA '21).Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. Frank McKeen, Ilya Alexandrovich, Alex Berenzon, Carlos V. Rozas, Hisham Shafi, Vedvyas Shanbhogue, and Uday R. Savagaonkar. 2013. Innovative Instructions and Software Model for Isolated Execution. In Proceedings of the 2nd International Workshop on Hardware and Architectural Support for Security and Privacy (HASP).Google ScholarGoogle Scholar
  27. Microsoft. 2022. Azure Functions. Retrieved April 5, 2023 from https://azure.microsoft.com/en-us/products/functionsGoogle ScholarGoogle Scholar
  28. MITRE. 2014. CVE-2014-9357. Retrieved April 5, 2023 from https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2014-9357Google ScholarGoogle Scholar
  29. MITRE. 2015. CVE-2015-3456. Retrieved April 5, 2023 from https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2015-3456Google ScholarGoogle Scholar
  30. MITRE. 2015. CVE-2015-5154. Retrieved April 5, 2023 from https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2015-5154Google ScholarGoogle Scholar
  31. Anup Mohan, Harshad Sane, Kshitij Doshi, Saikrishna Edupuganti, Naren Nayak, and Vadim Sukhomlinov. 2019. Agile Cold Starts for Scalable Serverless. In Proceedings of the 11th USENIX Workshop on Hot Topics in Cloud Computing (HotCloud '19).Google ScholarGoogle ScholarDigital LibraryDigital Library
  32. Edward Oakes, Leon Yang, Dennis Zhou, Kevin Houck, Tyler Harter, Andrea C. Arpaci-Dusseau, and Remzi H. Arpaci-Dusseau. 2018. SOCK: Rapid Task Provisioning with Serverless-Optimized Containers. In Proceedings of USENIX Annual Technical Conference (ATC '18).Google ScholarGoogle Scholar
  33. Christian Priebe, Divya Muthukumaran, Joshua Lind, Huanzhou Zhu, Shujie Cui, and Vasily A. Sartakovand Peter Pietzuch. 2019. SGX-LKL: Securing the Host OS Interface for Trusted Execution. In arXiv:1908.11143.Google ScholarGoogle Scholar
  34. Christian Priebe, Kapil Vaswani, and Manuel Costa. 2018. EnclaveDB: A secure database using SGX. In Proceedings of 39th IEEE Symposium on Security and Privacy (S&P '18).Google ScholarGoogle ScholarCross RefCross Ref
  35. Anjo Vahldiek-Oberwagner Thomas Knauth Pramod Bhatotia Christof Fetzer Robert Krahn, Bohdan Trach. 2018. Pesos: Policy Enhanced Secure Object Store. In ACM EuroSys.Google ScholarGoogle Scholar
  36. Peter Sbarski and Sam Kroonenburg. 2017. Serverless architectures on AWS: with examples using Aws Lambda. Manning Publications, New York.Google ScholarGoogle Scholar
  37. Felix Schuster, Manuel Costa, Cedric Fournet, Christos Gkantsidis, Marcus Peinado, Gloria Mainar-Ruiz, and Mark Russinovich. 2015. VC3: Trustworthy Data Analytics in the Cloud using SGX. In Proceedings of 36th IEEE Symposium on Security and Privacy (S&P '15).Google ScholarGoogle ScholarDigital LibraryDigital Library
  38. Mohammad Shahrad, Rodrigo Fonseca, Íñigo Goiri, Gohar Chaudhry, Paul Batum, Jason Cooke, Eduardo Laureano, Colby Tresness, Mark Russinovich, and Ricardo Bianchini. 2020. Serverless in the Wild: Characterizing and Optimizing the Serverless Workload at a Large Cloudd Provider. In Proceedings of USENIX Annual Technical Conference (ATC '20).Google ScholarGoogle Scholar
  39. Shweta Shinde, Dat Le Tien, Shruti Tople, and Prateek Saxena. 2017. Panoply: Low-TCB Linux Applications With SGX Enclaves. In Proceedings of the Network and Distributed System Security (NDSS) Symposium (NDSS '17).Google ScholarGoogle ScholarCross RefCross Ref
  40. Paulo Silva, Daniel Fireman, and Thiago Emmanuel Pereira. 2020. Prebaking Functions to Warm the Serverless Cold Start. In Proceedings of the annual ACM/IFIP Middleware conference (Middleware '20).Google ScholarGoogle ScholarDigital LibraryDigital Library
  41. ASYLO TEAM. 2019. Real-World Applications in Enclaves. Retrieved April 5, 2023 from https://asylo.dev/blog/2019/asylo-redis-sqlite.htmlGoogle ScholarGoogle Scholar
  42. Dave (Jing) Tian, Joseph Choi, Grant Hernandez, Patrick Traynor, and Kevin Butler. 2019. A practical intel sgx setting for linux containers in the cloud. In Proceedings of ACM Conference on Data and Application Security and Privacy (CODASPY '19).Google ScholarGoogle ScholarDigital LibraryDigital Library
  43. Bohdan Trach, Alfred Krohmer, Franz Gregor, Sergei Arnautov, Pramod Bhatotia, and Christof Fetzer. 2018. ShieldBox: Secure Middle-boxes using Shielded Execution. In Proceedings of Symposium on SDN Research (SOSR '18).Google ScholarGoogle ScholarDigital LibraryDigital Library
  44. Bohdan Trach, Oleksii Oleksenko, Franz Gregor, Pramod Bhatotia, and Christof Fetzer. 2019. Clemmys: Towards Secure Remote Execution in FaaS. In Proceedings of the ACM International Systems and Storage Conference (SYSTOR '19).Google ScholarGoogle ScholarDigital LibraryDigital Library
  45. Muoi Tran, Loi Luu, Min Suk Kang, Iddo Bentov, and Prateek Saxena. 2018. Obscuro: A Bitcoin Mixer using Trusted Execution Environments. In Proceedings of the Annual Computer Security Applications Conference (ACSAC '18).Google ScholarGoogle ScholarDigital LibraryDigital Library
  46. Chia-Che Tsai, Donald E. Porter, and Mona Vij. 2017. Graphene-SGX: A Practical Library OS for Unmodified Applications on SGX. In Proceedings of USENIX Annual Technical Conference (ATC '17).Google ScholarGoogle Scholar
  47. Dmitrii Ustiugov, Plamen Petrov, Marios Kogias, Edouard Bugnion, and Boris Grot. 2021. Benchmarking, Analysis, and Optimization of Serverless Function Snapshots. In Proceedings of the 26th ACM International Conference on Architectural Support for Programming Languages and Operating Systems (ASPLOS '21).Google ScholarGoogle ScholarDigital LibraryDigital Library
  48. Ofir Weisse, Valeria Bertacco, and Todd Austin. 2017. Regaining lost cycles with HotCalls: A fast interface for SGX secure enclaves. In Proceedings of the 44th Annual International Symposium on Computer Architecture (ISCA '17).Google ScholarGoogle ScholarDigital LibraryDigital Library
  49. Matthew Wilcox. 2018. XArray. Retrieved April 5, 2023 from Available: https://docs.kernel.org/core-api/xarray.htmlGoogle ScholarGoogle Scholar
  50. Y. Xu, W. Cui, and M. Peinado. 2015. Controlled-Channel Attacks: Deterministic Side Channels for Untrusted Operating Systems. In Proceedings of 36th IEEE Symposium on Security and Privacy (S&P '15).Google ScholarGoogle Scholar

Index Terms

  1. Cryonics: Trustworthy Function-as-a-Service using Snapshot-based Enclaves

    Recommendations

    Comments

    Login options

    Check if you have access through your login credentials or your institution to get full access on this article.

    Sign in
    • Published in

      cover image ACM Conferences
      SoCC '23: Proceedings of the 2023 ACM Symposium on Cloud Computing
      October 2023
      624 pages
      ISBN:9798400703874
      DOI:10.1145/3620678

      Copyright © 2023 ACM

      Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than the author(s) must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected].

      Publisher

      Association for Computing Machinery

      New York, NY, United States

      Publication History

      • Published: 31 October 2023

      Permissions

      Request permissions about this article.

      Request Permissions

      Check for updates

      Qualifiers

      • research-article
      • Research
      • Refereed limited

      Acceptance Rates

      Overall Acceptance Rate169of722submissions,23%
    • Article Metrics

      • Downloads (Last 12 months)167
      • Downloads (Last 6 weeks)17

      Other Metrics

    PDF Format

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader