<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 - Segfault when resetting rules with meta l4proto { tcp, udp }"
href="https://bugzilla.netfilter.org/show_bug.cgi?id=1763">1763</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Segfault when resetting rules with meta l4proto { tcp, udp }
</td>
</tr>
<tr>
<th>Product</th>
<td>nftables
</td>
</tr>
<tr>
<th>Version</th>
<td>1.0.x
</td>
</tr>
<tr>
<th>Hardware</th>
<td>x86_64
</td>
</tr>
<tr>
<th>OS</th>
<td>Ubuntu
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>minor
</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>sly@covertlabs.org
</td>
</tr></table>
<p>
<div>
<pre>Running into a segfault on version 1.0.9 when rules are listed after `nft reset
rules` with a `meta l4proto { tcp, udp } ...` rule added but listing the same
rule works fine. It seems to have problems with the `{ tcp, udp }` set.
# nft create table testsegfault
# nft add chain testsegfault dns-nat-pre "{ type nat hook prerouting priority
0; }"
# nft add rule testsegfault dns-nat-pre meta l4proto { tcp, udp } th dport 53
ip saddr 10.24.0.0/24 ip daddr != 10.25.0.1 counter dnat to 10.25.0.1
# nft list ruleset
table ip testsegfault {
chain dns-nat-pre {
type nat hook prerouting priority filter; policy accept;
meta l4proto { tcp, udp } th dport 53 ip saddr 10.24.0.0/24 ip
daddr != 10.25.0.1 counter packets 0 bytes 0 dnat to 10.25.0.1
}
}
# nft reset rules
table ip testsegfault {
chain dns-nat-pre {
type nat hook prerouting priority filter; policy accept;
meta l4proto Segmentation fault (core dumped)
I also tried a simplified version of the above rule to ensure it wasn't
something further in the rule causing issues and ran into the same segfault.
# nft create table testsegfault
# nft add chain testsegfault dns-nat-pre "{ type nat hook prerouting priority
0; }"
# nft add rule testsegfault dns-nat-pre meta l4proto { tcp, udp } th dport 53
counter dnat to 10.25.0.1
# nft list ruleset
table ip testsegfault {
chain dns-nat-pre {
type nat hook prerouting priority filter; policy accept;
meta l4proto { tcp, udp } th dport 53 counter packets 0 bytes 0
dnat to 10.25.0.1
}
}
# nft reset rules
table ip testsegfault {
chain dns-nat-pre {
type nat hook prerouting priority filter; policy accept;
meta l4proto Segmentation fault (core dumped)
This is on an AWS Ubuntu 24.04 EC2 instance.
# uname -rvp
6.8.0-1012-aws #13-Ubuntu SMP Mon Jul 15 13:40:27 UTC 2024 x86_64</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are watching all bug changes.</li>
</ul>
</body>
</html>