Lecture 2.2.3 Database Security
Lecture 2.2.3 Database Security
Database
Management
System
UNIT-I [10h]
Overview of Databases: Database concepts, DBMS, Data Base System Architecture (Three
Level ANSI-SPARC Architecture), Advantages and Disadvantages of DBMS, Data Independence,
DBA and Responsibilities of DBA, Relational Data Structure, Keys, Relations, Attributes, Schema and
Instances, Referential integrity, Entity integrity.
Data Models: Relational Model, Network Model, Hierarchical Model, ER Model: Design,
issues, Mapping constraints, ER diagram, Comparison of Models.
UNIT-II [10h]
Functional dependencies and Normalization: Functional dependencies, Decomposition, Full
Functional Dependency (FFD), Transitive Dependency (TD), Join Dependency (JD), Multi-valued
Dependency (MVD), Normal Forms (1NF, 2NF, 3NF, BCNF), De-normalization.
Database Security: Introduction, Threats, Counter Measures.
Control Structures: Introduction to conditional control, Iterative control and sequential control
statements, Cursors, Views.
3
University Institute of Engineering (UIE)
Department
Department of Computer
of Computer Scienceand
Science andEngineering
Engineering (CSE)
(CSE)
UNIT-III [10h]
Package, Procedures and Triggers: Parts of procedures, Parameter modes, Advantages of
procedures, Syntax for creating triggers, Types of triggers, package specification and package body,
developing a package, Bodiless package, Advantages of packages.
Transaction Management and Concurrency Control: Introduction to Transaction Processing,
Properties of Transactions, Serializability and Recoverability, Need for Concurrency Control, Locking
Techniques, Time Stamping Methods, Optimistic Techniques and Granularity of Data items.
Database Recovery of database: Introduction, Need for Recovery, Types of errors, Recovery
Techniques.
4
University Institute of Engineering (UIE)
Department of Computer Science and Engineering (CSE)
Chapter 2.2
(Database Security)
Database Security: Introduction, Threats, Counter Measures.
Learning objective
• Database Security
• Threats
• Counter Measures.
Learning Outcomes
• Understanding the concept of database security and its
issues.
• Discuss threats
• Discuss various level of security
• Understanding various Counter measures
Threats
Threat is any intentional or accidental event that may adversely affect the
system.
Examples of threats:
- Using another person’s log-in name to access data
- Unauthorized copying data
- Program/Data alteration
- Illegal entry by hacker
- Viruses
- Etc.
QUESTION
1. privacy invasion
2. hardware protection
3. fraudulent manipulation od data
4. all of the above
• Authentication
Authentication
Authentication is regarding credentials.
For example,
Username and Password for identity verification.
Here, the system checks whether you are what you say you are
through your credentials. Whether you’re using public or
private networks, the system authenticates users’ identity
through login details, namely, username and password.
However, there are other methods for Authentication, but this is
the most basic one, which is used almost by everyone.
Authorization
Authorization comes into picture once your identity
successfully gets authenticated by the system. Due to which
you get access to resources like files, funds, databases, sensitive
information, and so on.
Though Authorization is needed to verify your rights for
granting you access to resources once your access rights are
determined, in other words, Authorization is the process that is
used for determining whether the user who’s authenticated
has access right for the particular resources.
For example, once the employee User ID and password get
authenticated, the next thing will be to decide which employee
will get access to which floor, and it’s done using Authorization.
Authentication Authorization
It helps decide whether users are what they claim they It helps to decide which user is allowed to access what.
are.
User identity has to be verified via a username and It verifies whether the given access is allowed by
password or answering a security question. following rules and policies.
Typically this process takes place before Authorization. It takes place once Authentication is completed.
Captcha test Permissions – Read & Write access to files and allowing
Biometric Authentication access to the database.
Passwords Deciding the roles of users for accessing data
It’s controlled through the server for finding out who’s The server helps to decide that client has the authority
accessing what data or site. to access a resource or not.
Example: Employees authenticating through the network Example: Once an employee is authenticated, the
before opening the company mails. different system decides which information will be
accessed by which employee.
QUESTION
Authentication refers to :
Threats in Database
1. Availability Loss: Authorized users should be able to
access data whenever they need to do so
2. Integrity Loss: Only the authorized person can do
changes and update. Data should be maintained in a
correct state and nobody should be able to improperly
modify it, either accidentally or maliciously
3. Confidentiality Loss: This occur due to unauthorized or
unintentional disclosure of information.
Only authorized users and processes should be able to
access or modify data
EXAMPLE
QUESTION
1. Integrity
2. Productivity
3. Security
4. Reliability
QUESTION
RAID
Redundant Array of Independent Disks
The hardware that the DBMS is running on must be fault-tolerant, meaning
that the DBMS should continue to operate even if one of the hardware
components fails.
28
University
DatabaseInstitute of Engineering
and Application (UIE)
Security, Nov
Department of Computer Science and Engineering (CSE)
Physical/OS Security
• Physical level
– Traditional lock-and-key security
– Protection from floods, fire, etc.
• E.g. WTC (9/11), fires in IITM, WWW conf website, etc.
– Protection from administrator error
• E.g. delete critical files
– Solution
• Remote backup for disaster recovery
• Plus archival backup (e.g. DVDs/tapes)
• Operating system level
– Protection from virus/worm attacks critical
Database Encryption
• E.g. What if a laptop/disk/USB key with critical data is lost?
• Partial solution: encrypt the database at storage level, transparent to
application
– Main issue: key management
• E.g. user provides decryption key (password) when database is
started up
– Supported by many database systems
• Standard practice now to encrypt credit card information, and other
sensitive information
•
Network Security
Network level: must use encryption to prevent
– Eavesdropping: unauthorized reading of messages
– Masquerading:
• pretending to be an authorized user or legitimate site, or
• sending messages supposedly from authorized users
– Handled by secure http - https://
– + a PIN or password
Authorization
Forms of authorization on (parts of) the database:
• Read authorization - allows reading, but not modification of data.
• Insert authorization - allows insertion of new data, but not
modification of existing data.
• Update authorization - allows modification, but not deletion of data.
• Delete authorization - allows deletion of data
Privileges in SQL
• select: allows read access to relation,or the ability to query using the
view
– Example: grant users U1, U2, and U3 select authorization on the
branch relation:
grant select on branch to U1, U2, U3
• insert: the ability to insert tuples
• update: the ability to update using the SQL update statement
• delete: the ability to delete tuples.
• references: ability to declare foreign keys when creating relations.
• usage: In SQL-92; authorizes a user to use a specified domain
• all privileges: used as a short form for all the allowable privileges
• The commonly used model for multilevel security, known as the Bell-
LaPadula model, classifies each subject (user, account, program) and
object (relation, tuple, column, view, operation) into one of the security
classifications, T, S, C, or U:
– Clearance (classification) of a subject S as class(S) and to the
classification of an object O as class(O).
HOME WORK
Answers:1.d, 2.b
FAQ
• What do you understand by database security?
• What are threats in DBMS?
• What is RAID?
• What is revoke authentication in SQL?
• Explain privilege in SQL.
References
Other References
• Database Security (w3schools.in)
• Database Security (DS) Pdf Notes - Free Download 2020 | SW (sma
rtzworld.com)
• https://docs.oracle.com/
• Database Security (oracle.com)
• https://www.datasunrise.com/blog/potential-db-threats/database-
security-threats-and-countermeasures/
Database
Management
System
UNIT-I [10h]
Overview of Databases: Database concepts, DBMS, Data Base System Architecture (Three
Level ANSI-SPARC Architecture), Advantages and Disadvantages of DBMS, Data Independence,
DBA and Responsibilities of DBA, Relational Data Structure, Keys, Relations, Attributes, Schema and
Instances, Referential integrity, Entity integrity.
Data Models: Relational Model, Network Model, Hierarchical Model, ER Model: Design,
issues, Mapping constraints, ER diagram, Comparison of Models.
UNIT-II [10h]
Functional dependencies and Normalization: Functional dependencies, Decomposition, Full
Functional Dependency (FFD), Transitive Dependency (TD), Join Dependency (JD), Multi-valued
Dependency (MVD), Normal Forms (1NF, 2NF, 3NF, BCNF), De-normalization.
Database Security: Introduction, Threats, Counter Measures.
Control Structures: Introduction to conditional control, Iterative control and sequential control
statements, Cursors, Views.
48
University Institute of Engineering (UIE)
Department
Department of Computer
of Computer Scienceand
Science andEngineering
Engineering (CSE)
(CSE)
UNIT-III [10h]
Package, Procedures and Triggers: Parts of procedures, Parameter modes, Advantages of
procedures, Syntax for creating triggers, Types of triggers, package specification and package body,
developing a package, Bodiless package, Advantages of packages.
Transaction Management and Concurrency Control: Introduction to Transaction Processing,
Properties of Transactions, Serializability and Recoverability, Need for Concurrency Control, Locking
Techniques, Time Stamping Methods, Optimistic Techniques and Granularity of Data items.
Database Recovery of database: Introduction, Need for Recovery, Types of errors, Recovery
Techniques.
49
University Institute of Engineering (UIE)
Department of Computer Science and Engineering (CSE)
Chapter 2.2
(Database Security)
Database Security: Introduction, Threats, Counter Measures.
Learning objective
• Database Security
• Threats
• Counter Measures.
Learning Outcomes
• Understanding the concept of database security and its
issues.
• Discuss threats
• Discuss various level of security
• Understanding various Counter measures
Database Security
• Database Security - protection from malicious attempts to steal (view)
or modify data.
University
DatabaseInstitute of Engineering
and Application (UIE)
Security, Nov
Department of Computer Science and Engineering (CSE)
Threats
Threat is any intentional or accidental event that may adversely affect the
system.
Examples of threats:
- Using another person’s log-in name to access data
- Unauthorized copying data
- Program/Data alteration
- Illegal entry by hacker
- Viruses
- Etc.
RAID
Redundant Array of Independent Disks
The hardware that the DBMS is running on must be fault-tolerant, meaning
that the DBMS should continue to operate even if one of the hardware
components fails.
63
University
DatabaseInstitute of Engineering
and Application (UIE)
Security, Nov
Department of Computer Science and Engineering (CSE)
Physical/OS Security
• Physical level
– Traditional lock-and-key security
– Protection from floods, fire, etc.
• E.g. WTC (9/11), fires in IITM, WWW conf website, etc.
– Protection from administrator error
• E.g. delete critical files
– Solution
• Remote backup for disaster recovery
• Plus archival backup (e.g. DVDs/tapes)
• Operating system level
– Protection from virus/worm attacks critical
Database Encryption
• E.g. What if a laptop/disk/USB key with critical data is lost?
• Partial solution: encrypt the database at storage level, transparent to
application
– Main issue: key management
• E.g. user provides decryption key (password) when database is
started up
– Supported by many database systems
• Standard practice now to encrypt credit card information, and other
sensitive information
•
Network Security
Network level: must use encryption to prevent
– Eavesdropping: unauthorized reading of messages
– Masquerading:
• pretending to be an authorized user or legitimate site, or
• sending messages supposedly from authorized users
– Handled by secure http - https://
– + a PIN or password
Authorization
Forms of authorization on (parts of) the database:
• Read authorization - allows reading, but not modification of data.
• Insert authorization - allows insertion of new data, but not
modification of existing data.
• Update authorization - allows modification, but not deletion of data.
• Delete authorization - allows deletion of data
Privileges in SQL
• select: allows read access to relation,or the ability to query using the
view
– Example: grant users U1, U2, and U3 select authorization on the
branch relation:
grant select on branch to U1, U2, U3
• insert: the ability to insert tuples
• update: the ability to update using the SQL update statement
• delete: the ability to delete tuples.
• references: ability to declare foreign keys when creating relations.
• usage: In SQL-92; authorizes a user to use a specified domain
• all privileges: used as a short form for all the allowable privileges
• The commonly used model for multilevel security, known as the Bell-
LaPadula model, classifies each subject (user, account, program) and
object (relation, tuple, column, view, operation) into one of the security
classifications, T, S, C, or U:
– Clearance (classification) of a subject S as class(S) and to the
classification of an object O as class(O).
HOME WORK
Answers:1.d, 2.b
FAQ
• What do you understand by database security?
• What are threats in DBMS?
• What is RAID?
• What is revoke authentication in SQL?
• Explain privilege in SQL.
References
Other References
• Database Security (w3schools.in)
• Database Security (DS) Pdf Notes - Free Download 2020 | S
W (smartzworld.com)
• https://docs.oracle.com/
• Database Security (oracle.com)