From: Carlos O'Donell <carlos@redhat.com>
To: Mingjun Yang <yangmingjun@uniontech.com>, libc-alpha@sourceware.org
Subject: Re: [PATCH] feat: crypt support sm3 algorithm
Date: Thu, 4 Aug 2022 10:44:20 -0400 [thread overview]
Message-ID: <994e108f-38fe-38ed-0b04-80010f96c588@redhat.com> (raw)
In-Reply-To: <20220801025359.1363-1-yangmingjun@uniontech.com>
On 7/31/22 22:53, Mingjun Yang wrote:
> This patch aim to let crypt packet support SM3 algorithms, the
> proccess of SM3 encryption is the same to this semi-formal
> SHA-crypt document (https://www.akkadia.org/drepper/SHA-crypt.txt).
> noted that this patch define that SM3 algorithms ID is 8.
>
> SM3 algorithm is defined in section 23 of ISO/IEC 10118-3:2018
> (https://www.iso.org/standard/67116.html)
> SM3 is similar to SHA256, but its algorithm is more complex.
> SM3 is much safer than SHA256 at the same bit size.
>
> Signed-off-by: Mingjun Yang <yangmingjun@uniontech.com>
What needs do you have that drive this requirement?
I do not want to add any new algorithms to crypt in glibc.
I would instead suggest using libxcrypt, which is an ABI-compatible drop-in
replacement for crypt APIs.
The community worked closely with libxcrypt upstream to ensure it could be
used to provide all the functions required by applications.
For example Fedora uses --disable-crypt to configure glibc and uses libxcrypt
to provide the APIs. This change was done in 2018, and so for almost 4 years
Fedora has been using libxcrypt [1].
If anything I think glibc should switch to disabling libcrypt by default
and provide --enable-legacy-crypt (or something like this) to enable the
legacy library is built and installed. This is similar to the transition we
made with SunRPC to TIRPC [2].
--
Cheers,
Carlos.
[1] https://fedoraproject.org/wiki/Changes/Replace_glibc_libcrypt_with_libxcrypt
[2] https://fedoraproject.org/wiki/Changes/SunRPCRemoval
next prev parent reply other threads:[~2022-08-04 14:44 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-01 2:53 Mingjun Yang
2022-08-04 14:44 ` Carlos O'Donell [this message]
2022-08-04 15:02 ` Cristian Rodríguez
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=994e108f-38fe-38ed-0b04-80010f96c588@redhat.com \
--to=carlos@redhat.com \
--cc=libc-alpha@sourceware.org \
--cc=yangmingjun@uniontech.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).