<html>
<head>
<base href="https://bugzilla.netfilter.org/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - Feature request: Negated set elements in interval sets, as with ipset nomatch"
href="https://bugzilla.netfilter.org/show_bug.cgi?id=1504">1504</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Feature request: Negated set elements in interval sets, as with ipset nomatch
</td>
</tr>
<tr>
<th>Product</th>
<td>nftables
</td>
</tr>
<tr>
<th>Version</th>
<td>unspecified
</td>
</tr>
<tr>
<th>Hardware</th>
<td>All
</td>
</tr>
<tr>
<th>OS</th>
<td>All
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>enhancement
</td>
</tr>
<tr>
<th>Priority</th>
<td>P5
</td>
</tr>
<tr>
<th>Component</th>
<td>nft
</td>
</tr>
<tr>
<th>Assignee</th>
<td>pablo@netfilter.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>fmyhr@fhmtech.com
</td>
</tr></table>
<p>
<div>
<pre>It would be useful to be able to add negated elements (those that are
explicitly excluded from the set) to interval sets, as with the nomatch keyword
using ipset.
For example, I have an interval set 'harsh' of ipv4 address blocks that get
filtered more severely than most. But there are a few hosts within some of the
elements that I want to subject to my normal policy instead. I do this now by
creating a second set 'harsh-' for the exceptions and using a rule like
ip saddr @harsh ip saddr != @harsh- jump harsh_chain
If nftables had negated elements then I could eliminate the harsh- set and the
2nd expression in the above rule.
Even though this change may not appear to be a major benefit as far as nftables
itself is concerned, it would make maintaining such a 'harsh' (or similar) set
much easier. For now I maintain such lists as a single 'base list' in my own
syntax (using ! for negated elements), and use scripts to translate this base
list into 'positive' and 'negative' nft sets, and to transform nft expressions
using base sets (with my custom '~' operator) into the expression pair in the
above example. This works but is slow and clunky in addition to using the
non-standard syntax.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are watching all bug changes.</li>
</ul>
</body>
</html>