Linux kernel source tree
Go to file
Ido Schimmel f0e7036fc9 ipv4: icmp: Add RFC 5837 support
Add the ability to append the incoming IP interface information to
ICMPv4 error messages in accordance with RFC 5837 and RFC 4884. This is
required for more meaningful traceroute results in unnumbered networks.

The feature is disabled by default and controlled via a new sysctl
("net.ipv4.icmp_errors_extension_mask") which accepts a bitmask of ICMP
extensions to append to ICMP error messages. Currently, only a single
value is supported, but the interface and the implementation should be
able to support more extensions, if needed.

Clone the skb and copy the relevant data portions before modifying the
skb as the caller of __icmp_send() still owns the skb after the function
returns. This should be fine since by default ICMP error messages are
rate limited to 1000 per second and no more than 1 per second per
specific host.

Trim or pad the packet to 128 bytes before appending the ICMP extension
structure in order to be compatible with legacy applications that assume
that the ICMP extension structure always starts at this offset (the
minimum length specified by RFC 4884).

Reviewed-by: Petr Machata <petrm@nvidia.com>
Reviewed-by: David Ahern <dsahern@kernel.org>
Reviewed-by: Willem de Bruijn <willemb@google.com>
Signed-off-by: Ido Schimmel <idosch@nvidia.com>
Reviewed-by: Eric Dumazet <edumazet@google.com>
Link: https://patch.msgid.link/20251027082232.232571-2-idosch@nvidia.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2025-10-29 18:28:29 -07:00
arch 17 hotfixes. 12 are cc:stable and 14 are for MM. 2025-10-22 14:57:35 -10:00
block block-6.18-20251016 2025-10-17 08:31:26 -07:00
certs
crypto
Documentation ipv4: icmp: Add RFC 5837 support 2025-10-29 18:28:29 -07:00
drivers net: stmmac: reorganise stmmac_hwif_init() 2025-10-29 17:18:23 -07:00
fs for-6.18-rc2-tag 2025-10-23 06:44:43 -10:00
include ipv4: icmp: Add RFC 5837 support 2025-10-29 18:28:29 -07:00
init
io_uring io_uring/rw: check for NULL io_br_sel when putting a buffer 2025-10-15 13:38:53 -06:00
ipc
kernel 17 hotfixes. 12 are cc:stable and 14 are for MM. 2025-10-22 14:57:35 -10:00
lib
LICENSES
mm 17 hotfixes. 12 are cc:stable and 14 are for MM. 2025-10-22 14:57:35 -10:00
net ipv4: icmp: Add RFC 5837 support 2025-10-29 18:28:29 -07:00
rust rust: bitmap: fix formatting 2025-10-17 13:02:22 +02:00
samples
scripts
security
sound ALSA: hda/realtek: Fix mute led for HP Omen 17-cb0xxx 2025-10-17 16:37:21 +02:00
tools selftest: net: fix socklen_t type mismatch in sctp_collision test 2025-10-29 17:39:26 -07:00
usr
virt KVM x86 fixes for 6.18: 2025-10-18 10:25:43 +02:00
.clang-format
.clippy.toml
.cocciconfig
.editorconfig
.get_maintainer.ignore
.gitattributes
.gitignore
.mailmap MAINTAINERS: Update Alex Williamson's email address 2025-10-20 15:45:03 -06:00
.pylintrc
.rustfmt.toml
COPYING
CREDITS
Kbuild
Kconfig
MAINTAINERS MAINTAINERS: add dwmac-rk glue driver to the main Rockchip entry 2025-10-24 19:07:37 -07:00
Makefile Linux 6.18-rc2 2025-10-19 15:19:16 -10:00
README

Linux kernel
============

There are several guides for kernel developers and users. These guides can
be rendered in a number of formats, like HTML and PDF. Please read
Documentation/admin-guide/README.rst first.

In order to build the documentation, use ``make htmldocs`` or
``make pdfdocs``.  The formatted documentation can also be read online at:

    https://www.kernel.org/doc/html/latest/

There are various text files in the Documentation/ subdirectory,
several of them using the reStructuredText markup notation.

Please read the Documentation/process/changes.rst file, as it contains the
requirements for building and running the kernel, and information about
the problems which may result by upgrading your kernel.