You are on page 1of 74

PRIVACY PRESERVING DATA SECURITY MODEL FOR

CLOUD COMPUTING TECHNOLOGY

ABSTRACT:

New Advances in Cloud Computing Technology Enable rapid use of cloud platforms for
business purposes it is increasing day by day. Aggregating data about companies
Transactions, communications, business model architecture, etc. A lot of other
information is stored on cloud platforms, Visit our business partners in Dubai together.
Under consideration Security aspects of data stored in the cloud must be high
Protected and accessible by authentication. Was suggested this system focuses on
evaluating the integrity monitoring model of the cloud where security and data protection
systems are located if checked, algorithms are used to determine data protection. The
proposed model is developed using Cryptographic Algorithms where input data is stored
in the cloud Bring Your Own Encryption Key (BYOEK) platform. Or the safety of the
BYOEK model has been evaluated and verified from the following perspectives. For a
given test model in terms of comparison of execution time and data trading.

OBJECTIVE:
In this paper we propose a new and more efficient algorithm that produces solutions
which are very close to the optimal ones. Our contribution is efficient not only for the
bursting of behavior-based compositions but also for architecture-based compositions of
services.
INTRODUCTION

Cloud computing is an advanced technology every person is used inner or outer in


today’s world [2]. The advance and rapidly expanding technology of cloud computing are
used computation and storage. The very minimum cost is used storage and computation
as a service in it. Service model provided three essential services in it: infrastructure as a
service (IaaS), platform as a service (PaaS) and software as a service(SaaS)[3]. The NIST
definition, “Cloud computing is a model permissive ubiquitous, convenient, on-demand
network approach to a shared pool of configurable computing property(e.g. networks,
servers, storage, applications, and services) that can be immediately provisioned and
released with basic management effort or service provider interaction [4][6]. Cloud
storage is a crucial service of cloud computing[5]. They involve data privacy, data
protection, data availability, data location, and, secure transmission which is a crucial
release in cloud security. The involved in cloud challenge security are threats, data loss,
degradation, outside malicious attack and multi-tenancy [6]. The stored information of
integrity is conserved for data integrity in the cloud system. The unauthorized users
should not be accessed misappropriate or vary of data. Data confidentiality is taken to
assure access control policies and authentication. The faith of cloud computing could be
forward by rising cloud authenticate and data confidentiality [7]. A secure data storage of
cloud computing is presented of a data auditing scheme. Auditing is a refinement of
checking the user data which can be done by the data owner or by a TPA[8]. The
integrity of stored data on the cloud serves to maintain it. The TPA manage is split into
two: one is private audibility, which allows the data owner can analyze the integrity of
the data. No one has the authority to inquire about the server considering the data[8].
Though it attains to increases verification overhead of the user. Second is public
audibility, the confidentiality of the data can check by only TPA. The behalf of the client
can act TPA so TPA is an entity. The verification of integrity has handled to appropriate
work that all essential expertise, capabilities, knowledge and professional skill and the
position of the client is also reduced by it[8]

EXISTING SYSTEM:
The author presented a system that maintains the cloud auditing Protocol in which the
medical data accounts are securely transferred with a privacy preserving model. Not
perform the privacy preserving data communication protocol that enables the user to
communicate the data in a secure Gateway with high level of encryption. The presented
system is developed with a privacy preserving transform on a cloud platform with a
secure encryption and decryption process. Homomorphic transform technique is used
with appropriate differential models. To provide a health integrity approach on sending
the patient records in a more secure way. The encryption process needs to be done before
storing the data into the cloud. The presented system discusses the mobile based health
care system. The author presented a system in which the ng techniques for Incorporated
to achieve encrypted data. The proposed system focused on achieving efficient reliability.

DISADVANTAGES OF EXISTING SYSTEM:


 Increased cost
 Low Performance
 Less Secure
PROBLEM DEFINITION

Cloud computing is almost maintenance-free in terms of managing local storage.


However, it becomes a potential security issue when the data owner outsources the data
to the could as the cloud server usually is provided by an untrusted third party. with the
data being shared in a group of users, cloud computing faces a challenge of managing
access control of the encrypted data.

PROPOSED SYSTEM:

The proposed model is developed using Cryptographic Algorithms where input data is
stored in the cloud Bring Your Own Encryption Key (BYOEK) platform. Or the safety of
the BYOEK model has been evaluated and verified from the following perspectives. For
a given test model in terms of comparison of execution time and data trading.

ADVANTAGES OF PROPOSED SYSTEM

 Resistant to collaboration attacks


 Computationally efficient.
 Cost-effective.

SCOPE OF THE PROJECT:


Attribute-based encryption is a type of public-key encryption in which the secret
key of a user and the ciphertext are dependent upon attributes.
LITERATURE SURVEY:

TITLE: An Efficient Auditing Scheme for Data Storage Security in Cloud


AUTHOR: Jayashree Agarkhed, Ashalatha R.
YEAR: 2017
DESCRIPTION:

Cloud computing provides tremendous data storage and computing capabilities to its
users. Large amount of people can store various data onto the cloud without any
hesitation or limitations. Additional security requires a secure cloud storage system with
independent efficient auditing service to check the correctness of outsourced data.
Enormous users keep sending the data over Internet and they are made stored in cloud
data centers remotely. The data files can be accessed by unauthorized users or hackers in
the unsecured cloud network. This leads in leaking of confidential data or data loss
during the transmission over the network. Hence securing the cloud plays a very
important role in cloud environment. The data transfer over wireless network across the
globe has to be protected safely from unauthorized usage over the cloud. The data files
and the remote data centers have to be given extra security as well as maintenance
capabilities from hackers or third party intruders. In this regard, data auditing along with
privacy preserving, integrity and dynamic capabilities plays as a proficient method for
preventing from various cloud attacks which is considered in this work. In this work,
efficient auditor plays a crucial role in securing the cloud environment.
TITLE: Threshold Cryptography Based Data Security in Cloud Computing

AUTHOR: Sushil Kr Saroj, Sanjeev Kr Chauhan, Aravendra Kr Sharma, Sundaram


Vats
YEAR: 2015

DESCRIPTION:

Cloud computing is very popular in organizations and institutions because it provides


storage and computing services at very low cost. However, it also introduces new
challenges for ensuring the confidentiality, integrity and access control of the data. Some
approaches are given to ensure these security requirements but they are lacked in some
ways such as violation of data confidentiality due to collusion attack and heavy
computation (due to large no keys). To address these issues we propose a scheme that
uses threshold cryptography in which data owner divides users in groups and gives single
key to each user group for decryption of data and, each user in the group shares parts of
the key. In this paper, we use capability list to control the access. This scheme not only
provides the strong data confidentiality but also reduces the number of keys.
TITLE: Third Party Public Auditing scheme for Cloud Storage

AUTHOR: Swapnali More , Sangita Chaudhari


YEAR: 2016

DESCRIPTION:

Cloud storage is one of the service provided by Cloud computing in which data is
maintained, managed, backed up remotely and made available to users over a network
(typically the Internet). The user is concerned about the integrity of data stored in the
cloud as the user’s data can be attacked or modified by outside attacker. Therefore, a new
concept called data auditing is introduced which check the integrity of data with the help
of an entity called Third Party Auditor (TPA). The purpose of this work is to develop an
auditing scheme which is secure, efficient to use and possess the capabilities such as
privacy preserving, public auditing, maintaining the data integrity along with
confidentiality. Thus the new auditing scheme has been developed by considering all
these requirements. It consist of three entities: data owner, TPA and cloud server. The
data owner performs various operations such as splitting the file to blocks, encrypting
them, generating a hash value for each, concatenating it and generating a signature on it.
The TPA performs the main role of data integrity check. It performs activities like
generating hash value for encrypted blocks received from cloud server, concatenating
them and generates signature on it. It later compares both the signatures to verify whether
the data stored on cloud is tampered or not. It verifies the integrity of data on demand of
the users. The cloud server is used only to save the encrypted blocks of data. This
proposed auditing scheme make use of AES algorithm for encryption, SHA-2 for
integrity check and RSA signature for digital signature calculation.
TITLE: Third Party Public Auditing on Cloud Storage using the Cryptographic
Algorithm

AUTHOR: B.L Adokshaja , S.J. Saritha


YEAR: 2017

DESCRIPTION:

Cloud computing is a service which provides storage space for the users in which data is
maintained, managed, backed up remotely and made available to users over a network
(typically the Internet).The user is worried about the integrity of the data stored in the
cloud as the user’s data can be stolen or modified by unauthorized person. So the data
auditing mechanism is used to check the integrity of data with the use of Third Party
Auditor (TPA). The use of this work is to develop an auditing scheme which is secure,
efficient to use and possess the capabilities such as privacy preserving, public auditing,
maintaining the data integrity along with confidentiality. Thus the new auditing scheme
has been developed by considering all these requirements. It consists of three entities
namely data owner, TPA and cloud server. TPA verifies the integrity of data on demand
of the users. Thus no additional burden is provided on the cloud server. It is used only to
save the encrypted blocks of data. All the task for the scheme is performed by the TPA
and data owner. The introduced auditing scheme make use of AES algorithm for
encryption, hash value to verify the integrity of the data and code regenerator when the
data is corrupted.
TITLE: Privacy-Preserving Public Auditing for Secure Cloud Storage

AUTHOR: Cong Wang, Sherman S.M. Chow, Qian Wang, Kui Ren, and Wenjing
Lou
YEAR: 2013

DESCRIPTION:

Using cloud storage, users can remotely store their data and enjoy the on-demand high-
quality applications and services from a shared pool of configurable computing resources,
without the burden of local data storage and maintenance. However, the fact that users no
longer have physical possession of the outsourced data makes the data integrity
protection in cloud computing a formidable task, especially for users with constrained
computing resources. Moreover, users should be able to just use the cloud storage as if it
is local, without worrying about the need to verify its integrity. Thus, enabling public
auditability for cloud storage is of critical importance so that users can resort to a third-
party auditor (TPA) to check the integrity of outsourced data and be worry free. To
securely introduce an effective TPA, the auditing process should bring in no new
vulnerabilities toward user data privacy, and introduce no additional online burden to
user. In this paper, we propose a secure cloud storage system supporting privacy-
preserving public auditing. We further extend our result to enable the TPA to perform
audits for multiple users simultaneously and efficiently. Extensive security and
performance analysis show the proposed schemes are provably secure and highly
efficient. Our preliminary experiment conducted on Amazon EC2 instance further
demonstrates the fast performance of the design.
TITLE: An Efficient and Secure Dynamic Auditing Protocol for Data Storage in
Cloud Computing

AUTHOR: Kan Yang, Xiaohua Jia


YEAR: 2013

DESCRIPTION:

In cloud computing, data owners host their data on cloud servers and users (data
consumers) can access the data from cloud servers. Due to the data outsourcing, however,
this new paradigm of data hosting service also introduces new security challenges, which
requires an independent auditing service to check the data integrity in the cloud. Some
existing remote integrity checking methods can only serve for static archive data and thus
cannot be applied to the auditing service since the data in the cloud can be dynamically
updated. Thus, an efficient and secure dynamic auditing protocol is desired to convince
data owners that the data are correctly stored in the cloud. In this paper, we first design an
auditing framework for cloud storage systems and propose an efficient and privacy-
preserving auditing protocol. Then, we extend our auditing protocol to support the data
dynamic operations, which is efficient and provably secure in the random oracle model.
We further extend our auditing protocol to support batch auditing for both multiple
owners and multiple clouds, without using any trusted organizer. The analysis and
simulation results show that our proposed auditing protocols are secure and efficient,
especially it reduce the computation cost of the auditor.
MODULES:
1. Data owner uploading data

2. Data owner encrypting data

3. Auditor generating key for accessing file

4. Data User downloading files using key

5. Data user dynamic operation using key

2.2.2 MODULES DESCRIPTION:

DATA OWNER UPLOADING DATA:

Data owner will uploading file into the cloud using some key for encrypting the
particular text document. The data owner can upload and download the file.
DATA OWNER ENCRYPTING DATA:

Data owner outsourcing the data to the cloud while uploading the data it will be
encrypting the file then it will be placed in the cloud in encrypted format.

AUDITOR GENERATING KEY FOR ACCESSING FILE:

The auditor will maintaining everything in the cloud, then they generate key for
data which is presented in the cloud and then response which user sent a request for
particular file and then track file.
DATA USER DOWNLOADING FILES USING KEY

The data user downloading files before that they need to request the key from the
auditor after that key will be apply in the cloud finally they can download required file.

DATA USER DYNAMIC OPERATION USING KEY

Data user can update, delete and modify data using key and that user modified data’s can
be viewed by admin, data owner and auditor.
MODULE DIAGRAM

ALGORITHMS USED

 AES Algorithm
AES ALGORITHM
The more popular and widely adopted symmetric encryption algorithm likely to be
encountered nowadays is the Advanced Encryption Standard (AES). It is found at least
six time faster than triple DES.

A replacement for DES was needed as its key size was too small. With increasing
computing power, it was considered vulnerable against exhaustive key search attack.
Triple DES was designed to overcome this drawback but it was found slow.

The features of AES are as follows −

 Symmetric key symmetric block cipher

 128-bit data, 128/192/256-bit keys

 Stronger and faster than Triple-DES

 Provide full specification and design details

 Software implementable in C and Java

Operation of AES
AES is an iterative rather than Feistel cipher. It is based on ‘substitution–permutation
network’. It comprises of a series of linked operations, some of which involve replacing
inputs by specific outputs (substitutions) and others involve shuffling bits around
(permutations).

Interestingly, AES performs all its computations on bytes rather than bits. Hence, AES
treats the 128 bits of a plaintext block as 16 bytes. These 16 bytes are arranged in four
columns and four rows for processing as a matrix −

Unlike DES, the number of rounds in AES is variable and depends on the length of the
key. AES uses 10 rounds for 128-bit keys, 12 rounds for 192-bit keys and 14 rounds for
256-bit keys. Each of these rounds uses a different 128-bit round key, which is
calculated from the original AES key

SYSTEM REQUIREMENT
HARDWARE REQUIREMENTS
Processor : Pentium Dual Core 2.00GHZ
Hard disk : 40 GB
Mouse : Logitech.
RAM : 4 GB(minimum)
Keyboard : 110 keys enhanced.
SOFTWARE REQUIREMENTS

Operating system : Windows 7 (Service Pack 1), 8, 8.1 and 10


Front End : HTML, CSS, BOOTSTARP, JAVASCRIPT
Coding Language : java servlets
Backend : MYSQL
Software Tool : ECLIPSE
FEASIBILITY STUDY

The feasibility analysis results in a feasibility report, and includes the service
improvement value chain, an effective supply chain, an IT enabled strategy map, and
optimization of the acquisition process. Other benefits of leveraging cloud computing are
provided, including the cost/ benefit, agility, and high efficiency.

TECHNICAL FEASIBILITY

The key findings of the investigation are twofold, namely that it is indeed feasible
to implement a cloud-based portal for a global service organization, and there are real
prospects of value creation and service improvement. The small/medium sized global
service enterprise, GESA, is expected to obtain some competitive benefits from
leveraging PAAS with cloud computing. The benefits include reducing costs, business
processes improvement, optimization of customer relationship, and new services creation.
It was found that the SCOR model can aid an enterprise to understand its supply chain in
a cloud-based environment. Moreover, modeling processes and activities should be
conducted on three levels, namely processes, sub-processes, and activities with specific
goals and measures in mind. The outcome of modeling processes and activities allows the
enterprise to gain insight into the details of the business processes and behaviors on
different levels.
ECONOMICAL FEASIBILITY

In order to optimize the acquisition process, evaluation criteria of supplier


selection aligning with the agency’s vision and objectives, were developed. The criteria
are given in Table 1: cost, quality, safety, service, convenience, and agility. The criteria
were based on the needs and goals of acquisition, and aligned with new services using the
cloud-based portal. The new services include online application, online user
identification, online consultant, online database service, translation service, news
collection, newsletter system, online discussion forum, service cost calculator, and online
payment access. The alignment of business needs, technological support, strategic
guidelines, and business processes is a necessary condition for operating the cloud-based
portal for GESA.

OPERATIONAL FEASIBILITY

Utilizing IT-based solutions is beneficial for the enterprise from four perspectives.
Business processes may be improved via IT enablement in an internal perspective. The
Operation Management Process is supported by a cloud-based supply chain, and the new
services provided by a portal for GESA would strengthen customer management
processes and innovation processes. The agility of the system is positive for dealing with
the regulatory and social processes as well. Furthermore, considering the GESA customer
value proposition, a healthy customer relationship would provide several benefits to
applicants, such as lower price, more service selections, multiple accesses to information,
and ease of operation. Moreover, with the improvement of business processes and
customer relationship, the agency would be able to maintain a positive financial status. IT
enablement can improve the cost structure, increase asset utilization, expand revenue
opportunities, and enhance customer value in the financial perspective. Improvements
from different perspectives suggest that the agency would be able to gain long-term
shareholder value
SOFTWARE DEVELOPMENT LIFE CYCLE – SDLC:

In our project we use waterfall model as our software development cycle because of its step-by-
step procedure while implementing.

Fig1: Waterfall Model

 Requirement Gathering and analysis − All possible requirements of the system to be


developed are captured in this phase and documented in a requirement specification
document.
 System Design − the requirement specifications from first phase are studied in this phase
and the system design is prepared. This system design helps in specifying hardware and
system requirements and helps in defining the overall system architecture.
 Implementation − with inputs from the system design, the system is first developed in
small programs called units, which are integrated in the next phase. Each unit is
developed and tested for its functionality, which is referred to as Unit Testing.
 Integration and Testing − All the units developed in the implementation phase are
integrated into a system after testing of each unit. Post integration the entire system is
tested for any faults and failures.
 Deployment of system − Once the functional and non-functional testing is done; the
product is deployed in the customer environment or released into the market.
 Maintenance − There are some issues which come up in the client environment. To fix
those issues, patches are released. Also, to enhance the product some better versions are
released. Maintenance is done to deliver these changes in the customer environment.

SYSTEM DESIGN:

USE CASE DIAGRAM:

Use case diagrams are a way to capture the system's functionality and requirements in
UML diagrams. It captures the dynamic behavior of a live system. A use case diagram
consists of a use case and an actor. Here, data owner and user having separate
registration and login then data owners will uploading the text document using the
symmetric key for encrypting the cloud data.
CLASS DIAGRAM:

Class diagrams are the main building block in object-oriented modeling. They are used to
show the different objects in a system, their attributes, their operations and the
relationships among them. The different object's are Data owner, Cloud user, Cloud
admin these are the objects in this uml relationships and their properties are uploading the
documents, generating key for securing the data, maintaining the cloud data s then
downloading using the key and accessing the cloud data.
OBJECT DIAGRAM:

An object diagram shows this relation between the instantiated classes and the
defined class, and the relation between these objects in the system. They are be useful
to explain smaller portions of your system, when your system class diagram is very
complex, and also sometimes modeling recursive relationship in diagram.

The best way to illustrate what an object diagram look like is to show the object
diagram derived from the corresponding class diagram.
STATE DIAGRAM:

A state diagram, also known as a state machine diagram or state chart diagram, is an
illustration of the states an object can attain as well as the transitions between
those states in the Unified Modeling Language. Then, all of the possible
existing states are placed in relation to the beginning and the end.
ACTIVITY DIAGRAM:

Activity Diagrams describe how activities are coordinated to provide a service


which can be at different levels of abstraction. Typically, an event needs to be achieved
by some operations, particularly where the operation is intended to achieve a number of
different things that require coordination.
SEQUENCE DIAGRAM:

A sequence diagram is a type of interaction diagram because it describes how and in what
order a group of objects works together. These diagrams are used by software developers
and business professionals to understand requirements for a new system or to document
an existing process.
COLLABORATION DIAGRAM:

A collaboration diagram, also known as a communication diagram, is an


illustration of the relationships and interactions among software objects in the Unified
Modeling Language (UML). These diagrams can be used to portray the dynamic
behavior of a particular use case and define the role of each object.
COMPONENT DIAGRAM:

The Component diagrams are special type of UML diagrams used for different
purposes. These diagrams show the physical components of a system. To clarify it, we
can say that component diagrams describe the organization of the components in a
system.
DATA FLOW DIAGRAM

Data flow diagrams are used to graphically represent the flow of data in a business
information system. DFD describes the processes that are involved in a system to transfer
data from the input to the file storage and reports generation. Data flow diagrams can be
divided into logical and physical. The logical data flow diagram describes flow of data
through a system to perform certain functionality of a business. The physical data flow
diagram describes the implementation of the logical data flow.

E-R DIAGRAM

E-R Diagram stands for Entity Relationship Diagram, also known as ERD is a
diagram that displays the relationship of entity sets stored in a database. In other words,
ER diagrams help to explain the logical structure of databases. ER diagrams are created
based on three basic concepts: entities, attributes and relationships.ER Diagrams contain
different symbols that use rectangles to represent entities, ovals to define attributes and
diamond shapes to represent relationships

SYSTEM ARCHITECTURE
IMPLEMENTATION

DataOwner.jsp

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"


pageEncoding="ISO-8859-1"%>
<%@page import="com.Dynamic.Database.DatabaseConnection"%>
<%@page import="java.sql.ResultSet"%>
<%@page import="java.util.*" %>
<%@page import="java.sql.*" %>
<%@page import="java.sql.*"%>
<%@page import="java.sql.ResultSet"%>
<%@ page import="java.util.List" %>
<%@ page import="java.sql.*" %>
<%@ page import="pcloud.*" %>
<%@ page import="java.util.*" %>
<%@ page import="java.io.File" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Data Owners</title>
<link href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.0/css/bootstrap.min.css"
rel="stylesheet" id="bootstrap-css">
<script src="//maxcdn.bootstrapcdn.com/bootstrap/3.3.0/js/bootstrap.min.js"></script>
<script src="//code.jquery.com/jquery-1.11.1.min.js"></script>
<!------ Include the above in your HEAD tag ---------->

<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></
script>
<script src="http://getbootstrap.com/dist/js/bootstrap.min.js"></script>

</head>
<body>

<%
try{
File file = new File("E:\\Temp");
String[] myFiles;
if(file.isDirectory()){
myFiles = file.list();
for (int i=0; i<myFiles.length; i++) {
File myFile = new File(file, myFiles[i]);
myFile.delete();
}
}
PCloudAPI conn=new PCloudAPI();
Hashtable <String, Object> params=new Hashtable <String, Object> ();
params.put("username", "cloudproject18032019@gmail.com");
params.put("password", "18032019");
params.put("folderid", "3126483280");
Object res=conn.sendCommand("listfolder", params);
if (PCloudAPI.resultGetLong(res, "result")!=0){
System.out.println("Error: "+PCloudAPI.resultGetString(res, "error"));
return;
}
%>
<div class="container">
<div class="row">

<div class="col-md-12">
<h4>Data Owners </h4> <br>
<div class="table-responsive">

<table id="mytable" class="table table-bordred table-striped">

<thead>
<tr>
<!-- <th><input type="checkbox" id="checkall" /></th> -->
<th>S.no</th>
<th>Name</th>
<th>User name</th>
<th>Password</th>
<th>Email</th>
<th>Address</th>
<!-- <th>Action</th>
<th>Edit</th> -->

</tr>
</thead>
<%
Object[] contents=PCloudAPI.resultGetArray(PCloudAPI.resultGetHashtable(res,
"metadata"), "contents");
for (int i=0; i<contents.length; i++){

Object entry=contents[i];
if (PCloudAPI.resultGetBoolean(entry, "isfolder"))
System.out.println("Folder: "+PCloudAPI.resultGetString(entry, "name")+"
Id :"+PCloudAPI.resultGetString(entry, "id"));
else
System.out.println("File: "+PCloudAPI.resultGetString(entry, "name")+" Size:
"+PCloudAPI.resultGetLong(entry, "size")+" Id: "+PCloudAPI.resultGetString(entry,
"id"));
try
{
Class.forName("com.mysql.jdbc.Driver");
Connection con=(Connection)DriverManager.getConnection(
"jdbc:mysql://localhost:3306/dynamicdataauditing","root","root");
Statement st=con.createStatement();
ResultSet rs=st.executeQuery("select * from doreg");
%>

<tbody>
<%
int ii=1;
if(i<1)
{
while(rs.next())
{
%>

<tr>
<td><%=ii%></td>
<!-- <td><input type="checkbox" class="checkthis" /></td> -->

<td><%=rs.getString("name") %></td>
<td><%=rs.getString("uname") %></td>
<td><%=rs.getString("pass") %></td>
<td><%=rs.getString("email") %></td>
<td><%=rs.getString("addr") %></td>
<!-- <td><a href="Download?Filename=<%=rs.getString("filename")%>&&filekey=<
%=rs.getString("filekey")%>&&check=<%=PCloudAPI.resultGetString(entry, "id")
%>">Download</a></td> -->
<!-- <td><p data-placement="top" data-toggle="tooltip" title="Download"><button
class="btn btn-primary btn-xs" data-title="Edit" data-toggle="modal" data-
target="#edit" ><span class="glyphicon glyphicon-download-
alt"></span></button></p></td>
<td><p data-placement="top" data-toggle="tooltip" title="Insert or
Modify"><button class="btn btn-primary btn-xs" data-title="Edit" data-toggle="modal"
data-target="#edit" ><span class="glyphicon
glyphicon-pencil"></span></button></p></td> -->
<!-- <td><p data-placement="top" data-toggle="tooltip" title="Delete"><button
class="btn btn-danger btn-xs" data-title="Delete" data-toggle="modal" data-
target="#delete" ><span class="glyphicon glyphicon-trash"></span></button></p></td>
-->
</tr>
<%
ii++;
}
}%>

</tbody>

</table>

<%}
catch(Exception e){
out.print(e.getMessage());%><br><%
}
}
}
catch(Exception e){
e.printStackTrace();
}

%>

<!--
<div class="clearfix"></div>
<ul class="pagination pull-right">
<li class="disabled"><a href="#"><span class="glyphicon glyphicon-
chevron-left"></span></a></li>
<li class="active"><a href="#">1</a></li>
<li><a href="#">2</a></li>
<li><a href="#">3</a></li>
<li><a href="#">4</a></li>
<li><a href="#">5</a></li>
<li><a href="#"><span class="glyphicon glyphicon-chevron-right"></span></a></li>
</ul>
-->
</div>

</div>
</div>
</div>

<div class="modal fade" id="edit" tabindex="-1" role="dialog" aria-labelledby="edit"


aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-
hidden="true"><span class="glyphicon glyphicon-remove" aria-
hidden="true"></span></button>
<h4 class="modal-title custom_align" id="Heading">Edit Your Detail</h4>
</div>
<div class="modal-body">
<div class="form-group">
<input class="form-control " type="text" placeholder="Mohsin">
</div>
<div class="form-group">

<input class="form-control " type="text" placeholder="Irshad">


</div>
<div class="form-group">
<textarea rows="2" class="form-control" placeholder="CB 106/107 Street # 11
Wah Cantt Islamabad Pakistan"></textarea>

</div>
</div>
<div class="modal-footer ">
<button type="button" class="btn btn-warning btn-lg" style="width:
100%;"><span class="glyphicon glyphicon-ok-sign"></span> Update</button>
</div>
</div>
<!-- /.modal-content -->
</div>
<!-- /.modal-dialog -->
</div>

<div class="modal fade" id="delete" tabindex="-1" role="dialog" aria-


labelledby="edit" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-
hidden="true"><span class="glyphicon glyphicon-remove" aria-
hidden="true"></span></button>
<h4 class="modal-title custom_align" id="Heading">Delete this entry</h4>
</div>
<div class="modal-body">

<div class="alert alert-danger"><span class="glyphicon glyphicon-warning-


sign"></span> Are you sure you want to delete this Record?</div>

</div>
<div class="modal-footer ">
<button type="button" class="btn btn-success" ><span class="glyphicon
glyphicon-ok-sign"></span> Yes</button>
<button type="button" class="btn btn-default" data-dismiss="modal"><span
class="glyphicon glyphicon-remove"></span> No</button>
</div>
</div>
<!-- /.modal-content -->
</div>
<!-- /.modal-dialog -->
</div>
<script type="text/javascript" src="Table/table.js"></script>
<script>
$(document).ready(function(){
$("#mytable #checkall").click(function () {
if ($("#mytable #checkall").is(':checked')) {
$("#mytable input[type=checkbox]").each(function () {
$(this).prop("checked", true);
});

} else {
$("#mytable input[type=checkbox]").each(function () {
$(this).prop("checked", false);
});
}
});

$("[data-toggle=tooltip]").tooltip();
});
</script>
</body>
</html>

OwnerLogin.jsp

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"


pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Data Owner | Register</title>
<link href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.0/css/bootstrap.min.css"
rel="stylesheet" id="bootstrap-css">
<script src="//maxcdn.bootstrapcdn.com/bootstrap/3.3.0/js/bootstrap.min.js"></script>
<script src="//code.jquery.com/jquery-1.11.1.min.js"></script>
<!------ Include the above in your HEAD tag ---------->

<link rel="stylesheet" href="UserLogin.css">

</head>
<body>
<div class="container">
<div class="row">
<div class="col-md-6 col-md-offset-3">
<div class="panel panel-login">
<div class="panel-heading">
<div class="row">
<div class="col-xs-6">
<a href="#" class="active"
id="login-form-link">Login</a>
</div>
<div class="col-xs-6">
<a href="#" id="register-form-
link">Register</a>
</div>
</div>
<hr>
</div>
<div class="panel-body">
<div class="row">
<div class="col-lg-12">
<form id="login-form"
action="DoLogin" method="post" role="form" style="display: block;">
<div class="form-group">
<input type="text"
name="username" id="username" tabindex="1" class="form-control"
placeholder="Username" value="">
</div>
<div class="form-group">
<input
type="password" name="password" id="password" tabindex="2" class="form-control"
placeholder="Password">
</div>
<!-- <div class="form-group
text-center">
<input
type="checkbox" tabindex="3" class="" name="remember" id="remember">
<label
for="remember"> Remember Me</label>
</div> -->
<div class="form-group">
<div class="row">
<div
class="col-sm-6 col-sm-offset-3">
<input
type="submit" name="login-submit" id="login-submit" tabindex="4" class="form-control
btn btn-login" value="Log In">
</div>
</div>
</div>

</form>
<form id="register-form"
action="DoRegister" method="post" role="form" style="display: none;">
<div class="form-group">
<input type="text"
name="name" id="username" tabindex="1" class="form-control" placeholder="Name"
value="">
</div>
<div class="form-group">
<input type="text"
name="username" id="username" tabindex="1" class="form-control"
placeholder="Username" value="">
</div>
<div class="form-group">
<input
type="password" name="password" id="password" tabindex="2" class="form-control"
placeholder="Password">
</div>
<div class="form-group">
<input
type="password" name="conpassword" id="confirm-password" tabindex="2" class="form-
control" placeholder="Confirm Password">
</div>
<div class="form-group">
<input type="email"
name="email" id="email" tabindex="1" class="form-control" placeholder="Email
Address" value="">
</div>
<div class="form-group">
<input type="text"
name="contact" id="contact" tabindex="1" class="form-control" placeholder="Contact
Nnumber" value="">
</div>
<div class="form-group">
<input type="text"
name="address" id="address" tabindex="1" class="form-control" placeholder="Address"
value="">
</div>
<div class="form-group">
<div class="row">
<div
class="col-sm-6 col-sm-offset-3">
<input
type="submit" name="register-submit" id="register-submit" tabindex="4" class="form-
control btn btn-register" value="Register Now">
</div>
</div>
</div>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<script>
$(function() {

$('#login-form-link').click(function(e) {
$("#login-form").delay(100).fadeIn(100);
$("#register-form").fadeOut(100);
$('#register-form-link').removeClass('active');
$(this).addClass('active');
e.preventDefault();
});
$('#register-form-link').click(function(e) {
$("#register-form").delay(100).fadeIn(100);
$("#login-form").fadeOut(100);
$('#login-form-link').removeClass('active');
$(this).addClass('active');
e.preventDefault();
});

});
</script>
</body>
</html>

DataUser.jsp

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"


pageEncoding="ISO-8859-1"%>
<%@page import="com.Dynamic.Database.DatabaseConnection"%>
<%@page import="java.sql.ResultSet"%>
<%@page import="java.util.*" %>
<%@page import="java.sql.*" %>
<%@page import="java.sql.*"%>
<%@page import="java.sql.ResultSet"%>
<%@ page import="java.util.List" %>
<%@ page import="java.sql.*" %>
<%@ page import="pcloud.*" %>
<%@ page import="java.util.*" %>
<%@ page import="java.io.File" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Data Users</title>
<link href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.0/css/bootstrap.min.css"
rel="stylesheet" id="bootstrap-css">
<script src="//maxcdn.bootstrapcdn.com/bootstrap/3.3.0/js/bootstrap.min.js"></script>
<script src="//code.jquery.com/jquery-1.11.1.min.js"></script>
<!------ Include the above in your HEAD tag ---------->

<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></
script>
<script src="http://getbootstrap.com/dist/js/bootstrap.min.js"></script>

</head>
<body>

<%
try{
File file = new File("E:\\Temp");
String[] myFiles;
if(file.isDirectory()){
myFiles = file.list();
for (int i=0; i<myFiles.length; i++) {
File myFile = new File(file, myFiles[i]);
myFile.delete();
}
}
PCloudAPI conn=new PCloudAPI();
Hashtable <String, Object> params=new Hashtable <String, Object> ();
params.put("username", "cloudproject18032019@gmail.com");
params.put("password", "18032019");
params.put("folderid", "3126483280");
Object res=conn.sendCommand("listfolder", params);
if (PCloudAPI.resultGetLong(res, "result")!=0){
System.out.println("Error: "+PCloudAPI.resultGetString(res, "error"));
return;
}
%>

<div class="container">
<div class="row">

<div class="col-md-12">
<h4>Data Users </h4> <br>
<div class="table-responsive">

<table id="mytable" class="table table-bordred table-striped">

<thead>
<tr>
<!-- <th><input type="checkbox" id="checkall" /></th> -->
<th>S.no</th>
<th>Name</th>
<th>User name</th>
<th>Password</th>
<th>Email</th>
<th>Address</th>
<!-- <th>Action</th>
<th>Edit</th> -->

</tr>
</thead>
<%
Object[] contents=PCloudAPI.resultGetArray(PCloudAPI.resultGetHashtable(res,
"metadata"), "contents");
for (int i=0; i<contents.length; i++){

Object entry=contents[i];
if (PCloudAPI.resultGetBoolean(entry, "isfolder"))
System.out.println("Folder: "+PCloudAPI.resultGetString(entry, "name")+"
Id :"+PCloudAPI.resultGetString(entry, "id"));
else
System.out.println("File: "+PCloudAPI.resultGetString(entry, "name")+" Size:
"+PCloudAPI.resultGetLong(entry, "size")+" Id: "+PCloudAPI.resultGetString(entry,
"id"));
try
{
Class.forName("com.mysql.jdbc.Driver");
Connection con=(Connection)DriverManager.getConnection(
"jdbc:mysql://localhost:3306/dynamicdataauditing","root","root");
Statement st=con.createStatement();
ResultSet rs=st.executeQuery("select * from dureg");
%>

<tbody>
<%
int ii=1;
if(i<1)
{
while(rs.next())
{
%>

<tr>
<td><%=ii%></td>
<!-- <td><input type="checkbox" class="checkthis" /></td> -->

<td><%=rs.getString("name") %></td>
<td><%=rs.getString("uname") %></td>
<td><%=rs.getString("pass") %></td>
<td><%=rs.getString("email") %></td>
<td><%=rs.getString("addr") %></td>
<!-- <td><a href="Download?Filename=<%=rs.getString("filename")%>&&filekey=<
%=rs.getString("filekey")%>&&check=<%=PCloudAPI.resultGetString(entry, "id")
%>">Download</a></td> -->
<!-- <td><p data-placement="top" data-toggle="tooltip" title="Download"><button
class="btn btn-primary btn-xs" data-title="Edit" data-toggle="modal" data-
target="#edit" ><span class="glyphicon glyphicon-download-
alt"></span></button></p></td>
<td><p data-placement="top" data-toggle="tooltip" title="Insert or
Modify"><button class="btn btn-primary btn-xs" data-title="Edit" data-toggle="modal"
data-target="#edit" ><span class="glyphicon
glyphicon-pencil"></span></button></p></td> -->
<!-- <td><p data-placement="top" data-toggle="tooltip" title="Delete"><button
class="btn btn-danger btn-xs" data-title="Delete" data-toggle="modal" data-
target="#delete" ><span class="glyphicon glyphicon-trash"></span></button></p></td>
-->
</tr>
<%
ii++;
}
}%>

</tbody>

</table>

<%}
catch(Exception e){
out.print(e.getMessage());%><br><%
}
}
}
catch(Exception e){
e.printStackTrace();
}

%>

<!--
<div class="clearfix"></div>
<ul class="pagination pull-right">
<li class="disabled"><a href="#"><span class="glyphicon glyphicon-
chevron-left"></span></a></li>
<li class="active"><a href="#">1</a></li>
<li><a href="#">2</a></li>
<li><a href="#">3</a></li>
<li><a href="#">4</a></li>
<li><a href="#">5</a></li>
<li><a href="#"><span class="glyphicon glyphicon-chevron-right"></span></a></li>
</ul>
-->
</div>

</div>
</div>
</div>

<div class="modal fade" id="edit" tabindex="-1" role="dialog" aria-labelledby="edit"


aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-
hidden="true"><span class="glyphicon glyphicon-remove" aria-
hidden="true"></span></button>
<h4 class="modal-title custom_align" id="Heading">Edit Your Detail</h4>
</div>
<div class="modal-body">
<div class="form-group">
<input class="form-control " type="text" placeholder="Mohsin">
</div>
<div class="form-group">

<input class="form-control " type="text" placeholder="Irshad">


</div>
<div class="form-group">
<textarea rows="2" class="form-control" placeholder="CB 106/107 Street # 11
Wah Cantt Islamabad Pakistan"></textarea>

</div>
</div>
<div class="modal-footer ">
<button type="button" class="btn btn-warning btn-lg" style="width:
100%;"><span class="glyphicon glyphicon-ok-sign"></span> Update</button>
</div>
</div>
<!-- /.modal-content -->
</div>
<!-- /.modal-dialog -->
</div>

<div class="modal fade" id="delete" tabindex="-1" role="dialog" aria-


labelledby="edit" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-
hidden="true"><span class="glyphicon glyphicon-remove" aria-
hidden="true"></span></button>
<h4 class="modal-title custom_align" id="Heading">Delete this entry</h4>
</div>
<div class="modal-body">

<div class="alert alert-danger"><span class="glyphicon glyphicon-warning-


sign"></span> Are you sure you want to delete this Record?</div>

</div>
<div class="modal-footer ">
<button type="button" class="btn btn-success" ><span class="glyphicon
glyphicon-ok-sign"></span> Yes</button>
<button type="button" class="btn btn-default" data-dismiss="modal"><span
class="glyphicon glyphicon-remove"></span> No</button>
</div>
</div>
<!-- /.modal-content -->
</div>
<!-- /.modal-dialog -->
</div>
<script type="text/javascript" src="Table/table.js"></script>
<script>
$(document).ready(function(){
$("#mytable #checkall").click(function () {
if ($("#mytable #checkall").is(':checked')) {
$("#mytable input[type=checkbox]").each(function () {
$(this).prop("checked", true);
});

} else {
$("#mytable input[type=checkbox]").each(function () {
$(this).prop("checked", false);
});
}
});

$("[data-toggle=tooltip]").tooltip();
});
</script>
</body>
</html>

UserLogin.jsp

body {
padding-top: 90px;
}
.panel-login {
border-color: #ccc;
-webkit-box-shadow: 0px 2px 3px 0px rgba(0,0,0,0.2);
-moz-box-shadow: 0px 2px 3px 0px rgba(0,0,0,0.2);
box-shadow: 0px 2px 3px 0px rgba(0,0,0,0.2);
}
.panel-login>.panel-heading {
color: #00415d;
background-color: #fff;
border-color: #fff;
text-align:center;
}
.panel-login>.panel-heading a{
text-decoration: none;
color: #666;
font-weight: bold;
font-size: 15px;
-webkit-transition: all 0.1s linear;
-moz-transition: all 0.1s linear;
transition: all 0.1s linear;
}
.panel-login>.panel-heading a.active{
color: #029f5b;
font-size: 18px;
}
.panel-login>.panel-heading hr{
margin-top: 10px;
margin-bottom: 0px;
clear: both;
border: 0;
height: 1px;
background-image: -webkit-linear-gradient(left,rgba(0, 0, 0, 0),rgba(0, 0, 0,
0.15),rgba(0, 0, 0, 0));
background-image: -moz-linear-
gradient(left,rgba(0,0,0,0),rgba(0,0,0,0.15),rgba(0,0,0,0));
background-image: -ms-linear-
gradient(left,rgba(0,0,0,0),rgba(0,0,0,0.15),rgba(0,0,0,0));
background-image: -o-linear-
gradient(left,rgba(0,0,0,0),rgba(0,0,0,0.15),rgba(0,0,0,0));
}
.panel-login input[type="text"],.panel-login input[type="email"],.panel-login
input[type="password"] {
height: 45px;
border: 1px solid #ddd;
font-size: 16px;
-webkit-transition: all 0.1s linear;
-moz-transition: all 0.1s linear;
transition: all 0.1s linear;
}
.panel-login input:hover,
.panel-login input:focus {
outline:none;
-webkit-box-shadow: none;
-moz-box-shadow: none;
box-shadow: none;
border-color: #ccc;
}
.btn-login {
background-color: #59B2E0;
outline: none;
color: #fff;
font-size: 14px;
height: auto;
font-weight: normal;
padding: 14px 0;
text-transform: uppercase;
border-color: #59B2E6;
}
.btn-login:hover,
.btn-login:focus {
color: #fff;
background-color: #53A3CD;
border-color: #53A3CD;
}
.forgot-password {
text-decoration: underline;
color: #888;
}
.forgot-password:hover,
.forgot-password:focus {
text-decoration: underline;
color: #666;
}

.btn-register {
background-color: #1CB94E;
outline: none;
color: #fff;
font-size: 14px;
height: auto;
font-weight: normal;
padding: 14px 0;
text-transform: uppercase;
border-color: #1CB94A;
}
.btn-register:hover,
.btn-register:focus {
color: #fff;
background-color: #1CA347;
border-color: #1CA347;
}

AdminLogin.jsp

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"


pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Admin | Login</title>
<link href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.0/css/bootstrap.min.css"
rel="stylesheet" id="bootstrap-css">
<script src="//maxcdn.bootstrapcdn.com/bootstrap/3.3.0/js/bootstrap.min.js"></script>
<script src="//code.jquery.com/jquery-1.11.1.min.js"></script>
<!------ Include the above in your HEAD tag ---------->

<link rel="stylesheet" href="UserLogin.css">


</head>
<body>
<div class="container">
<div class="row">
<div class="col-md-6 col-md-offset-3">
<div class="panel panel-login">
<div class="panel-heading">
<div class="row">
<div class="col-xs-6">
<a href="#" class="active"
id="login-form-link">Login</a>
</div>
<!-- <div class="col-xs-6">
<a href="#" id="register-form-
link">Register</a>
</div> -->
</div>
<hr>
</div>
<div class="panel-body">
<div class="row">
<div class="col-lg-12">
<form id="login-form"
action="AdminLogin" method="post" role="form" style="display: block;">
<div class="form-group">
<input type="text"
name="username" tabindex="1" class="form-control" placeholder="Username" >
</div>
<div class="form-group">
<input
type="password" name="password" tabindex="2" class="form-control"
placeholder="Password">
</div>

<div class="form-group">
<div class="row">
<div
class="col-sm-6 col-sm-offset-3">
<input
type="submit" name="login-submit" id="login-submit" tabindex="4" class="form-control
btn btn-login" value="Log In">
</div>
</div>
</div>

</form>

</div>
</div>
</div>
</div>
</div>
</div>
</div>
<script>
$(function() {

$('#login-form-link').click(function(e) {
$("#login-form").delay(100).fadeIn(100);
$("#register-form").fadeOut(100);
$('#register-form-link').removeClass('active');
$(this).addClass('active');
e.preventDefault();
});
$('#register-form-link').click(function(e) {
$("#register-form").delay(100).fadeIn(100);
$("#login-form").fadeOut(100);
$('#login-form-link').removeClass('active');
$(this).addClass('active');
e.preventDefault();
});

});
</script>
</body>
</html>

AuditorLogin.jsp

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"


pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Auditor | Login</title>
<link href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.0/css/bootstrap.min.css"
rel="stylesheet" id="bootstrap-css">
<script src="//maxcdn.bootstrapcdn.com/bootstrap/3.3.0/js/bootstrap.min.js"></script>
<script src="//code.jquery.com/jquery-1.11.1.min.js"></script>
<!------ Include the above in your HEAD tag ---------->

<link rel="stylesheet" href="UserLogin.css">


</head>
<body>
<div class="container">
<div class="row">
<div class="col-md-6 col-md-offset-3">
<div class="panel panel-login">
<div class="panel-heading">
<div class="row">
<div class="col-xs-6">
<a href="#" class="active"
id="login-form-link">Login</a>
</div>
<!-- <div class="col-xs-6">
<a href="#" id="register-form-
link">Register</a>
</div> -->
</div>
<hr>
</div>
<div class="panel-body">
<div class="row">
<div class="col-lg-12">
<form id="login-form"
action="AuditorLogin" method="post" role="form" style="display: block;">
<div class="form-group">
<input type="text"
name="username" tabindex="1" class="form-control" placeholder="Username" >
</div>
<div class="form-group">
<input
type="password" name="password" tabindex="2" class="form-control"
placeholder="Password">
</div>

<div class="form-group">
<div class="row">
<div
class="col-sm-6 col-sm-offset-3">
<input
type="submit" name="login-submit" id="login-submit" tabindex="4" class="form-control
btn btn-login" value="Log In">
</div>
</div>
</div>

</form>

</div>
</div>
</div>
</div>
</div>
</div>
</div>
<script>
$(function() {

$('#login-form-link').click(function(e) {
$("#login-form").delay(100).fadeIn(100);
$("#register-form").fadeOut(100);
$('#register-form-link').removeClass('active');
$(this).addClass('active');
e.preventDefault();
});
$('#register-form-link').click(function(e) {
$("#register-form").delay(100).fadeIn(100);
$("#login-form").fadeOut(100);
$('#login-form-link').removeClass('active');
$(this).addClass('active');
e.preventDefault();
});

});
</script>
</body>
</html>

File.jsp

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"


pageEncoding="ISO-8859-1"%>
<%@page import="java.util.Random"%>
<%@ page import="java.util.*" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Data Owner | File Upload</title>

<link rel="stylesheet" href="css/File.css">


</head>
<body>
<%
String dprovider=session.getAttribute("dprovider").toString();
session.setAttribute("dprovider", dprovider);

Random r= new Random();

String key="ABCDEF123456789";
char c=key.charAt(r.nextInt(key.length()));
char c1=key.charAt(r.nextInt(key.length()));
char c2=key.charAt(r.nextInt(key.length()));
char c3=key.charAt(r.nextInt(key.length()));
char c4=key.charAt(r.nextInt(key.length()));
char c5=key.charAt(r.nextInt(key.length()));

String Secretkey=""+c+""+c1+""+c2+""+c3+""+c4+""+c5;
System.out.print(Secretkey);

%>
<div class="frame">
<form action="FileuploadServlet" method="post" enctype="multipart/form-data">
<div class="center">
<div class="title">

<h1> <%=dprovider.toUpperCase() %> Drop the file to upload</h1>

</div>

<div class="dropzone">
<img src="http://100dayscss.com/codepen/upload.svg"
class="upload-icon" />
<input type="file" name="filename" value="Choose" class="upload-
input" multiple multiple >

</div>

Secret key:<input type="text" name="key" value="<%=Secretkey%>" readonly


style="text-align:center"/>

<input type="submit" class="btn" name="uploadbutton" value="Upload


file">

</div>
</form>
</div>
</body>
</html>

DoRegister.java

package com.Dynamic.Servlet;
import java.io.IOException;

import javax.servlet.ServletException;

import javax.servlet.annotation.WebServlet;

import javax.servlet.http.HttpServlet;

import javax.servlet.http.HttpServletRequest;

import javax.servlet.http.HttpServletResponse;

import com.Dynamic.Bean.UserBean;

import com.Dynamic.Implementation.DynamicImplementation;

import com.Dynamic.Interface.DynamicInterface;

@WebServlet("/DoRegister")

public class DoRegister extends HttpServlet {

private static final long serialVersionUID = 1L;

public DoRegister() {

super();

protected void doGet(HttpServletRequest request, HttpServletResponse response)


throws ServletException, IOException {
response.getWriter().append("served
at :").append(request.getContextPath());

protected void doPost(HttpServletRequest request, HttpServletResponse response)


throws ServletException, IOException {

doGet(request, response);

String name = request.getParameter("name");

String uname = request.getParameter("username");

String mail = request.getParameter("email");

String pass = request.getParameter("password");

String rpass = request.getParameter("conpassword");

String con = request.getParameter("contact");

String addr = request.getParameter("address");

System.out.println(name+"--"+uname+"--"+mail+"--"+pass+"=="+rpass+"--"+con+"--"+
addr);

if(pass.equals(rpass)) {

System.out.println("User name and password matched----YES");


UserBean ub = new UserBean();

ub.setName(name);

ub.setUsername(uname);

ub.setEmail(mail);

ub.setPassword(pass);

ub.setContact(con);

ub.setAddress(addr);

DynamicInterface di = new DynamicImplementation();

int k = di.doregister(ub);

System.out.println("The k value is:"+k);

if(k==1) {

response.sendRedirect("OwnerLogin.jsp");

} else {

response.sendRedirect("error.jsp");

}
}

DoLogin.java

package com.Dynamic.Servlet;

import java.io.IOException;

import javax.servlet.ServletException;

import javax.servlet.annotation.WebServlet;

import javax.servlet.http.HttpServlet;

import javax.servlet.http.HttpServletRequest;

import javax.servlet.http.HttpServletResponse;

import javax.servlet.http.HttpSession;

import com.Dynamic.Implementation.DynamicImplementation;

import com.Dynamic.Interface.DynamicInterface;

@WebServlet("/DoLogin")

public class DoLogin extends HttpServlet{

private static final long serialVersionUID = 1L;

public DoLogin() {
super();

protected void doGet(HttpServletRequest request, HttpServletResponse response)


throws ServletException, IOException {

response.getWriter().append("Served
at :").append(request.getContextPath());

protected void doPost(HttpServletRequest request, HttpServletResponse response)


throws ServletException, IOException {

doGet(request, response);

String usname = request.getParameter("username");

String passss = request.getParameter("password");

System.out.println(usname+""+passss);

DynamicInterface di = new DynamicImplementation();

int k = di.dolog(usname,passss);

System.out.println("the value of k is:"+k);


if(k==1) {

HttpSession session = request.getSession();

session.setAttribute("dprovider", usname);

response.sendRedirect("OwnerHome.jsp");

} else {

response.sendRedirect("error.jsp");

DuRegister.java

package com.Dynamic.Servlet;

import java.io.IOException;

import javax.servlet.ServletException;

import javax.servlet.annotation.WebServlet;

import javax.servlet.http.HttpServlet;

import javax.servlet.http.HttpServletRequest;

import javax.servlet.http.HttpServletResponse;

import com.Dynamic.Bean.UserBean;
import com.Dynamic.Implementation.DynamicImplementation;

import com.Dynamic.Interface.DynamicInterface;

@WebServlet("/DuRegister")

public class DuRegister extends HttpServlet{

private static final long serialVersionUID = 1L;

public DuRegister() {

super();

protected void doGet(HttpServletRequest request, HttpServletResponse response)


throws ServletException, IOException {

response.getWriter().append("Served
at:").append(request.getContextPath());

protected void doPost(HttpServletRequest request, HttpServletResponse response)


throws ServletException, IOException {

doGet(request, response);

String name = request.getParameter("name");


String uname = request.getParameter("username");

String pass = request.getParameter("password");

String cpass = request.getParameter("conpassword");

String mail = request.getParameter("email");

String con = request.getParameter("contact");

String addr = request.getParameter("address");

System.out.println(name+"--"+uname+"--"+pass+"--"+cpass+"--"+mail+"--"+con+""+ad
dr);

if(pass.equals(cpass)) {

System.out.println("password and confirm password matched----


YES");

UserBean ub = new UserBean();

ub.setName(name);

ub.setUsername(uname);

ub.setPassword(pass);

ub.setEmail(mail);

ub.setContact(con);

ub.setAddress(addr);
DynamicInterface di = new DynamicImplementation();

int k = di.duregister(ub);

System.out.println("the value of k is:"+k);

if(k==1) {

response.sendRedirect("UserLogin.jsp");

} else {

response.sendRedirect("error.jsp");

DuLogin.java

package com.Dynamic.Servlet;

import java.io.IOException;

import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;

import javax.servlet.http.HttpServlet;

import javax.servlet.http.HttpServletRequest;

import javax.servlet.http.HttpServletResponse;

import javax.servlet.http.HttpSession;

import com.Dynamic.Implementation.DynamicImplementation;

import com.Dynamic.Interface.DynamicInterface;

@WebServlet("/DuLogin")

public class DuLogin extends HttpServlet {

private static final long serialVersionUID = 1L;

public DuLogin() {

super();

protected void doGet(HttpServletRequest request, HttpServletResponse response)


throws ServletException, IOException {

response.getWriter().append("Served
at:").append(request.getContextPath());

}
protected void doPost(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {

doGet(request, response);

String uname = request.getParameter("username");

String pass = request.getParameter("password");

System.out.println(uname+"--"+pass);

DynamicInterface di = new DynamicImplementation();

int k = di.dulog(uname,pass);

System.out.println("The value of k is:"+k);

if(k==1) {

HttpSession session = request.getSession();

session.setAttribute("duser", uname);

response.sendRedirect("UserHome.jsp");

} else {

response.sendRedirect("error.jsp");

}
}

AdminLogin.java

package com.Dynamic.Servlet;

import java.io.IOException;

import javax.servlet.ServletException;

import javax.servlet.annotation.WebServlet;

import javax.servlet.http.HttpServlet;

import javax.servlet.http.HttpServletRequest;

import javax.servlet.http.HttpServletResponse;

@WebServlet("/AdminLogin")

public class AdminLogin extends HttpServlet {

private static final long serialVersionUID = 1L;

public AdminLogin() {

super();

protected void doGet(HttpServletRequest request, HttpServletResponse response)


throws ServletException, IOException {
response.getWriter().append("Served
at:").append(request.getContextPath());

protected void doPost(HttpServletRequest request, HttpServletResponse response)


throws ServletException, IOException {

String uname = request.getParameter("username");

String pass = request.getParameter("password");

System.out.println(uname+"--"+pass);

if(uname.equals("admin") && pass.equals("admin")) {

response.sendRedirect("AdminHome.jsp");

} else {

response.sendRedirect("Error.jsp");

SCREENSHOT
FUTURE ENHANCEMENTS:
In the future, we plan to research on applying the principles of AES algorithm using
secure data sharing for improvising encryption performance

CONCLUSION:

A secure auditing method is to store the data on the cloud in a secure manner. The
prospective take the AES algorithm to assure that TPA cannot knowledge about data
toward the robustness-auditing scheme. We propose a data dynamics operation with
mostly deal insertion, deletion and, modification. In the future, we would like to perform
a batch auditing method of data.

REFERENCES:

[1] The global cloud computing market report 2019.

[2] J Agarkhed, R Ashalatha-”An efficient auditing schheme for data storage security in
cloud”.2017[ICCPCT].

[3]. SK Saroj, G Noida, SK Chauhan, AK Sharma “Threshold cryptography based data


security in cloud computing”.S Vats-2015.

[4] Mell, Peter, and Tim Grance.The NIST definition of cloud computing (2011).

[5]]P.Mell and T.Grance,”The NIST definition of cloud computing”, National Institute of


Standards and Technology, Tech. Rep., 2009.

[6].Swapnali Morea, Sangita Chaudhari,”Third Party Public Auditing Scheme for Cloud
Storage “,International Journal of Prpcedia Computer Science ,Volume 79,pp.69-
76,2016.

[7] Zissis, Dimitrios, and Dimitrios Lekkas. Addressing cloud computing security issues.
Future Generation computer systems 28.3(2012):583-592.

[8] B.L Adokshaja, and S.J.Saritha,”Third Party Public Auditing on Cloud Storage using
the Cryptographic Algorithm”ICECDS-2017.
[9]Cong Wang, Sherman SM Chow, Qian Wang, Kui Ren, and Wenjing Lou.”Privacy
Preserving Public Auditing for Secure Cloud Storage. http://eprint.iacr.org/2009/579.pdf.

[10] Cong Wong, Sherman S M Chow, Qian Wang, Kui Ren, and Wen jing Lou.
“Privacy Preserving Public Auditing for Secure Cloud Storage”. IEEE Transactions on
Computers, Volume 62, ISSUE 2, February 2013.

[11]Abhishek Mohta, Ravi Kant Sahu, Lalit Kumar. “Robust Data Security for Cloud
while using Third Party Auditor”. International journal of advanced research in CSE
(IJARCSE), Volume 2, Issue 2, February 2012.

[12]IK Meenakshi and Sudha George. Cloud Server Storage Security using
TPA.International Journal of Advanced Research in Computer Science and Technology
(IJARCST) ISSN: 2347-9817, 2014.

[13] Qian Wang, Cong Wang, Kui Ren, and Wenjing Lou, and Jin Li. Enabling Public
Auditability and Data Dynamics for Security in Cloud Computing. Parallel and
Distributed Systems, IEEE Transactions on, 22(5):847-859, 2011.

You might also like