Chapter 9 - Database Security
Chapter 9 - Database Security
4/1/2018 2
1
4/2/2018
4
4/1/2018
2
4/2/2018
3
4/2/2018
4
4/2/2018
10
11
5
4/2/2018
12
Threats to databases
o Loss of integrity
o Loss of availability
o Loss of confidentiality
13
6
4/2/2018
14
External hackers
7
4/2/2018
8
4/2/2018
9
4/2/2018
Element integrity
o integrity of specific database elements is their correctness or
accuracy
• field checks
– allow only acceptable values
• access controls
– allow only authorized users to update elements
• change log
– used to undo changes made in error
• referential Integrity (key integrity concerns)
• two phase locking process
Auditability
o log read/write to database
User Authentication
o may be separate from OS
o can be rigorous (hard)
Availability
o concurrent users
• granularity of locking
o reliability
10
4/2/2018
MAC
11
4/2/2018
12
4/2/2018
13
4/2/2018
14
4/2/2018
RBAC:
o is a natural fit for database access control
o use of roles in database security
o provides a means of easing the administrative burden and improving
security.
A database RBAC facility needs to provide the capabilities:
• Create and delete roles.
• Define permissions for a role.
• Assign and cancel assignment of users to roles.
SQL supports 3 types of roles: server, database, user-defined.
o The first two types of roles are referred to as fixed roles, are
preconfigured for a system with specific access rights.
o The administrator or user cannot add, delete, or modify fixed roles; it is
only possible to add and remove users as members of a fixed role.
4/1/2018 30
15
4/2/2018
4/1/2018 32
● SQL Injection
● Inference attacks
16
4/2/2018
17
4/2/2018
18
4/2/2018
4/1/2018 39
19
4/2/2018
Detection
•Manual defensive •Check queries at
coding practices runtime to see if
•Parameterized •Signature based they conform to a
query insertion •Anomaly based model of expected
•SQL DOM •Code analysis queries
Defensive Run-time
coding prevention
4/1/2018 40
20
4/2/2018
● Inference attacks:
● relates to database security
● is the process of performing authorized queries
and deducing unauthorized information from the
legitimate responses received.
● Problem:
● the combination of a number of data items is more
sensitive than the individual items,
● the combination of data items can be used to infer
data of a higher sensitivity
21
4/2/2018
Types of attack
o direct attack: aggregate computed over a small
sample so individual data items leaked
o indirect attack: combines several aggregates;
o tracker attack: type of indirect attack (very effective)
o linear system vulnerability: takes tracker attacks
further, using algebraic relations between query sets
to construct equations yielding desired information
22
4/2/2018
Direct Attack
o determine values of sensitive fields by seeking them directly with
queries that yield few records
o request LIST which is a union of 3 sets
LIST NAME where (SEX =M DRUGS = 1)
(SEX M SEX F) (DORM = Ayres)
• No dorm named Ayres , Sex either M or F
o “n items over k percent” rule helps prevent attack
23
4/2/2018
M 1 3 1 5
F 2 1 3 6
Total 3 4 4 11
2 inference techniques:
- analyzing functional
dependencies between
attributes within a table
or across tables,
24
4/2/2018
25
4/2/2018
Yes No
26
4/2/2018
4/1/2018 54
frontend that transforms user queries an organization that receives the encrypted
into queries on the encrypted data data from a data owner and makes them
stored on the server available for distribution to clients
27
4/2/2018
4/1/2018 57
28