企业版V6口令复杂度配置 目录

文档用途

本文档用于指导瀚高数据库企业版V6的口令复杂度配置

详细信息

瀚高数据库企业版V6在创建新用户设置口令或修改已有用户口令时,默认要符合以下规则:

(1)最短长度8位,最长长度1024位。开关参数passwordlength,默认on。

(2)须同时含有数字 、大小写字母和特殊字符,特殊字符包括 “!@#$%^&*()”。不能使用包含瀚高数据库关键字和当前用户名的密码,以及其他被数据库系统认定为过于简单的密码。开关参数passwordstrength,默认on。

(3)不能使用前五次使用过的密码。开关参数passwordhistory,默认on。

(4)创建用户所使用的密码不能含有瀚高保留字、关键字。

关闭以上口令复杂度功能需要使用管理员执行“alter system set passwordxxxx = off”后,重启数据库生效。

例:

1、关闭口令强度要求,设置简单密码

[highgo@host ~]$ psql highgo highgo

highgo=# create user test with password 'cQdGp#n3';

CREATE ROLE

highgo=# alter user test with password 'cqdcqdcqd';

ERROR:  Password must contain upper and lower case letters, numbers, and special characters:cqdcqdcqd.

highgo=# alter system set passwordstrength = off;

ALTER SYSTEM

highgo=# \q

[highgo@host ~]$ pg_ctl restart

[highgo@host ~]$ psql highgo highgo

highgo=# alter user test with password 'cqdcqdcqd';

ALTER ROLE

2、关闭口令长度要求

[highgo@host ~]$ psql highgo highgo

highgo=# alter user test with password 'cqd';

ERROR:  The password is too short

highgo=# alter system set passwordlength = off;

ALTER SYSTEM

highgo=# \q

[highgo@host ~]$ pg_ctl restart

[highgo@host ~]$ psql highgo highgo

highgo=# alter user test with password 'cqd';

ALTER ROLE

3、能重复设置之前的口令

[highgo@host ~]$ psql highgo highgo

highgo=# alter user test with password 'cqdcqdcqd';

ERROR:  The password cannot be the same as the old password.

highgo=# alter system set passwordhistory = off;

ALTER SYSTEM

highgo=# \q

[highgo@host ~]$ pg_ctl restart

[highgo@host ~]$ psql highgo highgo

highgo=# alter user test with password 'cqdcqdcqd';

ALTER ROLE
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值