当前位置:网站首页>Jincang database kingbasees plug-in identity_ pwdexp
Jincang database kingbasees plug-in identity_ pwdexp
2022-06-25 11:07:00 【Thousands of sails pass by the side of the sunken boat_】
Catalog
1. The plugin is introduced
identity_pwdexp yes KingbaseES An extension of , Used to set password validity .
KingbaseES The user management of contains the attribute of password validity , The user password expiration check is to set the validity period of the user password , Restrict user login to the database after the user password expires , And enter the new password .
KingbaseES Check the expiration of user password through plug-in . This way is more flexible , When the user password expiration check is required in the practical scenario of the database , Just load the plug-in . When this function is not required , Just uninstall the plug-in .
KingbaseES Pass through 1 Global level parameters cooperate with the plug-in to implement the user password expiration check .
2. Add plug-ins
In the use of identity_pwdexp Before , You need to add it to kingbase.conf Of documents shared_preload_libraries in , And restart KingbaseES database .
shared_preload_libraries = 'identity_pwdexp' # (change requires restart)
3. Parameter configuration
identity_pwdexp.password_change_interval
Password validity , The unit is day ,0 Means unlimited , The value range is [0,INT_MAX], Default is 7.
Parameters can only be used in postmaster Start or by the security administrator SQL Language (alter command ) Set it up .
sentence :Alter system set Parameter name = Parameter values ;
Run after modification select sys_reload_conf(); No need to restart the server , Effective immediately for all databases and connections .
Specify the password when creating a user , It can be done by valid until Option to specify the password validity period for this user , The specified password validity period must be later than the current time and earlier than the replacement cycle identity_pwdexp.password_change_interval Specified time .
For a user who has been successfully created and has a password , Can also pass alter Of the statement valid until Option to change the password validity , But only the security administrator has this permission , Other users cannot modify the password change cycle of themselves and others .
If it is not displayed when creating a user or modifying a user password, it can be passed valid until Option to specify the password validity period for this user , Then the system will be based on identity_pwdexp.password_change_interval The value set by the parameter will automatically calculate the password validity period .
identity_pwdexp.max_password_change_interval
Maximum password validity , The unit is day , The value range is [1,INT_MAX], Default is 30.
Parameters can only be used in postmaster Start or by the security administrator SQL Language (alter command ) Set it up .
This parameter is used to limit the setting range of password validity , When the set password validity period is greater than the maximum password validity period , The system will give an error prompt .
4. Example
-- Create extensions
\c test system
create extension identity_pwdexp;
CREATE EXTENSION
-- Set password validity to 5 God
\c test sso
show identity_pwdexp.password_change_interval;
identity_pwdexp.password_change_interval
--------------------------
7
(1 row)
alter system set identity_pwdexp.password_change_interval = 5;
ALTER SYSTEM
show identity_pwdexp.password_change_interval;
identity_pwdexp.password_change_interval
------------------------------------------
0
(1 rows )
select sys_reload_conf();
sys_reload_conf
-----------------
t
(1 rows )
show identity_pwdexp.password_change_interval;
identity_pwdexp.password_change_interval
------------------------------------------
5
(1 rows )
\c test system
call now();
now
-------------------------------
2020-04-30 15:34:30.408304+08
(1 rows )
CREATE USER u_pwd_et PASSWORD '1234567890abC/.' VALID UNTIL '2020-05-01';
CREATE ROLE
SELECT USENAME, VALUNTIL FROM SYS_USER WHERE USENAME = 'u_pwd_et';
usename | valuntil
----------+------------------------
u_pwd_et | 2020-05-01 00:00:00+08
(1 rows )
ALTER USER u_pwd_et PASSWORD '/.1234567890abC';
Warning : user "u_pwd_et" does not be locked
ALTER ROLE
SELECT USENAME, VALUNTIL FROM SYS_USER WHERE USENAME = 'u_pwd_et';
usename | valuntil
----------+-------------------------------
u_pwd_et | 2020-05-05 15:35:23.448381+08
(1 rows )
5. Uninstall plugins
modify kingbase.conf In file shared_preload_libraries Restart the database after parameters .
shared_preload_libraries = ''
边栏推荐
- 16 种企业架构策略
- Performance network
- Daily Mathematics Series 52: February 20
- 一个数学难题,难倒两位数学家
- Cdn+cos ultra detailed steps for drawing bed construction
- Google Earth Engine (Gee) - evaluate réalise le téléchargement en un clic de toutes les images individuelles dans la zone d'étude (certaines parties de Shanghai)
- Android: generic mapping analysis of gson and JSON in kotlin
- 金仓数据库 KingbaseES 插件DBMS_RANDOM
- Some assembly instructions specific to arm64
- 1-7Vmware中的快照与克隆
猜你喜欢

Ouverture de l'inscription | le troisième marathon des hackers de pagaie est arrivé comme prévu.
![[observation] objectscale: redefining the next generation of object storage, reconstruction and innovation of Dell Technology](/img/82/8cac87231e51698ab17f1274b3a0bd.jpg)
[observation] objectscale: redefining the next generation of object storage, reconstruction and innovation of Dell Technology

Netease's open source distributed storage system curve officially became the CNCF sandbox project

How to start the phpstudy server

Previous string inversion topic

Crawler scheduling framework of scratch+scratch+grammar

【文件包含漏洞-03】文件包含漏洞的六种利用方式

A five-year technical Er, based on the real experience of these years, gives some suggestions to the fresh students
![[file inclusion vulnerability-04] classic interview question: how to getshell when a website is known to have only local file inclusion vulnerability?](/img/28/ab02d38bde47053b155e0545b47039.png)
[file inclusion vulnerability-04] classic interview question: how to getshell when a website is known to have only local file inclusion vulnerability?

Chinese translation of IMA Lazarus' the new giant, the goddess of Liberty
随机推荐
仿真与烧录程序有哪几种方式?(包含常用工具与使用方式)
relu与sigmod的比较
报名开启|飞桨黑客马拉松第三期如约而至,久等啦
Previous string inversion topic
每日3题(2)- 找出数组中的幸运数
中國信通院沈瀅:字體開源協議——OFL V1.1介紹及合規要點分析
Flutter adds event listening | subscription
Explanation and use of kotlin syntax for Android
Spannable 和 Editable、SpannableString 和 SpannableString
Google Earth engine (GEE) - evaluate enables one click batch download of all single images in the research area (some areas in Shanghai)
Advanced single chip microcomputer -- development of PCB (2)
无心剑中译伊玛·拉扎罗斯《新巨人·自由女神》
Free access to the global human settlements layer (ghsl) dataset from Gee
Cdn+cos ultra detailed steps for drawing bed construction
COSCon'22 讲师征集令
有关计网的五种类型题
Is it safe to open an account through mobile phone if you open an account through stock speculation? Who knows?
FPGA displays characters and pictures based on VGA
Netease's open source distributed storage system curve officially became the CNCF sandbox project
Jincang KFS data cascade scenario deployment