oracle使用者安全管理

2021-04-27 23:48:03 字數 1837 閱讀 4025

oracle使用者安全管理   http://blog.csdn.net/wyzxg/archive/2008/04/09/2270974.aspx

oracle的使用者安全

作為dba一定要保證資料庫的安全,備份是要時刻準備的,個人覺得資料庫就好比乙個座樓

,要想最好的的保護樓,,最好是整個樓沒有窗戶和門等入口,我可以限制進入大樓的人,

對可以進入樓的人,根據他們的實際情況,限制他們在樓裡的活動情況.我門資料庫也是一樣的

資料庫裡的使用者根據不同的應用就有不同的許可權,下面我就個人對資料庫使用者安全提出個方案

資料庫的許可權分為實體許可權和系統許可權:

1. 系統許可權

一般使用者分為開發使用者,dba使用者

開發使用者一般許可權:

角色:connect,resource

系統許可權:

unlimited tablespace

所以開發使用者建立如下:

sys at omovo>  create user movo_new_dba identified by skate_dba

2  default tablespace movo_tbs

3  temporary tablespace temp;

user created.

sys at omovo>

sys at omovo>  grant connect,resource,unlimited tablespace  to skate_dba;

grant succeeded.

使用者登入,檢視自己具有的系統許可權:

select * from user_sys_privs

使用者登入,檢視自己擁有的角色:

select * from role_sys_privs

檢視資料庫共擁有的多少個角色

select * from dba_roles;

檢視使用者把什麼許可權授給了哪些表

select * from user_tab_privs

2.資料庫的實體許可權管理:

為了方便管理,可以把乙個使用者下的所由物件的所有許可權授予乙個角色,如果想得到這個使用者的所有許可權,可以授予這個角色

資料庫的實體許可權分類: 表,檢視,序列,過程,快照

通過下面的語句來生成需要授權的所有實體的語句

select

'grant all on '||object_name || ' to movo_new_role;'  from user_objects where object_type in

('table','sequence','procedure','view')

1.建立角色

sys at omovo>  create role skate_role;

role created.

2.把資料庫實體的許可權授權給建立的角色

執行上面語句的查詢結果,

3.把角色授權給相應的使用者

sys at omovo>  grant skate_role to skate_dba;

可以刪除角色

sys at omovo>  drop role skate_role

*.建議資料庫最低安全使用者:

開發使用者: connect,resource,unlimited tablespace(可以根據你的需要,建立更安全的角色)

管理使用者: connect,resource,dba

*.使用者要是暫時不用,可以先鎖定使用者:

sys at omovo> alter user perfstat account lock;

為使用者解鎖:

sys at omovo> alter user perfstat account unlock;

oracle 管理使用者和安全性

查詢物件型別 select distinct object type from dba objects 查詢使用者 select from dba users 授予使用者許可權 grant connect,resource to u1 一般授予這兩個,登入連線會話和使用資源 查詢系統所有許可權 se...

Oracle安全管理

oracle 10g 資料庫系統學習筆記 安全管理 2008 09 26 20 20建立test使用者 利用企業管理工具建立test使用者的sql語法 create user test profile default identified by account unlock grant connec...

ORACLE安全管理

cmd 進入dos頁面 鍵入命令 sqlplus as sysdba進入oracle 超級管理 1 用dba角色的使用者登陸,進行解鎖,先設定具體時間格式,以便檢視具體時間 sql alter session set nls date format yyyy mm dd hh24 mi ss ses...