BUG/MEDIUM: ssl: crt-list must continue parsing on ERR_WARN
authorWilliam Lallemand <wlallemand@haproxy.com>
Mon, 15 Jun 2020 12:37:19 +0000 (14:37 +0200)
committerWilliam Lallemand <wlallemand@haproxy.org>
Mon, 15 Jun 2020 15:30:43 +0000 (17:30 +0200)
commit43f1242f1e1c71a7e21cb0f7173414237429137a
tree36256161f0f4cc2e403338a97fc76fc491eb1fe8
parent4356453a4300435a3fea6cbb5bf424e0b6540468
BUG/MEDIUM: ssl: crt-list must continue parsing on ERR_WARN

The original crt-list parsing was stopping at any non-zero value in
the cfgerr variable, even warnings.

This is an issue as it could lead to a crt-list parsing stopped at the
first warning, then HAProxy launched with a partial crt-list.

A ERR_WARN must continue the parsing. The parsing must be only
stopped on an ERR_CODE.

This commit is 2.1 only since it was fixed
in 2.2 by commit 2954c47 ("MEDIUM: ssl: allow crt-list caching")
and accidently in 2.0 by commit b131c87 ("CLEANUP: ssl: make
ssl_sock_load_cert*() return real error codes") as well as in 1.9 and
1.8.
src/ssl_sock.c