Podcast
Questions and Answers
What is the primary goal of maintaining confidentiality in cloud computing?
What is the primary goal of maintaining confidentiality in cloud computing?
- Encryption of data to prevent access by unauthorized parties (correct)
- Monitoring data usage across the cloud environment
- Ensuring data is available to all network users
- Regularly backing up data to prevent loss
Which method is commonly used to ensure data integrity in cloud computing?
Which method is commonly used to ensure data integrity in cloud computing?
- Implementing a digital signature or MAC (correct)
- Data replication across multiple servers
- Regularly deleting old data
- Using encryption to protect data
What does the command 'clflush' do in the context of memory operations?
What does the command 'clflush' do in the context of memory operations?
- It modifies the contents of a memory location
- It reads data from a specified memory address
- It encrypts the data at the specified address
- It clears the cache for a specified address (correct)
What effect does the instruction 'mfence' have in a code execution context?
What effect does the instruction 'mfence' have in a code execution context?
What does the instruction 'jmp code1a' signify in the provided code snippet?
What does the instruction 'jmp code1a' signify in the provided code snippet?
What is considered a major concern regarding data in cloud computing?
What is considered a major concern regarding data in cloud computing?
Which aspect does NOT significantly contribute to vulnerabilities in cloud computing?
Which aspect does NOT significantly contribute to vulnerabilities in cloud computing?
What security measure is considered important at the application level in cloud security?
What security measure is considered important at the application level in cloud security?
Which of the following poses a privacy threat for cloud providers?
Which of the following poses a privacy threat for cloud providers?
What is a significant risk associated with the horizontal co-location of resources in cloud computing?
What is a significant risk associated with the horizontal co-location of resources in cloud computing?
Why is it essential for cloud providers to be trustworthy?
Why is it essential for cloud providers to be trustworthy?
What specific aspect should cloud computing security focus on?
What specific aspect should cloud computing security focus on?
Which type of security is critical for ensuring system integrity in cloud services?
Which type of security is critical for ensuring system integrity in cloud services?
What is the purpose of the function process_request in the enclave construction?
What is the purpose of the function process_request in the enclave construction?
Which statement about the enclave's contents is true?
Which statement about the enclave's contents is true?
What is a critical issue that arises from using untrusted memory for enclave content?
What is a critical issue that arises from using untrusted memory for enclave content?
What happens if the verify_MAC function returns false in process_request?
What happens if the verify_MAC function returns false in process_request?
Which instruction is used to add contents to the enclave?
Which instruction is used to add contents to the enclave?
What is the primary responsibility of dedicated security experts in cloud platforms?
What is the primary responsibility of dedicated security experts in cloud platforms?
What type of attacks can be conducted on cloud systems?
What type of attacks can be conducted on cloud systems?
What is NOT a type of vulnerability commonly exploited in cloud computing?
What is NOT a type of vulnerability commonly exploited in cloud computing?
What distinguishes the attack surface in cloud computing?
What distinguishes the attack surface in cloud computing?
What is the function of isolation provided by protected mode in modern operating systems?
What is the function of isolation provided by protected mode in modern operating systems?
Which of the following represents a component of the trusted computing base (TCB) in cloud platforms?
Which of the following represents a component of the trusted computing base (TCB) in cloud platforms?
Which example is classified as a direct hardware attack on cloud systems?
Which example is classified as a direct hardware attack on cloud systems?
What is a significant limitation of protected mode regarding application security?
What is a significant limitation of protected mode regarding application security?
What is the primary encryption method used by CryptDB for efficient query processing?
What is the primary encryption method used by CryptDB for efficient query processing?
What is a disadvantage of standard encryption methods like AES in database queries?
What is a disadvantage of standard encryption methods like AES in database queries?
In the context of CryptDB, what does the term 'indistinguishability' refer to?
In the context of CryptDB, what does the term 'indistinguishability' refer to?
What is the outcome of the randomization used in CryptDB's encryption approach?
What is the outcome of the randomization used in CryptDB's encryption approach?
Which type of attack does the randomization in CryptDB aim to prevent?
Which type of attack does the randomization in CryptDB aim to prevent?
What query capability does deterministic encryption in CryptDB allow?
What query capability does deterministic encryption in CryptDB allow?
Which of the following is NOT an encryption characteristic of CryptDB?
Which of the following is NOT an encryption characteristic of CryptDB?
What kind of trade-offs does CryptDB present when it comes to encryption methods?
What kind of trade-offs does CryptDB present when it comes to encryption methods?
What is the purpose of the function verify_MAC
in the trusted code?
What is the purpose of the function verify_MAC
in the trusted code?
What will happen if the return value of EENTER
is less than zero?
What will happen if the return value of EENTER
is less than zero?
Which function is responsible for decrypting the message before processing?
Which function is responsible for decrypting the message before processing?
In the main loop, what type of operation does receive
perform on request_buf
?
In the main loop, what type of operation does receive
perform on request_buf
?
What is the role of send
in the enclave code?
What is the role of send
in the enclave code?
Which part of the provided application is untrusted code?
Which part of the provided application is untrusted code?
What does the process_msg
function do?
What does the process_msg
function do?
What does the EEXIT
function signify in the code?
What does the EEXIT
function signify in the code?
Flashcards
Why are cloud platforms vulnerable?
Why are cloud platforms vulnerable?
Cloud computing platforms and services are attractive targets for attackers due to the large amount of data stored centrally, the availability of online access, the limited control over hardware and software, and the multi-tenancy model that allows for attackers to potentially exploit multiple companies' data and resources.
Why is cloud security important?
Why is cloud security important?
The security of cloud computing systems is essential because they store and process sensitive data. This includes ensuring that data is kept confidential, intact, and available only to authorized users.
What is a primary motive for attacks on cloud platforms?
What is a primary motive for attacks on cloud platforms?
The potential for financial gain by selling or trading stolen data is a major motivator for attackers targeting cloud platforms.
How does limited control over hardware and software impact cloud security?
How does limited control over hardware and software impact cloud security?
Signup and view all the flashcards
How does multi-tenancy impact cloud security?
How does multi-tenancy impact cloud security?
Signup and view all the flashcards
What are the trust concerns associated with cloud providers?
What are the trust concerns associated with cloud providers?
Signup and view all the flashcards
What specific security measures are needed for cloud environments?
What specific security measures are needed for cloud environments?
Signup and view all the flashcards
How does cloud security require a comprehensive approach?
How does cloud security require a comprehensive approach?
Signup and view all the flashcards
Malicious Application
Malicious Application
Signup and view all the flashcards
Protected Mode
Protected Mode
Signup and view all the flashcards
Privileged Code Attacks
Privileged Code Attacks
Signup and view all the flashcards
Attack Surface
Attack Surface
Signup and view all the flashcards
Hardware Attacks
Hardware Attacks
Signup and view all the flashcards
Trusted Computing Base (TCB)
Trusted Computing Base (TCB)
Signup and view all the flashcards
Software Vulnerability Exploitation
Software Vulnerability Exploitation
Signup and view all the flashcards
Exploiting Vulnerabilities
Exploiting Vulnerabilities
Signup and view all the flashcards
Confidentiality in Cloud Security
Confidentiality in Cloud Security
Signup and view all the flashcards
Integrity in Cloud Security
Integrity in Cloud Security
Signup and view all the flashcards
Sandbox Escape
Sandbox Escape
Signup and view all the flashcards
Corrupted Page Table
Corrupted Page Table
Signup and view all the flashcards
Memory Protection
Memory Protection
Signup and view all the flashcards
Cache
Cache
Signup and view all the flashcards
Memory Management
Memory Management
Signup and view all the flashcards
Cache Flush
Cache Flush
Signup and view all the flashcards
MFENCE
MFENCE
Signup and view all the flashcards
Memory Leak
Memory Leak
Signup and view all the flashcards
Enclave
Enclave
Signup and view all the flashcards
Enclave Construction
Enclave Construction
Signup and view all the flashcards
Enclave Page Cache (EPC)
Enclave Page Cache (EPC)
Signup and view all the flashcards
EADD Instruction
EADD Instruction
Signup and view all the flashcards
Enclave Integrity
Enclave Integrity
Signup and view all the flashcards
Verify MAC
Verify MAC
Signup and view all the flashcards
Decrypt Message
Decrypt Message
Signup and view all the flashcards
Trusted Code
Trusted Code
Signup and view all the flashcards
Process Request
Process Request
Signup and view all the flashcards
Copy Message
Copy Message
Signup and view all the flashcards
Encrypt Message
Encrypt Message
Signup and view all the flashcards
Trusted Environment
Trusted Environment
Signup and view all the flashcards
Why are standard encryption methods like AES unsuitable for querying encrypted data?
Why are standard encryption methods like AES unsuitable for querying encrypted data?
Signup and view all the flashcards
What is the basic idea behind deterministic encryption and its limitations?
What is the basic idea behind deterministic encryption and its limitations?
Signup and view all the flashcards
How does CryptDB address the trade-off between security and query expressiveness?
How does CryptDB address the trade-off between security and query expressiveness?
Signup and view all the flashcards
What are the security strengths and limitations of random encryption?
What are the security strengths and limitations of random encryption?
Signup and view all the flashcards
What are the security weaknesses and querying capabilities of deterministic encryption?
What are the security weaknesses and querying capabilities of deterministic encryption?
Signup and view all the flashcards
What are the key encryption techniques used by CryptDB and their benefits?
What are the key encryption techniques used by CryptDB and their benefits?
Signup and view all the flashcards
How does CryptDB enhance security by linking encryption keys to user passwords?
How does CryptDB enhance security by linking encryption keys to user passwords?
Signup and view all the flashcards
Study Notes
Cloud Computing - Lesson 9 : Security
Course Information
- Course Title: Cloud Computing
- Course Code: LINFO2145
- Lesson: 9 - Cloud Security
- Instructor: Pr. Etienne Rivière
- Contact: [email protected]
Announcements
- Quiz 3: Lectures 5 and 6, results available after this lecture
- Quiz 4: Lectures 7 and 8, available after this lecture, Due: Nov 27, 10:45
- Reviews: Dec 4, 10:45
Lecture Objectives
- Introduce security concerns from cloud computing
- Overview of data and computation integrity protection in cloud
- Describe new approaches for confidential data processing in the cloud
Introduction (1)
- Cloud computing platforms and applications are tempting attack targets
- Large amounts of data are stored centrally
- Sensitive data is often publicly available, making it an attractive target for malicious activity
- Limited control of software stacks, particularly in PaaS.
- Multi-tenancy creates larger attack surfaces
- Co-location of resources creates new attack opportunities.
- Single point of failure within one service can affect other services
Introduction (2)
- High trust required of cloud providers
- Cloud providers need to comply with local privacy regulations (e.g. PATRIOT Act)
- Security concerns are specific to cloud systems
- Application-level and OS-level security practices remain important
Why is Cloud Security Important?
- Major breaches like the Yahoo (1 billion accounts) and Dropbox (68 million) hacks, and the 2012 LinkedIn breach highlight the need for robust cloud security
The Provider Perspective
- Cloud providers must protect their customers from malicious actors
- Hypervisor-based isolation provides a limited security guarantee
- One-way protection: the provider does not protect the customer from the provider
The Client Perspective
- Cloud tenants must trust their providers, including personnel and software components
- Ideally, clients would only trust their portion of the service
Multi-tenancy and Security
- Resource sharing in virtualization creates new security threats
- Hypervisors and VMs are vulnerable to attacks impacting all tenants
- Access to the hypervisor gives access to all VM memory, including the kernel and page tables.
- Dedicated security experts and best practices are important.
Protected Mode Not Sufficient
- Protected mode (rings) is insufficient to prevent exploits
- Malicious applications can exploit flaws, gaining full privileges and potentially compromising the operating system or other applications
- Attack surface includes the entire software stack, comprising applications, OS, VMM, drivers, and BIOS
Example of Protection Rings in Microsoft Hypervisor
- Depicts layers of isolation for different components within a hypervisor
- Emphasizes the separation of different parts of the hypervisor
Attacking the Cloud
- Attacks are performed by executing software on the victim's computer, including remote execution
- Most attacks exploit vulnerabilities in software components, including exploitable memory safety vulnerabilities in C/C++
- Malicious APIs target services and infrastructure management interfaces
- Hardware vulnerabilities like Spectre and Meltdown, and RowHammer attacks are also possible
The Software Stack
- Cloud platforms utilize enormous amounts of code that must be trusted
- Examples of codebases include Linux, KVM, and OpenStack
Bugs are a Reality
- More code generally means more bugs
- Exploited vulnerabilities can lead to complete disclosure of sensitive data
- Xen hypervisor and Linux kernel have a significant number of reported vulnerabilities (e.g., 184 for Xen, 721 for Linux kernel in a given time period)
Examples of Software Attacks
- Control-flow hijacking: Goal is to execute arbitary code.
- Code injection attacks: Overwriting addresses to inject code
- Return-oriented programming: Stack corruption to execute existing instructions
Example: Heartbleed Bug
- Serious vulnerability in OpenSSL
- Widely used; targets web servers, email, chat, and VPNs
- Buffer overrun in heartbeat message handling resulting in exposure of memory
- Exploited to read server memory, including sensitive data like passwords, private keys, etc.
Other Examples
- "All your clouds are belong to us" (2011): attacks targeting EC2 management APIs
- Colocation attacks: targeting VMs on public clouds
- Attacks at hypervisor, OS and CPU level
- Exploit bugs to gain access to cached content from VMs, perform bus sniffing, obtain memory communication or perform cold boot attacks.
Hardware Attacks in the Cloud
- Hardware based attacks may or may not require direct physical access to the host
- With physical access, attacks include bus sniffing, and obtaining memory communication in DRAM
- Cold boot attacks obtain memory values during power cycles using short-lived memory state
Remote Hardware Attacks: "Row Hammer"
- Attacking physical memory to flip bits in neighboring memory
- Can cause sandbox escapes and corrupted page tables
Goals: Security in the Cloud
- Confidentiality: Protecting data from unauthorized access.
- Integrity: Protecting data from unauthorized modification
Tools: Cryptographic Hash Function
- Algorithm mapping arbitrary inputs into fixed-size outputs
- Infeasible inversion. Collision resistant
- More computationally intensive compared to generic hashes
Tools: Symmetric Cryptography
- Shared secret key for encryption and decryption
- Example: Advanced Encryption Standard (AES)
Tools: Symmetric Cryptography - MAC
- Message authentication code (MAC)
- Integrity and authenticity checking of messages
- Key required to produce a MAC
- Does not offer confidentiality
Tools: Asymmetric Cryptography
- Each party has a public and private key pair
- Public key used for encryption; private key for decryption
- Example: Rivest-Shamir-Adleman (RSA)
Tools: Asymmetric Cryptography - MAC (Digital Signature)
- Digital signature in asymmetric cryptography
- Signed using the sender's private key, verified with public key
- Ensures message integrity and authenticity
Ensuring Data Confidentiality
- Data-at-rest protection: Encrypting data directly on disk (e.g., full-disk encryption and encrypted file systems)
- Data-in-flight protection: Using end-to-end encryption mechanisms like TLS
Ensuring Data Confidentiality - TPM (Trusted Platform Module)
- Hardware security chip
- Generates and stores cryptographic keys
- Provides remote attestation
Ensuring Data Confidentiality – In-use Data
- Decrypting data before processing to maintain confidentiality in-use
- Confidentiality required during computations in the cloud
Securing Data During Computation
- Searchable data while protecting against security attacks on data distribution
- Privacy-utility-performance tradeoff consideration when applying security measures
Tools
- Software-Level Encryption
- Specific and generic encryption mechanisms
- Hardware support for trusted computing
- Homomorphic encryption
Encrypted Data Processing - Homomorphic Encryption
- Allows computation on encrypted data without decryption
- Enables operations like addition and multiplication on encrypted data; maintains confidentiality throughout computation.
- Example: Fully homomorphic encryption
Homomorphic Encryption - HELib
- Open-source homomorphic encryption library developed by IBM
- Designed to make homomorphic encryption more practical
- Low-level routines (addition, multiplication, etc.)
- Performance improvements but still requires significant resources, far from being practical in terms of computation time
Specific Encryption Schemes
- Homomorphic encryption (generic but costly)
- Specific schemes for targeted operations (e.g., exact match, nearest match, range, equality)
- Example: CryptDB (encrypted SQL database)
CryptDB: Encrypted SQL Database
- Proxy between the client and the database to handle query rewrites and data encryption/decryption.
- Prevents exposure of sensitive data to the untrusted zone of the cloud environment (especially in servers or proxy)
- Provides standard encryption (AES) but prevents from arbitrary query execution in non-trusted environment
CryptDB: Encryption Levels (1)
- Random encryption (e.g., AES): No data query possible
- Deterministic encryption (e.g., Pseudorandom permutation): Equality searches possible but maintains ciphertext integrity
- Order-preserving encryption: Enables range queries
CryptDB Encryption Levels (2)
- Summation homomorphic: Enables summation operations on encrypted data
- Joins: Enables joins across encrypted data; encryption key may be different
- Word Search: Limited full-word functionality but vulnerable with known frequency attacks
Onion Layers Encryption
- Multi-level encryption layer structure
- Security and privacy depend on how a specific level of encryption can be handled and how many levels of encryption an application requires
CryptDB Performance
- Performance of CryptDB can vary depending on the workload and number of cores
- Performance can be slower by an order of magnitude compared to non-encrypted databases due to the increased processing tasks from encryption/decryption
- Additional proxy server cost
Towards Hardware Support
- Software-based confidentiality or data protections have limited applicability and performance limitations
- The trusted computing base traditionally encompasses hardware and software stack, but there is a need to reduce this trusted code base to allow application enclaves
Intel SGX
- "Software Guard Extensions" in Intel CPUs (e.g. Skylake, Kaby Lake)
- Provides hardware-level protection for code and data in untrusted environments
- Platform owner considered malicious
- Only the CPU chip and isolated enclave are considered trusted
Enclaves
- Isolated memory regions (enclaves) for code and data
- Enclave content is protected by the hardware (Memory Encryption Engine [MEE])
- Plaintext secrets are prevented from being directly stored in main memory
- Enclave memory accessible only by enclave code, protecting against privilege escalation attacks
Enclave Memory
- Enclave memory is not accessible to other software
- Enclaves can access memory within the process
- Application can protect its secrets, reducing attack surface
Enclave Memory APIs
- ECALLs are enclave interface functions, providing input to the enclave
- OCALLs are enclave calls for returning results outside of the enclave
SGX Execution Model
- Trusted execution environment within a process, with dedicated code and data
- Controlled entry points
- Confidentiality and integrity provisioned
- Multiple threads support
- Full access to application memory
Enclave Page Cache (EPC)
- Physical memory region protected by the MEE
- EPC holds enclave contents
- Shared resource for all enclaves on the platform
- Content encryption in DRAM; decryption when brought to CPU
- Larger EPC sizes available in newer versions
SGX Limitations
- Memory limit for enclaves
- Security not absolute (vulnerabilities may exist)
- Performance is generally impacted compared to other approaches (enclave entry/exit, paging are costly)
- Legacy code, and application partitioning considerations
Conclusion
- Cloud security requires both general security practices and new techniques specific to cloud architectures (e.g., attacks on colocated and trusted code)
- Encryption of data in the cloud is beneficial
- Trusted Execution Environments (HW support) offer a way to reduce the trusted code base and trust only the required application enclaves
References (1/2) and (2/2)
- Includes a large list of academic papers which are relevant to cloud security practices
SGX Primer
- Introduction to writing SGX applications
1. Define Interface
- Enclave definition language (myenclave.edl) for function declarations
- untrusted and trusted sections for separating function declarations
2. Write Code
- Application (application.c) code and enclave (myenclave.c) code example (including
main()
andcompute())
functions - Demonstrate the
sgx_initialize_enclave
andecall_compute
calls
3. Compile Code
- Compilation of
application.c
,myenclave.c
to generatemyenclave.so
anda.out
- gcc, different compiler flags
4. Sign Code and Run
- Signing
myenclave.so
using SGX specific tool (sgx_sign
,private_key.pem
) - Execution and results from the application
Studying That Suits You
Use AI to generate personalized quizzes and flashcards to suit your learning preferences.