From: Gu Bowen <gubowen5@huawei.com>
To: Herbert Xu <herbert@gondor.apana.org.au>,
David Howells <dhowells@redhat.com>,
David Woodhouse <dwmw2@infradead.org>,
Lukas Wunner <lukas@wunner.de>,
Ignat Korchagin <ignat@cloudflare.com>,
"David S . Miller" <davem@davemloft.net>,
Jarkko Sakkinen <jarkko@kernel.org>,
Maxime Coquelin <mcoquelin.stm32@gmail.com>,
Alexandre Torgue <alexandre.torgue@foss.st.com>,
Eric Biggers <ebiggers@kernel.org>,
"Jason A . Donenfeld" <Jason@zx2c4.com>,
Ard Biesheuvel <ardb@kernel.org>,
Tianjia Zhang <tianjia.zhang@linux.alibaba.com>,
Dan Carpenter <dan.carpenter@linaro.org>
Cc: <keyrings@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
<linux-crypto@vger.kernel.org>,
<linux-stm32@st-md-mailman.stormreply.com>,
<linux-arm-kernel@lists.infradead.org>,
Lu Jialin <lujialin4@huawei.com>,
GONG Ruiqi <gongruiqi1@huawei.com>,
Gu Bowen <gubowen5@huawei.com>
Subject: [PATCH RFC 0/4] Reintroduce the sm2 algorithm
Date: Mon, 30 Jun 2025 21:39:30 +0800 [thread overview]
Message-ID: <20250630133934.766646-1-gubowen5@huawei.com> (raw)
To reintroduce the sm2 algorithm, the patch set did the following:
- Reintroduce the mpi library based on libgcrypt.
- Reintroduce ec implementation to MPI library.
- Rework sm2 algorithm.
- Support verification of X.509 certificates.
Gu Bowen (4):
Revert "Revert "lib/mpi: Extend the MPI library""
Revert "Revert "lib/mpi: Introduce ec implementation to MPI library""
crypto/sm2: Rework sm2 alg with sig_alg backend
crypto/sm2: support SM2-with-SM3 verification of X.509 certificates
certs/system_keyring.c | 8 +
crypto/Kconfig | 18 +
crypto/Makefile | 8 +
crypto/asymmetric_keys/public_key.c | 7 +
crypto/asymmetric_keys/x509_public_key.c | 27 +-
crypto/sm2.c | 492 +++++++
crypto/sm2signature.asn1 | 4 +
crypto/testmgr.c | 6 +
crypto/testmgr.h | 57 +
include/crypto/sm2.h | 31 +
include/keys/system_keyring.h | 13 +
include/linux/mpi.h | 170 +++
lib/crypto/mpi/Makefile | 2 +
lib/crypto/mpi/ec.c | 1507 ++++++++++++++++++++++
lib/crypto/mpi/mpi-add.c | 50 +
lib/crypto/mpi/mpi-bit.c | 143 ++
lib/crypto/mpi/mpi-cmp.c | 46 +-
lib/crypto/mpi/mpi-div.c | 29 +
lib/crypto/mpi/mpi-internal.h | 10 +
lib/crypto/mpi/mpi-inv.c | 143 ++
lib/crypto/mpi/mpi-mod.c | 144 +++
lib/crypto/mpi/mpicoder.c | 336 +++++
lib/crypto/mpi/mpih-mul.c | 25 +
lib/crypto/mpi/mpiutil.c | 182 +++
24 files changed, 3447 insertions(+), 11 deletions(-)
create mode 100644 crypto/sm2.c
create mode 100644 crypto/sm2signature.asn1
create mode 100644 include/crypto/sm2.h
create mode 100644 lib/crypto/mpi/ec.c
create mode 100644 lib/crypto/mpi/mpi-inv.c
--
2.25.1
next reply other threads:[~2025-06-30 13:27 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-30 13:39 Gu Bowen [this message]
2025-06-30 13:39 ` [PATCH RFC 1/4] Revert "Revert "lib/mpi: Extend the MPI library"" Gu Bowen
2025-07-03 9:18 ` Xi Ruoyao
2025-06-30 13:39 ` [PATCH RFC 2/4] Revert "Revert "lib/mpi: Introduce ec implementation to " Gu Bowen
2025-07-02 15:18 ` Ignat Korchagin
2025-06-30 13:39 ` [PATCH RFC 3/4] crypto/sm2: Rework sm2 alg with sig_alg backend Gu Bowen
2025-06-30 13:39 ` [PATCH RFC 4/4] crypto/sm2: support SM2-with-SM3 verification of X.509 certificates Gu Bowen
2025-06-30 19:41 ` [PATCH RFC 0/4] Reintroduce the sm2 algorithm Dan Carpenter
2025-07-01 3:49 ` Gu Bowen
2025-07-03 13:14 ` Jason A. Donenfeld
2025-07-03 13:29 ` Jason A. Donenfeld
2025-07-03 13:33 ` Ignat Korchagin
2025-07-11 2:14 ` Gu Bowen
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=20250630133934.766646-1-gubowen5@huawei.com \
--to=gubowen5@huawei.com \
--cc=Jason@zx2c4.com \
--cc=alexandre.torgue@foss.st.com \
--cc=ardb@kernel.org \
--cc=dan.carpenter@linaro.org \
--cc=davem@davemloft.net \
--cc=dhowells@redhat.com \
--cc=dwmw2@infradead.org \
--cc=ebiggers@kernel.org \
--cc=gongruiqi1@huawei.com \
--cc=herbert@gondor.apana.org.au \
--cc=ignat@cloudflare.com \
--cc=jarkko@kernel.org \
--cc=keyrings@vger.kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-stm32@st-md-mailman.stormreply.com \
--cc=lujialin4@huawei.com \
--cc=lukas@wunner.de \
--cc=mcoquelin.stm32@gmail.com \
--cc=tianjia.zhang@linux.alibaba.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).