Docsity

Addressing Security Challenges in Cloud Computing, Summaries of Bankruptcy Law

Toggle sidebar
bg1
Page 1
ASSIGNMENT 2 BRIEF
Qualification
BTEC Level 5 HND Diploma in Computing
Unit number
Unit 16: Cloud Computing
Assignment title
Cloud’s implementation and security threats
Academic Year
2021 – 2022
Unit Tutor
Ho Hai Van
Issue date
Submission date
IV name and date
Submission Format:
Format:
A report (in PDF format)
You must use font Calibri size 12, set number of the pages and use multiple line spacing at
1.3. Margins must be: left: 1.25 cm; right: 1 cm; top: 1 cm and bottom: 1 cm. The reference
follows Harvard referencing system.
Submission Students are compulsory to submit the assignment in due date and in a way requested by
the Tutors. The form of submission will be a soft copy posted on
http://cms.greenwich.edu.vn/
Note: The Assignment must be your own work, and not copied by or from another student or from
books etc. If you use ideas, quotes or data (such as diagrams) from books, journals or other sources, you
must reference your sources, using the Harvard style. Make sure that you know how to reference
properly, and that understand the guidelines on plagiarism. If you do not, you definitely get failed
Unit Learning Outcomes:
LO3 Develop Cloud Computing solutions using service provider’s frameworks and open source tools.
LO4 Analyze the technical challenges for cloud applications and assess their risks
Assignment Brief and Guidance:
Task 1
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e
pf1f
pf20
pf21
pf22
pf23
pf24
pf25
pf26
pf27
pf28
pf29
pf2a
pf2b
pf2c
pf2d
pf2e
pf2f
pf30
pf31
pf32
pf33
pf34
pf35
pf36
pf37
pf38
pf39
pf3a
pf3b

Partial preview of the text

Download Addressing Security Challenges in Cloud Computing and more Summaries Bankruptcy Law in PDF only on Docsity!

ASSIGNMENT 2 BRIEF

Qualification BTEC Level 5 HND Diploma in Computing

Unit number Unit 16 : Cloud Computing

Assignment title Cloud’s implementation and security threats

Academic Year 2021 – 2022

Unit Tutor Ho Hai Van

Issue date Submission date

IV name and date

Submission Format:

Format:

A report (in PDF format)

You must use font Calibri size 12, set number of the pages and use multiple line spacing at

1.3. Margins must be: left: 1.25 cm; right: 1 cm; top: 1 cm and bottom: 1 cm. The reference

follows Harvard referencing system.

Submission Students are compulsory to submit the assignment in due date and in a way requested by

the Tutors. The form of submission will be a soft copy posted on

http://cms.greenwich.edu.vn/

Note: The Assignment must be your own work, and not copied by or from another student or from

books etc. If you use ideas, quotes or data (such as diagrams) from books, journals or other sources, you

must reference your sources, using the Harvard style. Make sure that you know how to reference

properly, and that understand the guidelines on plagiarism. If you do not, you definitely get failed

Unit Learning Outcomes:

LO3 Develop Cloud Computing solutions using service provider’s frameworks and open source tools.

LO4 Analyze the technical challenges for cloud applications and assess their risks

Assignment Brief and Guidance:

Task 1

Base on the scenario and architecture design in the first assignment provide the

implementation. Because of the time constraint of the assignment, the implementation just

provides some demo functions of the scenario. The implementation includes two parts:

  • A step-by-step instruction

o which shows which functions are implemented

o How to config, deploy and test the services (Web application, Database Server,

Source code management, server logs...) using service provider’s frameworks

and open-source tools.

o Images for the built functions

  • A brief discussion about difficulties which one can face during the development process(optional)
  • The source code for the built application

Task 2

The table of contents in your security manual (which should be 500–700 words) should be

as follows:

1. Analysis of the most common problems and security issues of a cloud computing

platform.

2. Discussion on how to overcome these issues.

3. Summary.

Nô ̣i dung

  • P5 Configure a Cloud Computing platform with a cloud service provider’s framework.
      1. Git/Github
      1. Heroku/Render
      1. MongoDB Compass/Atlas
      1. Node.js
      • 4.1. Module Express
      • 4.2. Module MongoDB
  • P6 Implement a cloud platform using open-source tools.
      1. Source code (Node JS)
      • Backend source code:
      • Front-end code:
      1. Test Source Code on Localhost
      1. Deploy Source Code to GitHub and then Migrate to Render
      • 3 .1. Deploy Source Code to GitHub
      • 3.2. Migrate to Render
      1. Test on Render
      • 4 .1. Website Screenshot.
      • 2.2 Steps to perform and test
  • to these problems............................................................................................................................................................ P7 Analyse the most common problems which arise in a Cloud Computing platform and discuss appropriate solutions
      1. Common Cloud and Security Issues.....................................................................................................................
      • 1.1. Public Cloud Issues.......................................................................................................................................
      • 1.2. Private Cloud Issues
      • 1.3. Community Cloud Issues
      • 1.4. Hybrid Cloud Issues
      1. Solution for Every Cloud Model
      • 2.1. Public Cloud Solution
      • 2.2. Private Cloud Solution
      • 2.3. Community Cloud Solution
      • 2.4. Hybrid Cloud Solution
  • P8 Assess the most common security issues in cloud environments..............................................................................
      1. Security Threats and Vulnerabilities
      • 1.1. Basic Security Risk Considerations...............................................................................................................
      • 1.2. Data Security Considerations.......................................................................................................................
      1. Methods to Ensure Security in the Cloud
      • 2.1. Countermeasures for Security Risk
      • 2.2. Methods to ensure Data security
  • References

Afterwards, our next step involves adding a file to the staging environment and subsequently committing

it. To begin, we create a git repository at the root of the folder. The command "git add ." is then utilized to

add the file to the staging environment. Finally, we commit the file. The message displayed in blue can be

customized to serve as a version notification, allowing others to discern whether it represents a new

version or not.

Afterward, access github.com and proceed to establish a fresh repository, ensuring that its name matches

that of your project folder. Disregard any error message as I had already taken care of creating the

repository.

GitHub will inquire whether you prefer to initiate a new repository from the beginning or include a local

repository. Given the circumstances, as we have already established a new repository locally, our intention

is to upload it to GitHub. Therefore, please proceed with the instructions labeled '...or push an existing

repository from the command line.'

Finally, visit GitHub and ensure that the repository has been successfully uploaded.

  1. Heroku/Render

Because of the policy changes implemented by Heroku, they have discontinued offering free servers for

testing or learning purposes. As a result, we will need to utilize Render instead. To begin, you should log in

to Render using your GitHub account, as this will enable you to create a new server more quickly.

After patiently waiting for the web service to become active, you can proceed by clicking on the link

provided next to your web service's name in order to test your webpage.

Trying out the online service once it becomes operational.

  1. MongoDB Compass/Atlas

To begin, you should acquire the MongoDB Compass by downloading it.

While you're in the process of downloading MongoDB Compass, you can proceed to log in or create an

account on MongoDB Atlas.

Next, use express in server.js by requiring it.

Our objective is to establish a server that can be accessed by web browsers through the utilization of

Express's listen method.

After accessing localhost:3000.

4.2. Module MongoDB

To begin, npm should be used for the installation of MongoDB.

Once the installation is complete, establish a connection to MongoDB using the MongoClient's connect

method. Figure 26 illustrates that this line of code is used to make a request to MongoDB.

First, create a connection string within the MongoClient.connect function. After that, implement a

console.log statement to indicate that the database connection has been established.

should look like this when running the code.

P6 Implement a cloud platform using open-source tools.

Overview:

Rather than using the conventional Express.js and MongoDB with Handlebars as the frontend, our team

has developed the website using an advanced web stack. This stack includes Next.js, which is a framework

built on top of React, as the frontend framework to create a seamless and interactive user experience. By

leveraging SWR, we ensure efficient fetching of product data, providing real-time updates on availability

and pricing. Behind the scenes, our robust Express.js backend API handles all the business logic, securely

managing product information, adding mechanisms, as well as delete and edit functionalities. MongoDB

serves as our database, storing and organizing a vast collection of documents, making it easy for customers

to browse, search, and purchase items. Additionally, the incorporation of TypeScript adds a layer of static

typing, enhancing code reliability, facilitating better collaboration, and reducing potential errors.

Front-end:

Our website is constructed using a powerful web stack that combines Next.js as the frontend framework,

SWR for efficient data fetching, and TypeScript for enhanced type safety. Next.js, a popular React

framework, allows us to create dynamic and interactive user interfaces while optimizing performance

through server-side rendering and static site generation capabilities. This ensures fast loading times and

seamless navigation, resulting in a delightful user experience. For data fetching, we utilize SWR, a

lightweight library that simplifies the process by intelligently caching and updating data from our backend

servers. SWR optimizes network requests and provides real-time updates, ensuring that our product

information is always up-to-date and responsive. TypeScript, a statically typed superset of JavaScript,

improves the development process by enforcing strict type checking and preventing common programming

errors. It enables us to build a more robust and reliable codebase, reducing bugs and improving

maintainability. With this web stack, our website offers an intuitive and enjoyable shopping experience,

leveraging cutting-edge technologies to deliver high performance, real-time updates, and enhanced code

quality.

Backend:

The controller folder contains the product controller, which plays a vital role in processing all incoming

requests to the server. It handles queries to the database and manages the redirection of these requests.

The dist folder stores the compiled JavaScript files generated from TypeScript. It encompasses all the

relevant files and components.

The logs folder serves as a useful tool during development, displaying all requests made to the server and

any errors encountered. The middleware folder handles any errors that occur during request processing.

The model folder contains the necessary components for working with the Mongoose Object-Relational

Mapping (ORM) for the database.

The routes folder determines the appropriate controller to handle each specific request. Lastly, the view

folder simply contains a basic HTML file that serves as a confirmation message, indicating that the server is

up and running.

Figure 28: All the necessary library implemented in the server

I utilized TypeScript as the primary programming language for this project. The rationale behind this choice

is that TypeScript provides stronger typing compared to JavaScript, making it safer to use. Additionally,

TypeScript supports features like enums, interfaces, and more. However, web browsers cannot directly run

TypeScript code; they require JavaScript. To address this, I included a command called "compiler:ts" in the

package.json script, which compiles the TypeScript code into JavaScript. Although there is a "tsconfig.ts"

file involved, explaining it in detail would require a lengthy discussion.

In order to facilitate localization of the server after compilation, I incorporated Nodemon. Nodemon offers

a hot-reload module, enabling the browser to instantly reload any changes made to the code. For the

backend server, I opted for Express, a widely used framework. I also integrated additional libraries such as

cookie-parser and cors to enhance the security of HTTP requests. Furthermore, dotenv was employed to

manage environment variables and conceal any critical credentials used by the website.

To simplify database querying, I utilized the Mongoose library, which acts as an Object-Related-Mapping

(ORM) tool specifically designed for MongoDB. In terms of devDependency, most of the listed packages are

type definitions for the respective libraries.

Figure 29: .evn file structure

Figure 30: .env

Figure 31: .env.example

The .env file is a crucial repository for storing vital credentials in a project, including the NODE_ENV which

specifies the current stage of the project (e.g., on-cloud or under development). Additionally, it contains

the DATABASE_URL, which serves as the connection string for the MongoDB database. On the other hand,

the .env.example file is provided to assist individuals who have cloned the project from GitHub, enabling

them to conveniently manage and organize the credentials.

Figure 33: server code

To begin, commence the Express application and specify the preferred port. Subsequently, establish a

connection with the database. The reqLog will be monitored to capture incoming requests. Afterwards, the

file upload limit for images is configured to be 50mb. Following that, we employ cors, cookieParser, and

their respective routes.

Figure 34: config folder for the server

The config folder contains the cors for server and dbConnection.

Figure 35: allowedOrigin.ts

The file named "allowedOrigin" will contain a comprehensive list of all the origins that are allowed to

connect to the server. Any origins that are not listed in this file will be rejected from establishing a

connection due to the Cross-Origin Resource Sharing (CORS) exception.

Figure 36: corsOption.ts

The decision regarding whether the client request origin is permitted or not will be made by corsOption. If

the origin is deemed acceptable, the client will proceed to request the server's resource. Conversely, if the

origin is not allowed, the server will decline to provide the requested resource.