Unit V
Unit V
2
What Is Database Security?
Database:
It is a collection of information stored in a computer.
Security:
It is being free from danger.
Database Security:
It is the mechanisms that protect the database against
intentional or accidental thr eats.
3
Three Main Aspects
1. Secrecy
2. Integrity
3. Availability
4
Secrecy
It is protecting the database from unauthorized
users.
Ensures that users are allowed to do the things
they are trying to do.
For examples,
The employees sh ould not see the salaries of their
managers.
5
Integrity
Protecting the database from authorized
users.
For examples,
• An employee should be able to modif y
his or her own information. 6
Availability
Authorized users should be able to access
data for Legal purposes as necessary
For examples,
Payment orders regarding taxes should be
8
What is a Threat?
2. fraudulent Threat
Authorized users
• Those who abuse their privileges and authority.
Hostile agents
• Those improper users (outsider or insiders).
• who attack the software and/or hardware system, or read or
write data in a database.
10
Database Protection Requirements
●Atomicity
●Consistency
●Isolation
●Durability
● Atomicity. Either all operations of the
transaction are reflected properly in the database,
or none are.
activ
e
faile aborted
d
CISB314 Database II 28
• Example: Transfer RM100 from CUSTOMER A
account to CUSTOMER B account
• Program reads the record for customer A and
subtracts
RM100 from the account balance
• Program reads the record for customer B and adds RM100
to the account balance
• Program writes the updated record for customer A to the
database
• In attempting to write the record for customer B, program
encounters an error condition and cannot write the record
• An UNDO command – recovery manager to apply the
before
image for record customer A to restore account balance
to its original value CISB314 Database II 29
5. Forward Recovery (Rollforward)
• A technique that starts with an earlier copy of the database.
After images are applied to the database and the database
is quickly moved forward to a later state.
• Much faster than Restore/Rerun:
• The time consuming logic of reprocessing each
transaction does not have to be repeated
• Only the most recent after-images need to be applied. DB
record may have series of after image – most recent (good)
after image is required for rollback
CISB314 Database II 30
CISB314 Database II 31
Achievement of unit