DPDK patches and discussions
 help / color / mirror / Atom feed
From: Pablo de Lara <pablo.de.lara.guarch@intel.com>
To: declan.doherty@intel.com, fiona.trahe@intel.com,
	john.griffin@intel.com, deepak.k.jain@intel.com
Cc: dev@dpdk.org, Pablo de Lara <pablo.de.lara.guarch@intel.com>
Subject: [dpdk-dev] [PATCH 5/5] doc: extend installation section on SNOW3G/KASUMI PMDs
Date: Thu, 13 Jul 2017 06:36:50 +0100	[thread overview]
Message-ID: <20170713053650.62998-6-pablo.de.lara.guarch@intel.com> (raw)
In-Reply-To: <20170713053650.62998-1-pablo.de.lara.guarch@intel.com>

SNOW3G and KASUMI SW libraries encrypt buffers
assuming that they are padded to a specific block size.
This behaviour can be changed to avoid buffer overflow,
by modifying the Makefile of these libraries.
Therefore, the Installation section in the SNOW3G and
KASUMI documentation has been extended, to document
this case.

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 doc/guides/cryptodevs/kasumi.rst | 12 ++++++++++++
 doc/guides/cryptodevs/snow3g.rst | 11 +++++++++++
 2 files changed, 23 insertions(+)

diff --git a/doc/guides/cryptodevs/kasumi.rst b/doc/guides/cryptodevs/kasumi.rst
index bff9321..738ecee 100644
--- a/doc/guides/cryptodevs/kasumi.rst
+++ b/doc/guides/cryptodevs/kasumi.rst
@@ -70,6 +70,18 @@ on their system before building DPDK::
 
    make
 
+**Note**: When encrypting with KASUMI F8, by default the library
+encrypts full blocks of 8 bytes, regardless the number of bytes to
+be encrypted provided (which leads to a possible buffer overflow).
+To avoid this situation, it is necessary not to pass
+3GPP_SAFE_BUFFERS as a compilation flag.
+Also, this is required when using chained operations
+(cipher-then-auth/auth-then-cipher).
+For this, in the Makefile of the library, make sure that this flag
+is commented out::
+
+  #EXTRA_CFLAGS  += -D_3GPP_SAFE_BUFFERS
+
 **Note**: To build the PMD as a shared library, the libsso_kasumi
 library must be built as follows::
 
diff --git a/doc/guides/cryptodevs/snow3g.rst b/doc/guides/cryptodevs/snow3g.rst
index 12b6c4a..41c48d6 100644
--- a/doc/guides/cryptodevs/snow3g.rst
+++ b/doc/guides/cryptodevs/snow3g.rst
@@ -69,6 +69,17 @@ on their system before building DPDK::
 
    make snow3G
 
+**Note**: When encrypting with SNOW3G UEA2, by default the library
+encrypts blocks of 4 bytes, regardless the number of bytes to
+be encrypted provided (which leads to a possible buffer overflow).
+To avoid this situation, it is necessary not to pass
+3GPP_SAFE_BUFFERS as a compilation flag.
+For this, in the Makefile of the library, make sure that this flag
+is commented out.::
+
+  #EXTRA_CFLAGS  += -D_3GPP_SAFE_BUFFERS
+
+
 Initialization
 --------------
 
-- 
2.9.4

  parent reply	other threads:[~2017-07-13 13:37 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-07-13  5:36 [dpdk-dev] [PATCH 0/5] Fix crypto PMDs documentation Pablo de Lara
2017-07-13  5:36 ` [dpdk-dev] [PATCH 1/5] doc: fix supported algorithm table for AESNI GCM PMD Pablo de Lara
2017-07-13  5:36 ` [dpdk-dev] [PATCH 2/5] doc: remove incorrect limitation on QAT PMD Pablo de Lara
2017-07-14 15:58   ` Trahe, Fiona
2017-07-13  5:36 ` [dpdk-dev] [PATCH 3/5] doc: remove incorrect limitation on AESNI MB PMD Pablo de Lara
2017-07-13  5:36 ` [dpdk-dev] [PATCH 4/5] doc: add missing algorithm in limitations for QAT Pablo de Lara
2017-07-14 16:13   ` Trahe, Fiona
2017-07-13  5:36 ` Pablo de Lara [this message]
2017-07-13 17:00 ` [dpdk-dev] [PATCH 0/5] Fix crypto PMDs documentation Declan Doherty
2017-07-16 10:52 ` De Lara Guarch, Pablo

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=20170713053650.62998-6-pablo.de.lara.guarch@intel.com \
    --to=pablo.de.lara.guarch@intel.com \
    --cc=declan.doherty@intel.com \
    --cc=deepak.k.jain@intel.com \
    --cc=dev@dpdk.org \
    --cc=fiona.trahe@intel.com \
    --cc=john.griffin@intel.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).