用户管理

超级用户登录

用户管理

创建对象分配权限

Create user liucunzhi identified by root;

Grant resource to liucunzhi;

Grant connect to liucuzhi;

Connect liucunzhi/root;

 

 

为对象分配表的权限

对象权限分为 select update insert delete all

Grant select on emp to liucunzhi;

Select * from sys.emp;

Revoke select on emp from liucunzhi ;

 

可以继续传递权限的话

如果是对象权限 + with grant  option

如果 revoke 权限 liucunzhi 分配 出去的权限也被收回

grant all on emp to liucunzhi with grant option

这 liucunzhi 可以为其他的

如果是系统权限 with admin option

 

 

管理用户口令

使用 profile 管理用户口令

(1)       账户锁定指定用户锁定时间,指定用户输入密码出错的次数

注意:红色部分不能变 3 次 2 天

create profile 文件名   limit

failed_login_attempts 3 password_lock_time 2 ;

( 2 )解锁: alter user liucunzhi2 account unlock

3 )终止命令为了让用户定期更改密码

SQL> create profile myprofile limit password_life_time 10 ;

配置文件已创建

SQL> alter user liucunzhi2 profile myprofile;

用户已更改。

 

口令历史

create profile myprofile limit password_life_time 10 password_reuse_time 10// 十天之后可重复用着个用户名

drop profile password_history[cascade]

 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值