slides(lec-7)
slides(lec-7)
Administrator Authentication
Operating System Security
DBAs must have the OS privileges to create and
delete files: Database Administrators (DBAs) require
operating system (OS) privileges that allow them to create
and delete files. This is necessary because many
administrative tasks involve managing database files
directly, such as adding new datafiles, moving files, and
removing obsolete files. Without these OS privileges,
DBAs wouldn't be able to fully manage the database
infrastructure.
Typical database users should not have the OS
privileges to create or delete database files: Regular
database users should not have OS-level privileges to
create or delete database files. Granting these privileges
could lead to accidental or malicious changes that could
jeopardize the integrity and availability of the database.
Administrator Security
For SYSDBA, SYSOPER, and SYSASM connections:
These are special administrative roles in Oracle
databases that have extensive privileges:
• SYSDBA: Full database administration privileges,
including the ability to start up and shut down the
database.
• SYSOPER: Limited set of administrative privileges
primarily for operations like startup and shutdown.
• SYSASM: Specific privileges related to Automatic
Storage Management (ASM).
DBA user by name is audited for password file and
strong authentication methods: When a DBA connects
using a username, the connection is audited to ensure that
strong authentication methods are being used. This helps
in tracking and securing access, ensuring that only
authorized individuals can perform sensitive tasks.
OS account name is audited for OS authentication:
For connections authenticated via the operating system,
the OS account name is audited. This helps in maintaining
a log of who accessed the database using OS
authentication, providing a trail that can be reviewed for
security purposes.
OS authentication takes precedence over password
file authentication for privileged users: When a user
has both OS authentication and password file
authentication enabled, OS authentication is given priority.
This means that if a user is authenticated by the OS, that
authentication is used first, providing a more seamless
and potentially more secure method of authenticating
privileged users.
Password file uses case-sensitive passwords: The
password file, which stores credentials for users with
SYSDBA and SYSOPER privileges, enforces case-
sensitive passwords. This enhances security by
increasing the complexity of passwords, making them
harder to guess or crack.
Privileges
User privileges in a database are critical for managing what
actions users can perform and which objects they can access
or manipulate. These privileges are categorized into two main
types: System Privileges and Object Privileges.
System Privileges
Definition:
System privileges are permissions that allow users to perform
specific actions that affect the entire database system or certain
aspects of it. These privileges are not tied to any particular
object (such as a table or a view) but rather enable users to
execute administrative tasks or access system-wide functions.
Examples:
CREATE SESSION: Allows the user to connect to the
database.
CREATE TABLE: Allows the user to create new tables in
the database.
ALTER SYSTEM: Permits the user to alter the system
settings.
CREATE USER: Enables the user to create new database
users.
DROP TABLESPACE: Allows the user to drop (delete) a
tablespace.
Object Privileges
Definition:
Object privileges are permissions that allow users to perform
actions on specific database objects. These objects can include
tables, views, sequences, procedures, and other database
objects. Object privileges enable users to access and
manipulate these specific objects as needed.
Examples:
SELECT: Allows the user to retrieve data from a specific
table or view.
INSERT: Permits the user to insert data into a specific
table.
UPDATE: Enables the user to update existing data in a
specific table.
DELETE: Allows the user to delete data from a specific
table.
EXECUTE: Permits the user to execute a specific stored
procedure or function.
ALTER: Allows the user to alter the structure of a specific
table or view.
Revoking System Privileges with ADMIN OPTION
Scenario:
The DBA grants the CREATE TABLE system privilege to
Jeff with ADMIN OPTION.
Jeff creates a table.
Jeff grants the CREATE TABLE system privilege to Emi.
Emi creates a table.
The DBA revokes the CREATE TABLE system privilege
from Jeff.
Result:
Jeff’s table still exists, but Jeff cannot create new tables.
Emi’s table still exists, and she still has the CREATE
TABLE system privilege.
Revoking Object Privileges with GRANT OPTION
Scenario:
Jeff is granted the SELECT object privilege on
EMPLOYEES with GRANT OPTION.
Jeff grants the SELECT privilege on EMPLOYEES to Emi.
Result:
The SELECT privilege is revoked from Jeff. This revoke is
cascaded to Emi as well.
Benefits of Roles
1. Easier Privilege Management:
• Roles allow DBAs to group multiple privileges into a
single named entity. Instead of assigning and
managing numerous individual privileges for each
user, DBAs can assign a role to the user. This
significantly reduces the complexity and effort
involved in privilege management.
• Consistency: Roles help ensure consistency in
privilege assignments. By using roles, DBAs can
maintain a standard set of privileges for similar types
of users, such as developers, analysts, and
administrators.
2. Dynamic Privilege Management:
• Flexible Assignments: Roles can be easily
assigned or revoked from users without altering the
underlying individual privileges. This allows for
dynamic changes to user access levels based on
changing requirements.
• Centralized Updates: Updating a role (e.g., adding
or removing privileges) automatically updates the
privileges for all users assigned to that role. This
makes it easier to manage changes in privilege
requirements centrally.
3. Selective Availability of Privileges:
• Context-Specific Access: Roles can be created for
specific tasks or projects, allowing users to have the
necessary privileges only when they need them. This
reduces the risk of over-privileged accounts and
enhances security.
• Granular Control: By using roles, DBAs can control
which users have access to which resources and
functionalities, providing a more granular and precise
control over database access.
• Temporary Assignments: Roles can be temporarily
assigned to users for specific tasks or projects and
then revoked once the tasks are completed,
providing a way to manage short-term access needs
effectively.