summaryrefslogtreecommitdiffstats
path: root/src/str_array.c
Commit message (Collapse)AuthorAgeFilesLines
* utils: Add helpers for interface name wildcardsPhil Sutter2025-09-301-3/+7
| | | | | | | | Support simple (suffix) wildcards in NFTNL_{CHAIN,FLOWTABLE}_DEVICES identified by NFTA_DEVICE_PREFIX attribute. Add helpers converting to and from the human-readable asterisk-suffix notation. Signed-off-by: Phil Sutter <phil@nwl.cc>
* Use SPDX License Identifiers in headersPhil Sutter2024-10-301-2/+1
| | | | | | | | | | | | | Replace the copyright notice in header comments by an equivalent SPDX-License-Identifier string. Drop a following empty line if at the bottom of the comment. Leave any other header comment content in place. This also fixes for an incomplete notice in examples/nft-ruleset-get.c since commit c335442eefcca ("src: incorrect header refers to GPLv2 only"). Signed-off-by: Phil Sutter <phil@nwl.cc> Reviewed-by: Pablo Neira Ayuso <pablo@netfilter.org>
* Introduce struct nftnl_str_arrayPhil Sutter2024-10-291-0/+68
This data structure holds an array of allocated strings for use in nftnl_chain and nftnl_flowtable structs. For convenience, implement functions to clear, populate and iterate over contents. While at it, extend chain and flowtable tests to cover these attributes, too. Signed-off-by: Phil Sutter <phil@nwl.cc> Reviewed-by: Pablo Neira Ayuso <pablo@netfilter.org>