代码拉取完成,页面将自动刷新
同步操作将从 src-openEuler/anaconda 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
From 3562cad5ea86afc5d2ce0ead649e64cf13e39128 Mon Sep 17 00:00:00 2001
From: sun_hai_10 <sunhai10@huawei.com>
Date: Mon, 7 Nov 2022 14:48:28 +0800
Subject: [PATCH] add passwd policy
---
data/anaconda.conf | 6 +++---
pyanaconda/input_checking.py | 4 ++++
2 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/data/anaconda.conf b/data/anaconda.conf
index 703114a..07e500f 100644
--- a/data/anaconda.conf
+++ b/data/anaconda.conf
@@ -308,9 +308,9 @@ can_change_users = False
# strict Require the minimum quality.
#
password_policies =
- root (quality 1, length 6)
- user (quality 1, length 6, empty)
- luks (quality 1, length 6)
+ root (quality 1, length 8, strict)
+ user (quality 1, length 8, empty, strict)
+ luks (quality 1, length 8, strict)
[License]
diff --git a/pyanaconda/input_checking.py b/pyanaconda/input_checking.py
index 4482b26..4bed6c1 100644
--- a/pyanaconda/input_checking.py
+++ b/pyanaconda/input_checking.py
@@ -421,6 +421,10 @@ class PasswordValidityCheck(InputCheck):
pw_score = 4
status_text = _(constants.SecretStatus.STRONG.value)
+ #disable set password without confirnation
+ if not error_message and not check_request.password_confirmation:
+ error_message = _(constants.SECRET_CONFIRM_ERROR_GUI[check_request.secret_type])
+
# the policy influences the overall success of the check
# - score 0 & strict == True -> success = False
# - score 0 & strict == False -> success = True
--
2.23.0
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。