Segfault when using simple set in named map
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
nftables (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
Considering this minimal example:
```
#!/usr/sbin/nft -f
define l = {
192.168.22.24,
192.168.22.25
}
table t1 {
# the definition of this map causes a segementation fault
map snat_table {
type ipv4_addr : ipv4_addr
flags interval
counter
elements = {
$l : 86.12.22.24
}
}
chain c2 {
type nat hook postrouting priority srcnat;
oif wan1 snat to ip saddr map @snat_table
# while using an anonymous map seems to work fine
oif wan1 snat to ip saddr map {
$l : 86.12.22.24
}
}
}
```
Expected outcome: Either an error that this is syntactically incorrect or that it works in named and anonymous maps
Actual outcome: Segmentation fault
Package name version: 1.0.2-1ubuntu2
OS release: Ubuntu 22.04 LTS
---
ProblemType: Bug
ApportVersion: 2.20.11-0ubuntu82.1
Architecture: amd64
CasperMD5CheckR
DistroRelease: Ubuntu 22.04
InstallationDate: Installed on 2022-06-27 (20 days ago)
InstallationMedia: Ubuntu-Server 22.04 LTS "Jammy Jellyfish" - Release amd64 (20220421)
Package: nftables 1.0.2-1ubuntu2
PackageArchitec
ProcEnviron:
TERM=xterm-
PATH=(custom, no user)
LANG=en_US.UTF-8
SHELL=/bin/bash
ProcVersionSign
RebootRequiredPkgs: Error: path contained symlinks.
Tags: jammy uec-images
Uname: Linux 5.15.0-40-generic x86_64
UpgradeStatus: No upgrade log present (probably fresh install)
UserGroups: N/A
_MarkForUpload: True
modified.
mtime.conffile.
description: | updated |
Thank you for taking the time to report this bug and helping to make Ubuntu better. Please execute the following command only once, as it will automatically gather debugging information, in a terminal:
apport-collect 1981965
When reporting bugs in the future please use apport by using 'ubuntu-bug' and the name of the package affected. You can learn more about this functionality at https:/ /wiki.ubuntu. com/ReportingBu gs.