代写csec5615 Assignment 2 s1 2025

2025-05-15 代写csec5615 Assignment 2 s1 2025

csec5615

Assignment 2 (100 marks)

s1 2025

Problem 1.(15 marks) A cloud provider wants to store a cryptographic secret S securely across n cloud servers using Shamir’s Secret Sharing (SSS). However, each setup has a different risk model affecting the required threshold.

For each scenario:

1. Determine the threshold t that ensures security. (1 mark)

2. Find the polynomial’s degree. (1 mark)

3. Choose a polynomial f(x) of the required degree, to share the secret. (1 mark)

4. Compute and distribute shares for x = 1, 2, 3, . . . , n. (2 marks)

Scenario 1: A small cloud network with n = 5 servers.

1. The system is secure as long as at most one server is compromised.

2. Secret: S = 10.

Scenario 2: A large cloud storage provider with n = 7 servers.

1. The provider assumes that external attackers can corrupt at most 2 servers.

2. Additionally, an insider may compromise 1 additional server.

3. Secret: S = 20.

Scenario 3: A blockchain-based cloud storage system with n = 6 servers.

1. The threat model assumes 2 external attackers.

2. Additionally, there is a risk of random crashes on 1 additional server.

3. Secret: S = 25.

Problem 2. (5 marks) A financial institution integrates advanced Security-as-a-Service (SECaaS) offerings into its cloud-based infrastructure. Recommend suit-able solutions for the following scenarios:

1. Allow auditing teams to access historical transaction logs without risking data modification or compromise.

2. Provide automated recovery mechanisms to preserve financial data in-tegrity and operational continuity during disruptions.

3. Ensure employees can securely process transactions remotely, using multi-factor authentication.

4. Prevent unauthorized access to customer financial records, ensuring strict encryption and compartmentalized storage.

5. Detect unusual transaction patterns across cloud-based systems, providing real-time alerts to the security team.

Provide a one-sentence justification for each recommendation.

Problem 3. (10 marks)

A company wants to secure its cloud-based web application against Man-in-the-Middle (MITM) attacks using TLS.

However, users are reporting security warnings when accessing the site, and attackers are still able to intercept some data. After investigation, the security team finds the following issues:

1. Some users manually bypass certificate warnings in their browsers.

2. The application server accepts outdated encryption algorithms for compat-ibility reasons.

3. An internal system administrator disabled certificate validation on API re-quests for testing.

4. Some API endpoints are accessible without HTTPS, allowing attackers to intercept sensitive data.

5. The company uses self-signed certificates for internal services without proper distribution of trust anchors.

(a) Explain how each of these issues could allow a MITM attack despite using TLS. (5 marks, 1 per issue) (b) For each issue, suggest a security measure that could mitigate the risk effectively. (5 marks, 1 per issue)

Problem 4. (13 marks)

Scenario 1: A streaming platform. offers age-restricted content. Users must prove to a cloud-based age verification system that they are at least 18 years old.

1. Do we need ZK? Where, and why or why not? (1 mark)

2. Irrespective of ZK, what is the soundness guarantee we need and why is it necessary? (1 mark)

3. What is the statement? (1 mark)

4. What is the witness? (1 mark)

Scenario 2: A country implements an online cloud-based voting system where users cast private votes that is either a 0 or a 1, and the system must count votes and announce results.

1. If the users encrypt their votes, do they need to add a ZK proof to the vote? Why or why not? (2 marks)

2. Irrespective of ZK, what is the soundness guarantee we need and why is it necessary? (1 mark)

3. What is the statement? (1 mark)

4. What is the witness? (1 mark)

Scenario 3: A company provides a cloud-based file storage system. Employees access files based on role-based permissions. The cloud verifies if a user has permission to access a file using a proof that the user gives.

1. Do we need ZK? Why or why not? (1 mark)

2. Irrespective of ZK, what is the soundness guarantee we need and why is it necessary? (1 mark)

3. What is the statement? (1 mark)

4. What is the witness? (1 mark)

Problem 5. (15 marks)

Scenario: A company stores employee salaries in a cloud database. The salaries stored in the form. (EmpID,sID), where EmpID is the employee ID and sID is the salary for that employee ID. Employee Alice wants to get a pay raise and wants to ask the cloud if her salary is above or below the mean salary of the employees. The company authorizes the cloud to give this service. The cloud must prove that:

1. It correctly computed the median salary from the dataset.

2. It correctly compared the employee’s salary to the mean without revealing any other information about the mean or other salaries.

Available Tools:

1. Additively homomorphic encryption (HE) which the cloud can use to en-crypt the salaries and compute on.

2. Zero Knowledge Proofs for correct encryptions: This proof allows the prover to prove that a ciphertext encrypts the correct salary for an asso-ciated employee ID EmpID. That is, the proof proves in zero-knowledge that the ciphertext encrypts sID (the salary of EmpID) without leaking any information about sID. The proof is also sound in that the prover cannot cheat.

3. Zero Knowledge Proofs of correct Encrypted Comparisons: Used to prove that a value v that is given in plain is smaller or larger than the value en-crypted inside a ciphertext, without revealing any other information about the value encrypted. The proof is also sound in that the prover cannot cheat with the comparison.

Questions:

1. Design a zero-knowledge proof interaction between Alice and the cloud, where in the end Alice is convinced if her salary is lower or above the mean value. Use the tools provided above and describe the protocol flow in detail. (4 marks)

2. Argue why the design satisfies zero-knowledge, i.e., privacy of others’ salaries is preserved against a malicious Alice. (4 marks) [Hint: Use the privacy properties of the tool one by one.]

3. Argue why the design does not let a malicious cloud cheat Alice into think-ing her salary is higher than the mean, in other words, argue why the design is sound. (4 marks) [Hint: Use the soundness properties of underlying tools used.]

4. In your design, can the cloud use false data for salaries of others? Why or why not? (3 marks)

Problem 6. (15 marks)

Scenario 1: A cloud-based file storage system uses role-based access control (RBAC) with the following roles:

1. Admin: Full access to upload, download, delete any documents.

2. Manager: Can upload and download documents, but only within their de-partment.

3. Employee: Can only download documents associated with their own user ID.

Suppose Alice is an Admin, Bob is a Manager (Department A), and Carol is an Employee (Department A).

1. Can Carol (Employee) upload new documents to the cloud? (1 mark)

2. Can Bob (Manager) download a document uploaded by another Manager in a different department? (1 mark)

3. Can Alice (Admin) delete a document uploaded by any Employee or Man-ager? (1 mark)

4. Who can access (upload, download, delete) a file named ”Depart-mentA Report.pdf” uploaded by a Manager of Department A? (2 marks)

Scenario 2: A cloud provider uses RBAC to control access to virtual compute instances:

1. CloudAdmin: Can create, modify, delete, and read all instances.

2. DevTeamMember: Can launch, stop, and restart instances, but cannot delete or modify configuration.

3. DataAnalyst: Can only read system logs and output data generated by instances.

Suppose David is a DevTeamMember, Eva is a DataAnalyst, and Frank is a CloudAdmin.

1. Can David (DevTeamMember) launch a new compute instance? (1 mark)

2. Can Eva (DataAnalyst) modify a running instance’s CPU or memory con-figuration? (1 mark)

3. Can Frank (CloudAdmin) read logs generated by an instance running under David’s project? (1 mark)

4. If a DevTeamMember accidentally stops an instance, who can restart it? (2 marks)

Scenario 3: A company uses an Identity and Access Management (IAM) sys-tem with RBAC. Users have roles like ”StandardUser” (basic access) and ”Iden-tityAdmin” (privileged to modify user accounts). Password resets are handled by users with the ”HelpdeskUser” role, who can reset passwords but not assign roles.

Incident: Emma (StandardUser) forgets her password. Noah (HelpdeskUser) resets her password. After reset, Emma somehow gains ”IdentityAdmin” role and deletes another user account.

1. Was Emma supposed to have permission to delete another user? (1 mark)

2. Identify two possible RBAC misconfigurations that might have caused this issue. (1 mark)

3. Could Noah (HelpdeskUser) have intentionally escalated Emma’s privileges during password reset under correct RBAC rules? (1 mark)

4. After a password reset under proper RBAC enforcement, what should Emma have been able to do? (1 mark)

5. Suggest two best practices to prevent such incidents. (1 mark)

Problem 7. (7 marks) TechNova is a cloud-based startup offering collabora-tive software development tools to global teams. The platform. manages access for employees, contractors, and automated systems across engineering, support, and sales departments. Access control is crucial for protecting intellectual prop-erty, customer data, and internal tools.

Each situation below needs the most appropriate access control model: Discre-tionary Access Control (DAC), Mandatory Access Control (MAC), Role-Based Access Control (RBAC), or Attribute-Based Access Control (ABAC). For each scenario, choose the best access control model and give a short 1–2 sentence justification.

1. A project lead manually grants and revokes repository access to contribu-tors based on team membership.

2. Access to confidential design documents is restricted by classification labels such as “Internal,” “Confidential,” or “Top Secret,” regardless of employee preference.

3. Engineers are granted access to build tools and deployment systems based on their role in the DevOps team.

4. Contractors can access internal dashboards only if connecting through an enterprise VPN and during assigned hours.

5. Automated testing bots must have access to specific folders but cannot mod-ify source code or push changes.

6. Customer support staff should be able to view customer tickets but not modify billing records, based on their department and task.

7. A security engineer sets permissions on sensitive audit logs and retains full control over who can read or write them.

Problem 8.(15 marks) A company stores encrypted user data across multiple cloud providers. To access their data, a user must prove that they hold a valid signing key (for authentication) and demonstrate possession of the cor-responding decryption key—all without revealing any sensitive information. A smart contract oversees the process: if the user’s proofs are valid and the cloud provider publishes the encrypted data on-chain, the smart contract releases the encrypted data (or a decryption token) to the user and compensates the provider, ensuring a fair exchange. Key Requirements:

• Privacy: Sensitive data—including key material and authentication de-tails—must remain confidential at every step of the process.

• Soundness: Only users who genuinely possess both the signing and de-cryption keys can successfully access their data.

• Fairness: The provider receives compensation only when (a) the user ver-ifies their credentials correctly and (b) the provider has published the en-crypted data on-chain.

Answer the following questions.

1. Which tools can enable a user to prove possession of both a valid signing key (for authentication) and the corresponding decryption key without re-vealing any sensitive information? Outline the details of these tools. (4 marks)

2. Describe a smart contract based exchange design that meets the require-ments for privacy, soundness, and fairness. Use the the above tools and describe the entire protocol in detail. (6 marks)

3. Discuss how the designed protocol prevents unauthorized data access, pro-tects sensitive key material, and guarantees that neither party can cheat the other. (5 marks)

Problem 9. (5 marks) CloudSecure Inc. provides Encryption-as-a-Service (EaaS) for enterprises. As part of a security audit, they need advice on specific inci-dents involving key management. For each case (1 mark each): Identify the key management practice that applies. Give a short 1–2 sentence justification.

Situations:

1. A private key used to sign certificates was stored in plain in a shared devel-oper folder.

2. Encryption keys used for protecting temporary customer data are never updated, even after months of operation.

3. After several administrative changes, no clear record exists showing which administrator accessed which encryption keys.

4. A highly sensitive encryption key is currently managed by a single admin-istrator, creating a single point of failure risk.

5. An employee who had access to production keys recently left the company, and the keys remain in use without any change.