From: Thomas Haller <thaller@redhat.com>
To: NetFilter <netfilter-devel@vger.kernel.org>
Cc: Thomas Haller <thaller@redhat.com>
Subject: [PATCH nft 1/3] tests/shell: add "bogons/nft-f/zero_length_devicename2_assert"
Date: Mon, 23 Oct 2023 19:00:45 +0200 [thread overview]
Message-ID: <20231023170058.919275-1-thaller@redhat.com> (raw)
This is copied from "bogons/nft-f/zero_length_devicename_assert" and
adjusted.
- `device""lo"` looks odd. In this file use `device ""` to only check
against empty strings, without oddity.
- "ip" type has no hook ingress in filter. If the device name would be
valid, the file would still be rejected. Use "netdev".
The purpose is to add a test for a file that would otherwise pass,
except having an empty device name. Without oddities.
Signed-off-by: Thomas Haller <thaller@redhat.com>
---
.../testcases/bogons/nft-f/zero_length_devicename2_assert | 5 +++++
1 file changed, 5 insertions(+)
create mode 100644 tests/shell/testcases/bogons/nft-f/zero_length_devicename2_assert
diff --git a/tests/shell/testcases/bogons/nft-f/zero_length_devicename2_assert b/tests/shell/testcases/bogons/nft-f/zero_length_devicename2_assert
new file mode 100644
index 000000000000..fe416f8536e9
--- /dev/null
+++ b/tests/shell/testcases/bogons/nft-f/zero_length_devicename2_assert
@@ -0,0 +1,5 @@
+table netdev x {
+ chain Main_Ingress1 {
+ type filter hook ingress device "" priority -1
+ }
+}
--
2.41.0
next reply other threads:[~2023-10-23 17:03 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-23 17:00 Thomas Haller [this message]
2023-10-23 17:00 ` [PATCH nft 2/3] tests/shell: cover long interface name in "0042chain_variable_0" test Thomas Haller
2023-10-23 17:00 ` [PATCH nft 3/3] parser_bison: fix length check for ifname in ifname_expr_alloc() Thomas Haller
2023-10-23 17:15 ` Pablo Neira Ayuso
2023-10-23 17:16 ` Pablo Neira Ayuso
2023-10-23 17:33 ` Thomas Haller
2023-10-24 9:57 ` [PATCH nft 1/3] tests/shell: add "bogons/nft-f/zero_length_devicename2_assert" Pablo Neira Ayuso
2023-10-24 10:15 ` Thomas Haller
2023-10-24 10:24 ` Pablo Neira Ayuso
2023-10-24 10:29 ` Florian Westphal
2023-10-24 10:43 ` Pablo Neira Ayuso
2023-10-24 11:50 ` Phil Sutter
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=20231023170058.919275-1-thaller@redhat.com \
--to=thaller@redhat.com \
--cc=netfilter-devel@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;
as well as URLs for NNTP newsgroup(s).