[dpdk-dev] [PATCH] crypto/openssl: fix out-of-place encryption

De Lara Guarch, Pablo pablo.de.lara.guarch at intel.com
Thu Apr 16 10:52:48 CEST 2020



> -----Original Message-----
> From: dev <dev-bounces at dpdk.org> On Behalf Of Akhil Goyal
> Sent: Wednesday, April 15, 2020 8:23 PM
> To: De Lara Guarch, Pablo <pablo.de.lara.guarch at intel.com>; Doherty, Declan
> <declan.doherty at intel.com>
> Cc: Zhang, Roy Fan <roy.fan.zhang at intel.com>; dev at dpdk.org;
> akhil.goyal at intel.com; stable at dpdk.org
> Subject: Re: [dpdk-dev] [PATCH] crypto/openssl: fix out-of-place encryption
> 
> Hi Pablo,
> 
> > When authenticating after encrypting, if the operation is
> > out-of-place, the destination buffer is the one that will get
> > authenticated.
> > If the cipher offset is higher than the authentication offset, it
> > means that part of the text to authenticate will be plaintext, so this
> > needs to get copied to the destination buffer, or the result will be
> > incorrect.
> >
> > Fixes: d61f70b4c918 ("crypto/libcrypto: add driver for OpenSSL
> > library")
> > Cc: stable at dpdk.org
> >
> > Signed-off-by: Pablo de Lara <pablo.de.lara.guarch at intel.com>
> 
> Do we have a test case in app/test for this case? If not, we should probably add
> it.

Hi Akhil,

Yes, we do. In test_cryptodev_aes_test_vectors.h, the "AES-128-CBC HMAC-SHA1 Encryption Digest OOP Offset"
is testing this case, in aes_chain_test_cases[].

Thanks,
Pablo


More information about the dev mailing list