授予/撤销用户 oracle 的执行权限
GRANT/REVOKE 权限究竟如何影响数据库。
我有一个解决方案,可以解决我的组件之一(可执行文件)无法识别我的 Oracle 配置包的问题。但是我是否可以通过撤销来进行测试,
revoke execute on package_name to user1;
然后再次授予,
grant execute on package_name to user1;
总之,这是否会对特权产生负面影响。这主要是因为 user1 是一个通用用户,所以这就是我谨慎的原因。
谢谢
How exactly is the GRANT/REVOKE privileges affecting the database.
I have a solution ready for a problem where one of my components(an executable) is not identifying my oracle config packages. But is it possible for me to test by revoking with this,
revoke execute on package_name to user1;
And then again grant,
grant execute on package_name to user1;
In short, can this in anyway affect the privileges negatively. This is mainly because user1 is a generic user so that's why I am being cautious.
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
但是,当然,撤销权限会对用户产生负面影响……它将无法再使用该包。
如果该用户 (
user1
) 已向其他用户授予权限(因为它被授予带有授予选项
的权限),事情可能会更加复杂,因为 - 一旦您从撤销权限code>user1
,Oracle 将自动撤销所有这些用户/角色的权限(这就是我们所说的级联效应)。因此,要小心。我想测试它的最佳选择是拥有一个单独的测试数据库。在那里你可以做任何你想做的事情,因为它不会影响生产中的任何人。
最后,它是
从用户撤销权限
,而不是TO
(指您发布的第一个声明)。But of course that revoking a privilege affects that user negatively ... it won't be able to use that package any more.
Things can be even more complicated if that user (
user1
) has granted privilege to other users (as it was granted privilegewith grant option
) because - once you revoke privileges fromuser1
, Oracle will automatically revoke privileges from all those users/roles (that's what we'd call a cascading effect).Therefore, be careful. I guess that your best option to test it is to have a separate - testing - database. There you can do anything you want, as it won't affect nobody in production.
Finally, it is
revoke privilege FROM user
, notTO
(referring to the 1st statement you posted).