Bo's Oracle Station

查看: 2074|回复: 0

第43次:2015-08-19星期三

[复制链接]

1005

主题

1469

帖子

1万

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
12012
发表于 2015-8-20 11:13:00 | 显示全部楼层 |阅读模式
2015-08-19a.sql:
  1. select * from dba_users where username='SYSTEM';

  2. alter user sysman identified by oracle_4U;

  3. select * from user$ where name ='SYS';

  4. 48DF04E7BAB11018;

  5. select  * from dba_sys_privs sp where sp.grantee='SYSTEM';

  6. select  * from dba_role_privs rp where rp.grantee='SYSTEM';

  7. grant sysdba to hr;

  8. revoke sysdba from hr;

  9. select  * from role_sys_privs rsp where rsp.role='DBA';

  10. select  * from role_tab_privs rtp where rtp.role='DBA';

  11. select  * from role_role_privs rrp where rrp.role='DBA';

  12. select  * from dba_sys_privs sp where sp.grantee='HR';

  13. select  * from dba_tab_privs tp where tp.grantee='HR';

  14. select  * from dba_role_privs rp where rp.grantee='HR';

  15. grant select_catalog_role to hr;

  16. revoke  select_catalog_role  from hr;

  17. select  * from role_sys_privs rsp where rsp.role='CONNECT';

  18. select  * from role_tab_privs rtp where rtp.role='CONNECT';

  19. select  * from role_role_privs rrp where rrp.role='CONNECT';

  20. select * from dba_users  order by username;

  21. grant connect  to u1 identified by  oracle_4U;

  22. grant create session  to u2 identified by  oracle_4U;

  23. create user u3 identified by u3 ;
  24. grant connect to u3;

  25. select  * from dba_sys_privs sp where sp.grantee='U1';

  26. select  * from dba_tab_privs tp where tp.grantee='U1';

  27. select  * from dba_role_privs rp where rp.grantee='U1';

  28. select   distinct  sp.privilege  from dba_sys_privs sp  order by 1;

  29. grant create table to u1;

  30. select  * from dba_segments s where s.owner='U1' and s.segment_name='T05208_A';

  31. select  * from dba_ts_quotas ;

  32. alter user u1 quota 64k on  users;

  33. alter user u1 quota 0 on  users;
复制代码

2015-08-19b.sql:
  1. select  * from dba_sys_privs sp where sp.grantee='U1';

  2. select  * from dba_tab_privs tp where tp.grantee='U1';

  3. select  * from dba_role_privs rp where rp.grantee='U1';

  4. select  * from role_sys_privs rsp where rsp.role='RESOURCE';

  5. select  * from role_tab_privs rtp where rtp.role='RESOURCE';

  6. select  * from role_role_privs rrp where rrp.role='RESOURCE';

  7. grant resource to u1;

  8. revoke resource  from u1;


  9. select * from dba_users where username='U1';


  10. alter user u1 account lock;

  11. alter user u1 account unlock;

  12. alter user u1 password expire;

  13. grant select any table to u1;

  14. grant select any table to public;

  15. revoke  select any table from u1;

  16. revoke select  any table from public;

  17. select  * from dba_sys_privs sp where sp.grantee='U1';

  18. select  * from dba_tab_privs tp where tp.grantee='U1';

  19. select  * from dba_col_privs c where c.grantee='U1';

  20. select  * from dba_role_privs rp where rp.grantee='U1';


复制代码



回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

QQ|手机版|Bo's Oracle Station   

GMT+8, 2024-11-22 06:01 , Processed in 0.039283 second(s), 24 queries .

快速回复 返回顶部 返回列表