BUG/MEDIUM: server: Use sni as pool connection name for SSL server only
By default, for a given server, when no pool-conn-name is specified, the
configured sni is used. However, this must only be done when SSL is in-use
for the server. Of course, it is uncommon to have a sni expression for
now-ssl server. But this may happen.
In addition, the SSL may be disabled via the CLI. In that case, the
pool-conn-name must be discarded if it was copied from the sni. And, we must
of course take care to set it if the ssl is enabled.
Finally, when the attac-srv action is checked, we now checked the
pool-conn-name expression.
This patch should be backported as far as 3.0. It relies on "MINOR: server:
Parse sni and pool-conn-name expressions in a dedicated function" which
should be backported too.
(cherry picked from commit
f8f94ffc9c26bb8c2ff261972ce2f6c4fd731f6d)
Signed-off-by: Christopher Faulet <cfaulet@haproxy.com>
(cherry picked from commit
0d57285653b93428368112a9fbfbe59a40848707)
Signed-off-by: Christopher Faulet <cfaulet@haproxy.com>
(cherry picked from commit
5ff4c9da3720c4e1fd194c72670bfb4b108b7ce1)
Signed-off-by: Christopher Faulet <cfaulet@haproxy.com>