From 9340af713f3b983c41dd3248425bff31f9b2f18c70ae1bf7e4a1361ffdc239eb Mon Sep 17 00:00:00 2001 From: Stephan Kulow Date: Mon, 25 Aug 2014 09:04:11 +0000 Subject: [PATCH] Accepting request 245769 from network:ha-clustering:Factory 1 OBS-URL: https://build.opensuse.org/request/show/245769 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/haproxy?expand=0&rev=10 --- ...-move-the-directive-endif-to-the-end.patch | 2 +- ...arch-for-p-argument-in-systemd-wrapp.patch | 2 +- ...x-a-possible-busy-spinning-loop-in-c.patch | 2 +- ...-in-http-response-replace-header-num.patch | 34 ++++++++++++++ ...-MEDIUM-http-tarpit-timeout-is-reset.patch | 45 +++++++++++++++++++ haproxy.changes | 14 ++++++ haproxy.spec | 4 ++ 7 files changed, 100 insertions(+), 3 deletions(-) create mode 100644 0004-BUG-config-error-in-http-response-replace-header-num.patch create mode 100644 0005-BUG-MEDIUM-http-tarpit-timeout-is-reset.patch diff --git a/0001-BUG-MINOR-server-move-the-directive-endif-to-the-end.patch b/0001-BUG-MINOR-server-move-the-directive-endif-to-the-end.patch index 14a9b8e..2b113ff 100644 --- a/0001-BUG-MINOR-server-move-the-directive-endif-to-the-end.patch +++ b/0001-BUG-MINOR-server-move-the-directive-endif-to-the-end.patch @@ -1,7 +1,7 @@ From ad65af7dab9b8d8033fd09d8031cc774a6fbf768 Mon Sep 17 00:00:00 2001 From: Godbach Date: Mon, 28 Jul 2014 17:31:57 +0800 -Subject: [PATCH 1/3] BUG/MINOR: server: move the directive #endif to the end +Subject: [PATCH 1/5] BUG/MINOR: server: move the directive #endif to the end of file If a source file includes proto/server.h twice or more, redefinition errors will diff --git a/0002-BUG-MINOR-Fix-search-for-p-argument-in-systemd-wrapp.patch b/0002-BUG-MINOR-Fix-search-for-p-argument-in-systemd-wrapp.patch index eee0c1b..c08fb87 100644 --- a/0002-BUG-MINOR-Fix-search-for-p-argument-in-systemd-wrapp.patch +++ b/0002-BUG-MINOR-Fix-search-for-p-argument-in-systemd-wrapp.patch @@ -1,7 +1,7 @@ From 715e9b892f564e58489f86c125aed2a8994f16e9 Mon Sep 17 00:00:00 2001 From: Conrad Hoffmann Date: Mon, 28 Jul 2014 23:22:43 +0200 -Subject: [PATCH 2/3] BUG/MINOR: Fix search for -p argument in systemd wrapper. +Subject: [PATCH 2/5] BUG/MINOR: Fix search for -p argument in systemd wrapper. Searching for the pid file in the list of arguments did not take flags without parameters into account, like e.g. -de. Because diff --git a/0003-BUG-MAJOR-tcp-fix-a-possible-busy-spinning-loop-in-c.patch b/0003-BUG-MAJOR-tcp-fix-a-possible-busy-spinning-loop-in-c.patch index 66a181a..3b317f2 100644 --- a/0003-BUG-MAJOR-tcp-fix-a-possible-busy-spinning-loop-in-c.patch +++ b/0003-BUG-MAJOR-tcp-fix-a-possible-busy-spinning-loop-in-c.patch @@ -1,7 +1,7 @@ From f94735eb76e634d7531f9c903113f64820c4cec0 Mon Sep 17 00:00:00 2001 From: Willy Tarreau Date: Wed, 30 Jul 2014 08:56:35 +0200 -Subject: [PATCH 3/3] BUG/MAJOR: tcp: fix a possible busy spinning loop in +Subject: [PATCH 3/5] BUG/MAJOR: tcp: fix a possible busy spinning loop in content track-sc* As a consequence of various recent changes on the sample conversion, diff --git a/0004-BUG-config-error-in-http-response-replace-header-num.patch b/0004-BUG-config-error-in-http-response-replace-header-num.patch new file mode 100644 index 0000000..64700dd --- /dev/null +++ b/0004-BUG-config-error-in-http-response-replace-header-num.patch @@ -0,0 +1,34 @@ +From a772b945d757c25037ac58de64ccc27ceeb4b4a7 Mon Sep 17 00:00:00 2001 +From: Baptiste Assmann +Date: Fri, 8 Aug 2014 17:29:06 +0200 +Subject: [PATCH 4/5] BUG: config: error in http-response replace-header number + of arguments + +A couple of typo fixed in 'http-response replace-header': +- an error when counting the number of arguments +- a typo in the alert message + +This should be backported to 1.5. +(cherry picked from commit 12cb00b216d67468b7c4bd84abedcb4ecd1a32bc) +--- + src/proto_http.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/src/proto_http.c b/src/proto_http.c +index b7ed85d..2b75b32 100644 +--- a/src/proto_http.c ++++ b/src/proto_http.c +@@ -9281,8 +9281,8 @@ struct http_res_rule *parse_http_res_cond(const char **args, const char *file, i + cur_arg = 1; + + if (!*args[cur_arg] || !*args[cur_arg+1] || !*args[cur_arg+2] || +- (*args[cur_arg+3] && strcmp(args[cur_arg+2], "if") != 0 && strcmp(args[cur_arg+2], "unless") != 0)) { +- Alert("parsing [%s:%d]: 'http-request %s' expects exactly 3 arguments.\n", ++ (*args[cur_arg+3] && strcmp(args[cur_arg+3], "if") != 0 && strcmp(args[cur_arg+3], "unless") != 0)) { ++ Alert("parsing [%s:%d]: 'http-response %s' expects exactly 3 arguments.\n", + file, linenum, args[0]); + goto out_err; + } +-- +1.8.4.5 + diff --git a/0005-BUG-MEDIUM-http-tarpit-timeout-is-reset.patch b/0005-BUG-MEDIUM-http-tarpit-timeout-is-reset.patch new file mode 100644 index 0000000..7641e2d --- /dev/null +++ b/0005-BUG-MEDIUM-http-tarpit-timeout-is-reset.patch @@ -0,0 +1,45 @@ +From fc566b541e4c67cfbd8d6b40b627ce27dfc8a7cb Mon Sep 17 00:00:00 2001 +From: Thierry FOURNIER +Date: Fri, 22 Aug 2014 06:55:26 +0200 +Subject: [PATCH 5/5] BUG/MEDIUM: http: tarpit timeout is reset + +Before the commit bbba2a8ecc35daf99317aaff7015c1931779c33b +(1.5-dev24-8), the tarpit section set timeout and return, after this +commit, the tarpit section set the timeout, and go to the "done" label +which reset the timeout. + +Thanks Bryan Talbot for the bug report and analysis. + +This should be backported in 1.5. +(cherry picked from commit 7566e30477bf5ea4206bda5950d2d83108c4a3dc) +--- + src/proto_http.c | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) + +diff --git a/src/proto_http.c b/src/proto_http.c +index 2b75b32..bebc8bf 100644 +--- a/src/proto_http.c ++++ b/src/proto_http.c +@@ -4117,8 +4117,9 @@ int http_process_req_common(struct session *s, struct channel *req, int an_bit, + done: /* done with this analyser, continue with next ones that the calling + * points will have set, if any. + */ +- req->analysers &= ~an_bit; + req->analyse_exp = TICK_ETERNITY; ++ done_without_exp: /* done with this analyser, but dont reset the analyse_exp. */ ++ req->analysers &= ~an_bit; + return 1; + + tarpit: +@@ -4144,7 +4145,7 @@ int http_process_req_common(struct session *s, struct channel *req, int an_bit, + s->be->be_counters.denied_req++; + if (s->listener->counters) + s->listener->counters->denied_req++; +- goto done; ++ goto done_without_exp; + + deny: /* this request was blocked (denied) */ + txn->flags |= TX_CLDENY; +-- +1.8.4.5 + diff --git a/haproxy.changes b/haproxy.changes index 81a90d1..4b3e70d 100644 --- a/haproxy.changes +++ b/haproxy.changes @@ -1,3 +1,17 @@ +------------------------------------------------------------------- +Fri Aug 22 14:38:59 UTC 2014 - mrueckert@suse.de + +- pull 2 more fixes from git: + - 0004-BUG-config-error-in-http-response-replace-header-num.patch + A couple of typo fixed in 'http-response replace-header': + - an error when counting the number of arguments + - a typo in the alert message + - 0005-BUG-MEDIUM-http-tarpit-timeout-is-reset.patch + Before the commit bbba2a8ecc35daf99317aaff7015c1931779c33b + (1.5-dev24-8), the tarpit section set timeout and return, after + this commit, the tarpit section set the timeout, and go to the + "done" label which reset the timeout. + ------------------------------------------------------------------- Wed Jul 30 09:47:38 UTC 2014 - mrueckert@suse.de diff --git a/haproxy.spec b/haproxy.spec index 40c3ea3..8843a80 100644 --- a/haproxy.spec +++ b/haproxy.spec @@ -64,6 +64,8 @@ Patch4: haproxy-1.5_check_config_before_start.patch Patch5: 0001-BUG-MINOR-server-move-the-directive-endif-to-the-end.patch Patch6: 0002-BUG-MINOR-Fix-search-for-p-argument-in-systemd-wrapp.patch Patch7: 0003-BUG-MAJOR-tcp-fix-a-possible-busy-spinning-loop-in-c.patch +Patch8: 0004-BUG-config-error-in-http-response-replace-header-num.patch +Patch9: 0005-BUG-MEDIUM-http-tarpit-timeout-is-reset.patch Source99: haproxy-rpmlintrc # Summary: The Reliable, High Performance TCP/HTTP Load Balancer @@ -100,6 +102,8 @@ the most work done from every CPU cycle. %patch5 -p1 %patch6 -p1 %patch7 -p1 +%patch8 -p1 +%patch9 -p1 %build %{__make} \