add sm3 crypt support
(cherry picked from commit 0f9094f1ec39c3761d9b3897ead43a85d1061099)
This commit is contained in:
parent
0c693589db
commit
2717ef9340
27
add-sm3-crypt-support.patch
Normal file
27
add-sm3-crypt-support.patch
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
From 87c95887b93ffac388b30ea81d41f83782e8cd34 Mon Sep 17 00:00:00 2001
|
||||||
|
From: lujie42 <lujie42@huawei.com>
|
||||||
|
Date: Thu, 28 Oct 2021 20:06:53 +0800
|
||||||
|
Subject: [PATCH] add sm3 crypt support
|
||||||
|
|
||||||
|
Signed-off-by: lujie42 <lujie42@huawei.com>
|
||||||
|
---
|
||||||
|
libuser.c | 3 +++
|
||||||
|
1 file changed, 3 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/libuser.c b/libuser.c
|
||||||
|
index 7a36520..f5bedc1 100644
|
||||||
|
--- a/libuser.c
|
||||||
|
+++ b/libuser.c
|
||||||
|
@@ -298,6 +298,9 @@ pwdb_display_status(const char *username)
|
||||||
|
} else if (strncmp(current, "$6$", 3) ==
|
||||||
|
0) {
|
||||||
|
msg = _("Password set, SHA512 crypt.");
|
||||||
|
+ } else if (strncmp(current, "$sm3$", 5) ==
|
||||||
|
+ 0) {
|
||||||
|
+ msg = _("Password set, SM3 crypt.");
|
||||||
|
} else {
|
||||||
|
msg = _("Password set, unknown crypt variant.");
|
||||||
|
}
|
||||||
|
--
|
||||||
|
1.8.3.1
|
||||||
|
|
||||||
10
passwd.spec
10
passwd.spec
@ -1,11 +1,13 @@
|
|||||||
Name: passwd
|
Name: passwd
|
||||||
Version: 0.80
|
Version: 0.80
|
||||||
Release: 8
|
Release: 9
|
||||||
Summary: An implementation of the password setting/changing utility through PAM and libuser libraries
|
Summary: An implementation of the password setting/changing utility through PAM and libuser libraries
|
||||||
License: BSD or GPL+
|
License: BSD or GPL+
|
||||||
URL: https://pagure.io/passwd
|
URL: https://pagure.io/passwd
|
||||||
Source0: https://releases.pagure.org/passwd/passwd-%{version}.autotoolized.tar.bz2
|
Source0: https://releases.pagure.org/passwd/passwd-%{version}.autotoolized.tar.bz2
|
||||||
|
|
||||||
|
Patch9000: add-sm3-crypt-support.patch
|
||||||
|
|
||||||
BuildRequires:libselinux-devel >= 2.1.6-3 gcc glib2-devel, libuser-devel, pam-devel, libuser >= 0.53-1
|
BuildRequires:libselinux-devel >= 2.1.6-3 gcc glib2-devel, libuser-devel, pam-devel, libuser >= 0.53-1
|
||||||
BuildRequires: gettext, popt-devel audit-libs-devel >= 2.4.5
|
BuildRequires: gettext, popt-devel audit-libs-devel >= 2.4.5
|
||||||
Requires:libselinux >= 2.1.6-3 audit-libs >= 2.4.5 pam >= 1.0.90, /etc/pam.d/system-auth
|
Requires:libselinux >= 2.1.6-3 audit-libs >= 2.4.5 pam >= 1.0.90, /etc/pam.d/system-auth
|
||||||
@ -55,6 +57,12 @@ make check
|
|||||||
%{_mandir}/man1/*.gz
|
%{_mandir}/man1/*.gz
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu Oct 28 2021 lujie <lujie42@huawei.com> - 0.80-9
|
||||||
|
- Type:requirement
|
||||||
|
- ID:NA
|
||||||
|
- SUG:NA
|
||||||
|
- DESC:add sm3 crypt support
|
||||||
|
|
||||||
* Fri Sep 10 2021 Hugel <gengqihu1@huawei.com> - 0.80-8
|
* Fri Sep 10 2021 Hugel <gengqihu1@huawei.com> - 0.80-8
|
||||||
- Type:enhancement
|
- Type:enhancement
|
||||||
- ID:NA
|
- ID:NA
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user