是否可以在没有 DBA 权限的情况下查看 Oracle 用户表权限?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/1166064/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Is it possible to view Oracle user table privileges without having DBA privilege?
提问by grokster
Is it possible to view the roles of the user without having DBA Privilege? If so, how?
是否可以在没有 DBA 权限的情况下查看用户的角色?如果是这样,如何?
SELECT * FROM DBA_TAB_PRIVS WHERE GRANTEE = 'USER_NAME';
The above query needs the "SELECT_CATALOG_ROLE" role.
上述查询需要“SELECT_CATALOG_ROLE”角色。
I need to get the result of the above query without (DBA and SELECT_CATALOG_ROLE) Privileges.
我需要在没有(DBA 和 SELECT_CATALOG_ROLE)特权的情况下获得上述查询的结果。
回答by Adam Paynter
Perhaps ALL_TAB_PRIVS
will provide what you want. Apparently, it contains:
也许ALL_TAB_PRIVS
会提供你想要的。显然,它包含:
Grants on objects for which the user is the grantor, grantee, owner, or an enabled role or PUBLIC is the grantee
对用户是授予者、被授予者、所有者或已启用角色或 PUBLIC 是被授予者的对象的授予
回答by grokster
See me what GRANTs and Privileges I have:
看看我有哪些 GRANT 和特权:
SELECT * FROM user_tab_privs;
回答by jedd
DBA_TAB_PRIVS DBA_SYS_PRIVS DBA_ROLE_PRIVS
DBA_TAB_PRIVS DBA_SYS_PRIVS DBA_ROLE_PRIVS
Here are the main tables you can check for roles and privs
以下是您可以检查角色和权限的主要表
回答by jedd
You could have the DBA create a new role and grant the new role select on the table. The DBA could then grant you the new role which will allow you to see the table without DBA or select catalog role.
您可以让 DBA 创建一个新角色并授予新角色选择表。然后,DBA 可以授予您新角色,这将允许您在没有 DBA 的情况下查看表或选择目录角色。