Re: [PATCH v7 0/9] Introduce akcipher service for virtio-crypto

2022-05-26 Thread Daniel P . Berrangé
I've sent a pull request containing all the crypto/ changes, as that covers stuff I maintain. ie patches 2-8 Patches 1 and 9, I'll leave for MST to review & queue since the virtual hardware is not my area of knowledge. On Wed, May 25, 2022 at 05:01:09PM +0800, Lei He wrote: > v6 -> v7: > - Fix

Re: [PATCH v6 4/9] crypto: add ASN.1 DER decoder

2022-05-23 Thread Daniel P . Berrangé
On Sat, May 14, 2022 at 08:54:59AM +0800, zhenwei pi wrote: > From: Lei He > > Add an ANS.1 DER decoder which is used to parse asymmetric > cipher keys > > Signed-off-by: zhenwei pi > Signed-off-by: lei he > --- > crypto/der.c | 189 +++ > crypto/der.h

Re: [PATCH v6 7/9] test/crypto: Add test suite for crypto akcipher

2022-05-23 Thread Daniel P . Berrangé
On Sat, May 14, 2022 at 08:55:02AM +0800, zhenwei pi wrote: > From: Lei He > > Add unit test and benchmark test for crypto akcipher. > > Signed-off-by: lei he > Signed-off-by: zhenwei pi > Reviewed-by: Daniel P. Berrangé > --- > tests/bench/benchmark-crypto-akcip

Re: [PATCH v6 5/9] crypto: Implement RSA algorithm by hogweed

2022-05-23 Thread Daniel P . Berrangé
On Sat, May 14, 2022 at 08:55:00AM +0800, zhenwei pi wrote: > From: Lei He > > Implement RSA algorithm by hogweed from nettle. Thus QEMU supports > a 'real' RSA backend to handle request from guest side. It's > important to test RSA offload case without OS & hardware requirement. > >

Re: [PATCH v6 5/9] crypto: Implement RSA algorithm by hogweed

2022-05-23 Thread Daniel P . Berrangé
On Sat, May 14, 2022 at 08:55:00AM +0800, zhenwei pi wrote: > From: Lei He > > Implement RSA algorithm by hogweed from nettle. Thus QEMU supports > a 'real' RSA backend to handle request from guest side. It's > important to test RSA offload case without OS & hardware requirement. > >

Re: [PATCH v6 6/9] crypto: Implement RSA algorithm by gcrypt

2022-05-23 Thread Daniel P . Berrangé
On Sat, May 14, 2022 at 08:55:01AM +0800, zhenwei pi wrote: > From: Lei He > > Added gcryt implementation of RSA algorithm, RSA algorithm > implemented by gcrypt has a higher priority than nettle because > it supports raw padding. > > Signed-off-by: zhenwei pi > Signed-off-by: lei he > --- >

Re: [External] [PATCH v5 5/9] crypto: Implement RSA algorithm by hogweed

2022-05-13 Thread Daniel P . Berrangé
On Fri, May 13, 2022 at 08:26:14PM +0800, 何磊 wrote: > > > > On May 13, 2022, at 6:55 PM, Daniel P. Berrangé wrote: > > > > On Thu, Apr 28, 2022 at 09:59:39PM +0800, zhenwei pi wrote: > >> From: Lei He > >> > >> Implement RSA algorithm by h

Re: [PATCH v5 6/9] crypto: Implement RSA algorithm by gcrypt

2022-05-13 Thread Daniel P . Berrangé
On Thu, Apr 28, 2022 at 09:59:40PM +0800, zhenwei pi wrote: > From: Lei He > > Added gcryt implementation of RSA algorithm, RSA algorithm > implemented by gcrypt has a higher priority than nettle because > it supports raw padding. > > Signed-off-by: lei he > --- > crypto/akcipher-gcrypt.c.inc

Re: [PATCH v5 5/9] crypto: Implement RSA algorithm by hogweed

2022-05-13 Thread Daniel P . Berrangé
On Thu, Apr 28, 2022 at 09:59:39PM +0800, zhenwei pi wrote: > From: Lei He > > Implement RSA algorithm by hogweed from nettle. Thus QEMU supports > a 'real' RSA backend to handle request from guest side. It's > important to test RSA offload case without OS & hardware requirement. > >

Re: [PATCH v5 8/9] tests/crypto: Add test suite for RSA keys

2022-05-13 Thread Daniel P . Berrangé
-crypto-akcipher.c | 285 +- > 1 file changed, 282 insertions(+), 3 deletions(-) Reviewed-by: Daniel P. Berrangé With regards, Daniel -- |: https://berrange.com -o-https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o-https://fstop138.berrange

Re: [PATCH v5 3/9] crypto: Introduce akcipher crypto class

2022-05-12 Thread Daniel P . Berrangé
On Thu, Apr 28, 2022 at 09:59:37PM +0800, zhenwei pi wrote: > Introduce new akcipher crypto class 'QCryptoAkCIpher', which supports > basic asymmetric operations: encrypt, decrypt, sign and verify. > > Suggested by Daniel P. Berrangé, also add autoptr cleanup for the new > class. T

Re: [PATCH v5 1/9] virtio-crypto: header update

2022-05-12 Thread Daniel P . Berrangé
20220302033917.1295334-3-pizhen...@bytedance.com Signed-off-by: Michael S. Tsirkin Reviewed-by: Gonglei And the changes proposed here match that, so Reviewed-by: Daniel P. Berrangé With regards, Daniel -- |: https://berrange.com -o-https://www.flickr.com/photos/dberrange :

Re: [PATCH v5 4/9] crypto: add ASN.1 DER decoder

2022-05-12 Thread Daniel P . Berrangé
On Thu, Apr 28, 2022 at 09:59:38PM +0800, zhenwei pi wrote: > From: Lei He > > Add an ANS.1 DER decoder which is used to parse asymmetric > cipher keys > > Signed-off-by: zhenwei pi > Signed-off-by: lei he > --- > crypto/der.c | 190 +++ > crypto/der.h

Re: [PATCH v5 7/9] test/crypto: Add test suite for crypto akcipher

2022-05-12 Thread Daniel P . Berrangé
On Thu, Apr 28, 2022 at 09:59:41PM +0800, zhenwei pi wrote: > From: Lei He > > Add unit test and benchmark test for crypto akcipher. > > Signed-off-by: lei he > Signed-off-by: zhenwei pi > Reviewed-by: Daniel P. Berrangé > --- > tests/bench/benchmark-crypto-akcip

Re: [PATCH v4 7/8] tests/crypto: Add test suite for crypto akcipher

2022-04-26 Thread Daniel P . Berrangé
file in the top-level directory. > + * > + * Author: lei he > + */ > + > +/* RSA test keys, generated by OpenSSL */ > +static const uint8_t rsa1024_priv_key[] = { > +0x30, 0x82, 0x02, 0x5c, 0x02, 0x01, 0x00, 0x02, > + 0x81, 0x81, 0x00, 0xe6, 0x4d, 0x76, 0x4f, 0xb2,

Re: [PATCH v4 6/8] crypto: Implement RSA algorithm by gcrypt

2022-04-26 Thread Daniel P . Berrangé
On Mon, Apr 11, 2022 at 06:43:25PM +0800, zhenwei pi wrote: > From: Lei He > > Added gcryt implementation of RSA algorithm, RSA algorithm > implemented by gcrypt has a higher priority than nettle because > it supports raw padding. > > Signed-off-by: Lei He > --- > crypto/akcipher-gcrypt.c.inc

Re: [PATCH v4 5/8] crypto: Implement RSA algorithm by hogweed

2022-04-26 Thread Daniel P . Berrangé
On Mon, Apr 11, 2022 at 06:43:24PM +0800, zhenwei pi wrote: > From: Lei He > > Implement RSA algorithm by hogweed from nettle. Thus QEMU supports > a 'real' RSA backend to handle request from guest side. It's > important to test RSA offload case without OS & hardware requirement. > >

Re: [PATCH v4 4/8] crypto: add ASN.1 decoder

2022-04-26 Thread Daniel P . Berrangé
On Mon, Apr 11, 2022 at 06:43:23PM +0800, zhenwei pi wrote: > From: Lei He > > Add an ANS.1 decoder which is used to parse asymmetric > cipher keys > > Signed-off-by: zhenwei pi > Signed-off-by: Lei He > --- > crypto/asn1_decoder.c | 161 ++ >

Re: [PATCH v4 3/8] crypto: Introduce akcipher crypto class

2022-04-26 Thread Daniel P . Berrangé
On Mon, Apr 11, 2022 at 06:43:22PM +0800, zhenwei pi wrote: > Support basic asymmetric operations: encrypt, decrypt, sign and > verify. > > Co-developed-by: lei he > Signed-off-by: lei he > Signed-off-by: zhenwei pi > --- > crypto/akcipher.c | 102 + >

Re: [PATCH v4 2/8] crypto-akcipher: Introduce akcipher types to qapi

2022-04-26 Thread Daniel P . Berrangé
> + 'base': { 'algorithm': 'QCryptoAkCipherAlgorithm' }, > + 'discriminator': 'algorithm', > + 'data': { 'rsa': 'QCryptoAkCipherOptionsRSA' }} I mistakenly suggested 'algorithm' here, but for consistency with other fields, I should have said just 'alg'. With that change Revie

Re: PING: [PATCH v4 0/8] Introduce akcipher service for virtio-crypto

2022-04-21 Thread Daniel P . Berrangé
On Thu, Apr 21, 2022 at 09:41:40AM +0800, zhenwei pi wrote: > Hi Daniel, > Could you please review this series? Yes, its on my to do. I've been on holiday for 2 weeks, so still catching up on the backlog of reviews. > On 4/11/22 18:43, zhenwei pi wrote: > > v3 -> v4: > > - Coding style fix:

Re: [Spice-devel] 回复: Re: 回复: Re: 回复: Re: 回复: Re: [PATCH v1 1/2] drm/qxl: replace ioremap by ioremap_cache on arm64

2022-03-24 Thread Daniel P . Berrangé
On Thu, Mar 24, 2022 at 02:21:09PM +0100, Gerd Hoffmann wrote: > On Thu, Mar 24, 2022 at 06:34:02PM +0800, liuco...@kylinos.cn wrote: > >ok, thanks, a lot of our customer use qxl on x86 before, so it still need > >to supoort qxl on arm64. > > Well, qxl isn't the best choice even on x86.

Re: [PATCH v3 1/6] virtio-crypto: header update

2022-03-23 Thread Daniel P . Berrangé
On Wed, Mar 23, 2022 at 10:49:07AM +0800, zhenwei pi wrote: > Update header from linux, support akcipher service. I'm assuming this is updated for *non-merged* Linux headers, since I don't see these changes present in current linux.git > > Reviewed-by: Gonglei > Signed-off-by: lei he >

Re: [PATCH v3 5/6] tests/crypto: Add test suite for crypto akcipher

2022-03-23 Thread Daniel P . Berrangé
On Wed, Mar 23, 2022 at 10:49:11AM +0800, zhenwei pi wrote: > From: Lei He > > Add unit test and benchmark test for crypto akcipher. > > Signed-off-by: lei he > Signed-off-by: zhenwei pi > --- > tests/bench/benchmark-crypto-akcipher.c | 163 ++ > tests/bench/meson.build |

Re: [PATCH v3 2/6] crypto-akcipher: Introduce akcipher types to qapi

2022-03-23 Thread Daniel P . Berrangé
On Wed, Mar 23, 2022 at 10:49:08AM +0800, zhenwei pi wrote: > From: Lei He > > Introduce akcipher types, also include RSA & ECDSA related types. > > Signed-off-by: Lei He > Signed-off-by: zhenwei pi > --- > qapi/crypto.json | 86 > 1 file

Re: [PATCH v3 4/6] crypto: Implement RSA algorithm by hogweed

2022-03-23 Thread Daniel P . Berrangé
On Wed, Mar 23, 2022 at 10:49:10AM +0800, zhenwei pi wrote: > From: Lei He > > Introduce ASN.1 decoder, and implement RSA algorithm by hogweed > from nettle. Thus QEMU supports a 'real' RSA backend to handle > request from guest side. It's important to test RSA offload case > without OS &

Re: [PATCH v3 3/6] crypto: Introduce akcipher crypto class

2022-03-23 Thread Daniel P . Berrangé
On Wed, Mar 23, 2022 at 10:49:09AM +0800, zhenwei pi wrote: > Support basic asymmetric operations: encrypt, decrypt, sign and > verify. > > Co-developed-by: lei he > Signed-off-by: lei he > Signed-off-by: zhenwei pi > --- > crypto/akcipher.c | 78 + >

Re: [PATCH v3 2/6] crypto-akcipher: Introduce akcipher types to qapi

2022-03-23 Thread Daniel P . Berrangé
On Wed, Mar 23, 2022 at 10:49:08AM +0800, zhenwei pi wrote: > From: Lei He > > Introduce akcipher types, also include RSA & ECDSA related types. > > Signed-off-by: Lei He > Signed-off-by: zhenwei pi > --- > qapi/crypto.json | 86 > 1 file