From: "Daniel P. Berrangé" <berrange@redhat.com>
To: "Thomas Huth" <thuth@redhat.com>,
"Hyman Huang" <yong.huang@smartx.com>,
qemu-devel@nongnu.org, "Paolo Bonzini" <pbonzini@redhat.com>,
"Marc-André Lureau" <marcandre.lureau@redhat.com>,
"Philippe Mathieu-Daudé" <philmd@linaro.org>,
"Eric Blake" <eblake@redhat.com>,
"Markus Armbruster" <armbru@redhat.com>
Subject: Re: [PATCH v6] crypto: Introduce SM4 symmetric cipher algorithm
Date: Mon, 11 Mar 2024 10:14:58 +0000 [thread overview]
Message-ID: <Ze7Zomg9YrhvrN2J@redhat.com> (raw)
In-Reply-To: <Ze7PsJV7eQar1hNe@redhat.com>
On Mon, Mar 11, 2024 at 09:32:32AM +0000, Daniel P. Berrangé wrote:
> On Fri, Mar 08, 2024 at 09:30:52PM +0100, Thomas Huth wrote:
> > On 07/12/2023 16.47, Hyman Huang wrote:
> > > Introduce the SM4 cipher algorithms (OSCCA GB/T 32907-2016).
> > >
> > > SM4 (GBT.32907-2016) is a cryptographic standard issued by the
> > > Organization of State Commercial Administration of China (OSCCA)
> > > as an authorized cryptographic algorithms for the use within China.
> > >
> > > Detect the SM4 cipher algorithms and enable the feature silently
> > > if it is available.
> > >
> > > Signed-off-by: Hyman Huang <yong.huang@smartx.com>
> > > Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
> > > ---
> >
> > FYI, starting with this commit, tests/unit/test-crypto-cipher is now failing
> > on s390x hosts (i.e. big endian machines)... could be that there is maybe an
> > endianess issue somewhere in here...
>
> Or more worringly the issue could be in nettle's impl of SM4, as
> I'm not seeing an obvious place in this QEMU glue layer which
> could cause endianness mistakes.
This is not a s390x problem in fact, it happens on all arches.
For unknown reasons RHEL has disabled build of the SM4 cipher
algorithm in libgcrypt.
If building QEMU with nettle you won't see the problem, as the
nettle in RHEL is too old currently.
If building QEMU with gnutls you won't see the issue as gnutls
doesn't support SM4 cipher at all.
With regards,
Daniel
--
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org -o- https://fstop138.berrange.com :|
|: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
next prev parent reply other threads:[~2024-03-11 10:15 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-07 15:47 [PATCH v6] crypto: Introduce SM4 symmetric cipher algorithm Hyman Huang
2023-12-07 16:02 ` Philippe Mathieu-Daudé
2023-12-08 2:10 ` Yong Huang
2023-12-08 9:33 ` Daniel P. Berrangé
2024-03-08 20:30 ` Thomas Huth
2024-03-11 9:32 ` Daniel P. Berrangé
2024-03-11 10:14 ` Daniel P. Berrangé [this message]
2024-03-11 12:00 ` Thomas Huth
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=Ze7Zomg9YrhvrN2J@redhat.com \
--to=berrange@redhat.com \
--cc=armbru@redhat.com \
--cc=eblake@redhat.com \
--cc=marcandre.lureau@redhat.com \
--cc=pbonzini@redhat.com \
--cc=philmd@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=thuth@redhat.com \
--cc=yong.huang@smartx.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 NNTP newsgroup(s).