meta: introduce time/day/hour matching
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest4 patches 4 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/4 | evaluate: New internal helper __expr_evaluate_rangesrc/ | +16 | 0 replies | |
| 2/4 | meta: Introduce new conditions 'time', 'day' and 'hour'doc/ doc/ include/ +10 more | +390 | 0 replies | |
| 3/4 | tests: add meta time test casestests/ tests/ tests/ +1 more | +559 | 4 replies | |
| 4/4 | src: evaluate: catch invalid 'meta day' values in eval stepsrc/ tests/ | +17 | 0 replies |
Reviews trailers per patch
1 of 4 patches has a Reviewed-by or Acked-by.
| Patch | Florian Westphal |
|---|---|
| 1/4 | |
| 2/4 | R-b |
| 3/4 | |
| 4/4 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH nft 0/4] meta: introduce time/day/hour matching
Hi.
This series contains the changes that I plan to apply to nftables.git soon to get the 'time' matching feature in.
First patch is unchanged, second patch has the tests removed and replaces 'day' parsing with one that is based on the symbol table infra we already have. This means 'nft describe meta day' will now print all days plus their numeric value.
Third patch contains the test cases, I've moved them to 'any' because time matching isn't ip specific.
Last match adds a patch to catch invalid days during eval step.
Ander Juaristi (3):
evaluate: New internal helper __expr_evaluate_range
meta: Introduce new conditions 'time', 'day' and 'hour'
tests: add meta time test cases
Florian Westphal (1):
src: evaluate: catch invalid 'meta day' values in eval step
doc/nft.txt | 6 doc/primary-expression.txt | 27 +++ include/datatype.h | 6 include/linux/netfilter/nf_tables.h | 6 include/meta.h | 3 include/nftables.h | 5 include/nftables/libnftables.h | 1 src/datatype.c | 3 src/evaluate.c | 91 +++++++++++- src/main.c | 12 + src/meta.c | 261 ++++++++++++++++++++++++++++++++++++ src/parser_bison.y | 9 + src/scanner.l | 1 tests/py/any/meta.t | 19 ++ tests/py/any/meta.t.json | 233 ++++++++++++++++++++++++++++++++ tests/py/any/meta.t.json.output | 234 ++++++++++++++++++++++++++++++++ tests/py/any/meta.t.payload | 77 ++++++++++ 17 files changed, 982 insertions(+), 12 deletions(-)