qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH for-2.9 v2] crypto: add 3des-ede support when us


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH for-2.9 v2] crypto: add 3des-ede support when using libgcrypt/nettle
Date: Thu, 8 Dec 2016 09:45:13 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.5.1

On 12/07/2016 08:33 PM, Longpeng(Mike) wrote:
> Libgcrypt and nettle support 3des-ede, so this patch add 3des-ede
> support when using libgcrypt or nettle.
> 
> Signed-off-by: Longpeng(Mike) <address@hidden>
> ---

> +++ b/qapi/crypto.json
> @@ -63,6 +63,7 @@
>  # @aes-192: AES with 192 bit / 24 byte keys
>  # @aes-256: AES with 256 bit / 32 byte keys
>  # @des-rfb: RFB specific variant of single DES. Do not use except in VNC.
> +# @3des: 3DES(EDE) with 192 bit / 24 byte keys (since 2.9)
>  # @cast5-128: Cast5 with 128 bit / 16 byte keys
>  # @serpent-128: Serpent with 128 bit / 16 byte keys
>  # @serpent-192: Serpent with 192 bit / 24 byte keys
> @@ -75,7 +76,7 @@
>  { 'enum': 'QCryptoCipherAlgorithm',
>    'prefix': 'QCRYPTO_CIPHER_ALG',
>    'data': ['aes-128', 'aes-192', 'aes-256',
> -           'des-rfb',
> +           'des-rfb', '3des',

Not your fault that this is yet another enum name that is not a valid C
identifier. QAPI at least handles it when referring to the enum constant
(since we already have other such enums, in describing key codes), but
it might make it awkward if we later want to use the enum type as a
discriminator of a flat union (where I'm not sure that QAPI will still
do the right thing).  Is there some name we can pick that starts with a
letter, to reduce the worry?  But if not, I can live with '3des'.


-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]