From: David Miller <davem@davemloft.net>
To: kristian.evensen@gmail.com
Cc: netdev@vger.kernel.org
Subject: Re: [PATCH net-next] inet_diag: Add equal-operator for ports
Date: Tue, 02 Jan 2018 13:54:23 -0500 (EST) [thread overview]
Message-ID: <20180102.135423.1243941734307734099.davem@davemloft.net> (raw)
In-Reply-To: <20171227172758.7241-1-kristian.evensen@gmail.com>
From: Kristian Evensen <kristian.evensen@gmail.com>
Date: Wed, 27 Dec 2017 18:27:58 +0100
> inet_diag currently provides less/greater than or equal operators for
> comparing ports when filtering sockets. An equal comparison can be
> performed by combining the two existing operators, or a user can for
> example request a port range and then do the final filtering in
> userspace. However, these approaches both have drawbacks. Implementing
> equal using LE/GE causes the size and complexity of a filter to grow
> quickly as the number of ports increase, while it on busy machines would
> be great if the kernel only returns information about relevant sockets.
>
> This patch introduces source and destination port equal operators.
> INET_DIAG_BC_S_EQ is used to match a source port, INET_DIAG_BC_D_EQ a
> destination port, and usage is the same as for the existing port
> operators. I.e., the port to match is stored in the no-member of the
> next inet_diag_bc_op-struct in the filter.
>
> Signed-off-by: Kristian Evensen <kristian.evensen@gmail.com>
Applied, thank you.
prev parent reply other threads:[~2018-01-02 18:54 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-27 17:27 [PATCH net-next] inet_diag: Add equal-operator for ports Kristian Evensen
2018-01-02 18:54 ` David Miller [this message]
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=20180102.135423.1243941734307734099.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=kristian.evensen@gmail.com \
--cc=netdev@vger.kernel.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