DPDK patches and discussions
 help / color / mirror / Atom feed
From: Konstantin Ananyev <konstantin.ananyev@intel.com>
To: dev@dpdk.org
To: dev@dpdk.org
Cc: Konstantin Ananyev <konstantin.ananyev@intel.com>
Subject: [dpdk-dev] [PATCH 0/3] bpf: extend validation of input BPF programs
Date: Fri,  8 Jun 2018 09:42:32 +0100	[thread overview]
Message-ID: <1528447355-29411-1-git-send-email-konstantin.ananyev@intel.com> (raw)

As first step extend struct rte_bpf_xsym with new fields to provide
extra information for allowed external varaibles and helper functions.
That allows to extend bpf validation with new checks for:
 - use/return uninitialized registers and/or stack data
 - possible memory access boundaries violation
 - invalid arguments for the function

Konstantin Ananyev (3):
  bpf: add extra information for external symbol definitions
  bpf: add extra validation for input BPF program
  test/bpf: add new test-case for external function call

 app/test-pmd/bpf_cmd.c        |   27 +-
 lib/librte_bpf/bpf_def.h      |    5 +
 lib/librte_bpf/bpf_exec.c     |    2 +-
 lib/librte_bpf/bpf_impl.h     |   14 +
 lib/librte_bpf/bpf_jit_x86.c  |   17 +-
 lib/librte_bpf/bpf_load.c     |   49 +-
 lib/librte_bpf/bpf_load_elf.c |    4 +-
 lib/librte_bpf/bpf_validate.c | 1136 +++++++++++++++++++++++++++++++++++++++--
 lib/librte_bpf/rte_bpf.h      |   21 +-
 test/test/test_bpf.c          |  169 +++++-
 10 files changed, 1382 insertions(+), 62 deletions(-)

-- 
2.13.6

             reply	other threads:[~2018-06-08  8:42 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-06-08  8:42 Konstantin Ananyev [this message]
2018-06-08  8:42 ` [dpdk-dev] [PATCH 1/3] bpf: add extra information for external symbol definitions Konstantin Ananyev
2018-06-08  8:42 ` [dpdk-dev] [PATCH 2/3] bpf: add extra validation for input BPF program Konstantin Ananyev
2018-06-08  8:42 ` [dpdk-dev] [PATCH 3/3] test/bpf: add new test-case for external function call Konstantin Ananyev
2018-07-12  7:46 ` [dpdk-dev] [PATCH 0/3] bpf: extend validation of input BPF programs Thomas Monjalon

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=1528447355-29411-1-git-send-email-konstantin.ananyev@intel.com \
    --to=konstantin.ananyev@intel.com \
    --cc=dev@dpdk.org \
    /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).