* [PATCH 1/2 nft] src: json: fix synproxy flag parser typo
@ 2019-07-17 10:46 Fernando Fernandez Mancera
2019-07-17 10:46 ` [PATCH 2/2 nft] tests: py: add missing json outputs Fernando Fernandez Mancera
2019-07-17 11:41 ` [PATCH 1/2 nft] src: json: fix synproxy flag parser typo Pablo Neira Ayuso
0 siblings, 2 replies; 4+ messages in thread
From: Fernando Fernandez Mancera @ 2019-07-17 10:46 UTC (permalink / raw)
To: netfilter-devel; +Cc: Fernando Fernandez Mancera
Signed-off-by: Fernando Fernandez Mancera <ffmancera@riseup.net>
---
src/parser_json.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/src/parser_json.c b/src/parser_json.c
index 42893c2..76c0a5c 100644
--- a/src/parser_json.c
+++ b/src/parser_json.c
@@ -2197,7 +2197,7 @@ static int json_parse_synproxy_flag(struct json_ctx *ctx,
assert(flags);
if (!json_is_string(root)) {
- json_error(ctx, "Invalid log flag type %s, expected string.",
+ json_error(ctx, "Invalid synproxy flag type %s, expected string.",
json_typename(root));
return 1;
}
@@ -2208,7 +2208,7 @@ static int json_parse_synproxy_flag(struct json_ctx *ctx,
return 0;
}
}
- json_error(ctx, "Unknown log flag '%s'.", flag);
+ json_error(ctx, "Unknown synproxy flag '%s'.", flag);
return 1;
}
@@ -2222,13 +2222,13 @@ static int json_parse_synproxy_flags(struct json_ctx *ctx, json_t *root)
json_parse_synproxy_flag(ctx, root, &flags);
return flags;
} else if (!json_is_array(root)) {
- json_error(ctx, "Invalid log flags type %s.",
+ json_error(ctx, "Invalid synproxy flags type %s.",
json_typename(root));
return -1;
}
json_array_foreach(root, index, value) {
if (json_parse_synproxy_flag(ctx, value, &flags))
- json_error(ctx, "Parsing log flag at index %zu failed.",
+ json_error(ctx, "Parsing synproxy flag at index %zu failed.",
index);
}
return flags;
--
2.20.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH 2/2 nft] tests: py: add missing json outputs
2019-07-17 10:46 [PATCH 1/2 nft] src: json: fix synproxy flag parser typo Fernando Fernandez Mancera
@ 2019-07-17 10:46 ` Fernando Fernandez Mancera
2019-07-17 11:41 ` Pablo Neira Ayuso
2019-07-17 11:41 ` [PATCH 1/2 nft] src: json: fix synproxy flag parser typo Pablo Neira Ayuso
1 sibling, 1 reply; 4+ messages in thread
From: Fernando Fernandez Mancera @ 2019-07-17 10:46 UTC (permalink / raw)
To: netfilter-devel; +Cc: Fernando Fernandez Mancera
Fixes: 1188a69604c3 ("src: introduce SYNPROXY matching")
Signed-off-by: Fernando Fernandez Mancera <ffmancera@riseup.net>
---
tests/py/inet/synproxy.t.json | 25 +++++++++++++++++++++++++
1 file changed, 25 insertions(+)
diff --git a/tests/py/inet/synproxy.t.json b/tests/py/inet/synproxy.t.json
index 313fa9f..92c69d7 100644
--- a/tests/py/inet/synproxy.t.json
+++ b/tests/py/inet/synproxy.t.json
@@ -69,3 +69,28 @@
}
}
]
+
+# synproxy mss 1460 wscale 5 timestamp sack-perm
+[
+ {
+ "synproxy": {
+ "flags": [
+ "timestamp",
+ "sack-perm"
+ ],
+ "mss": 1460,
+ "wscale": 5
+ }
+ }
+]
+
+# synproxy sack-perm
+[
+ {
+ "synproxy": {
+ "flags": [
+ "sack-perm"
+ ]
+ }
+ }
+]
--
2.20.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 1/2 nft] src: json: fix synproxy flag parser typo
2019-07-17 10:46 [PATCH 1/2 nft] src: json: fix synproxy flag parser typo Fernando Fernandez Mancera
2019-07-17 10:46 ` [PATCH 2/2 nft] tests: py: add missing json outputs Fernando Fernandez Mancera
@ 2019-07-17 11:41 ` Pablo Neira Ayuso
1 sibling, 0 replies; 4+ messages in thread
From: Pablo Neira Ayuso @ 2019-07-17 11:41 UTC (permalink / raw)
To: Fernando Fernandez Mancera; +Cc: netfilter-devel
Applied, thanks Fernando.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 2/2 nft] tests: py: add missing json outputs
2019-07-17 10:46 ` [PATCH 2/2 nft] tests: py: add missing json outputs Fernando Fernandez Mancera
@ 2019-07-17 11:41 ` Pablo Neira Ayuso
0 siblings, 0 replies; 4+ messages in thread
From: Pablo Neira Ayuso @ 2019-07-17 11:41 UTC (permalink / raw)
To: Fernando Fernandez Mancera; +Cc: netfilter-devel
also applied, thanks.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2019-07-17 11:41 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-07-17 10:46 [PATCH 1/2 nft] src: json: fix synproxy flag parser typo Fernando Fernandez Mancera
2019-07-17 10:46 ` [PATCH 2/2 nft] tests: py: add missing json outputs Fernando Fernandez Mancera
2019-07-17 11:41 ` Pablo Neira Ayuso
2019-07-17 11:41 ` [PATCH 1/2 nft] src: json: fix synproxy flag parser typo Pablo Neira Ayuso
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).