When a new backend is added at runtime via the CLI, ensures its cap
contains PR_CAP_LB along with already set PR_CAP_BE.
The purpose of this cap is to flag a proxy with "load-balancing
capabilities". In fact this is a loose meaning which could be understand
in several manners. Currently, this cap is reserved for frontend,
backend and listen instances from the configuration file explicitely
created by users, by contrast to internal proxies. Thus, dynamically
added backends also enter in this definition.
The impact of this bug is limited as PR_CAP_LB usage is only used for
checking the compatibility of a server with the proxy mode. However,
this may change in the future so this change is mandatory.
This must be backported up to 3.4.
goto err;
}
- px = alloc_new_proxy(be_name, PR_CAP_BE, &msg);
+ px = alloc_new_proxy(be_name, PR_CAP_BE|PR_CAP_LB, &msg);
if (!px)
goto err;