lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:   Thu,  7 Nov 2019 18:42:08 +0200
From:   Ido Schimmel <idosch@...sch.org>
To:     netdev@...r.kernel.org
Cc:     davem@...emloft.net, jiri@...lanox.com, amitc@...lanox.com,
        dsahern@...il.com, mlxsw@...lanox.com,
        Ido Schimmel <idosch@...lanox.com>
Subject: [PATCH net-next 00/12] mlxsw: Add layer 3 devlink-trap support

From: Ido Schimmel <idosch@...lanox.com>

This patch set from Amit adds support in mlxsw for layer 3 traps that
can report drops and exceptions via devlink-trap.

In a similar fashion to the existing layer 2 traps, these traps can send
packets to the CPU that were not routed as intended by the underlying
device.

The traps are divided between the two types detailed in devlink-trap
documentation: drops and exceptions. Unlike drops, packets received via
exception traps are also injected to the kernel's receive path, as they
are required for the correct functioning of the control plane. For
example, packets trapped due to TTL error must be injected to kernel's
receive path for traceroute to work properly.

Patch set overview:

Patch #1 adds the layer 3 drop traps to devlink along with their
documentation.

Patch #2 adds support for layer 3 drop traps in mlxsw.

Patches #3-#5 add selftests for layer 3 drop traps.

Patch #6 adds the layer 3 exception traps to devlink along with their
documentation.

Patches #7-#9 gradually add support for layer 3 exception traps in
mlxsw.

Patches #10-#12 add selftests for layer 3 exception traps.

Amit Cohen (12):
  devlink: Add layer 3 generic packet traps
  mlxsw: Add layer 3 devlink-trap support
  selftests: devlink: Export functions to devlink library
  selftests: devlink: Make devlink_trap_cleanup() more generic
  selftests: mlxsw: Add test cases for devlink-trap layer 3 drops
  devlink: Add layer 3 generic packet exception traps
  mlxsw: Add new FIB entry type for reject routes
  mlxsw: Add specific trap for packets routed via invalid nexthops
  mlxsw: Add layer 3 devlink-trap exceptions support
  selftests: forwarding: devlink: Add functionality for trap exceptions
    test
  selftests: forwarding: tc_common: Add hitting check
  selftests: mlxsw: Add test cases for devlink-trap layer 3 exceptions

 Documentation/networking/devlink-trap.rst     |  61 ++
 drivers/net/ethernet/mellanox/mlxsw/reg.h     |   1 +
 .../net/ethernet/mellanox/mlxsw/spectrum.c    |   5 -
 .../ethernet/mellanox/mlxsw/spectrum_router.c |  61 +-
 .../ethernet/mellanox/mlxsw/spectrum_trap.c   | 100 ++++
 drivers/net/ethernet/mellanox/mlxsw/trap.h    |  15 +
 include/net/devlink.h                         |  45 ++
 net/core/devlink.c                            |  15 +
 .../net/mlxsw/devlink_trap_l2_drops.sh        |  68 +--
 .../net/mlxsw/devlink_trap_l3_drops.sh        | 563 ++++++++++++++++++
 .../net/mlxsw/devlink_trap_l3_exceptions.sh   | 557 +++++++++++++++++
 .../selftests/net/forwarding/devlink_lib.sh   |  55 ++
 .../selftests/net/forwarding/tc_common.sh     |  11 +
 13 files changed, 1496 insertions(+), 61 deletions(-)
 create mode 100755 tools/testing/selftests/drivers/net/mlxsw/devlink_trap_l3_drops.sh
 create mode 100755 tools/testing/selftests/drivers/net/mlxsw/devlink_trap_l3_exceptions.sh

-- 
2.21.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ