]> git.kaiwu.me - haproxy.git/commit
BUG/MINOR: cfgcond: properly set the error pointer on evaluation error
authorWilly Tarreau <w@1wt.eu>
Fri, 3 Apr 2026 06:51:02 +0000 (08:51 +0200)
committerWilly Tarreau <w@1wt.eu>
Fri, 3 Apr 2026 06:51:02 +0000 (08:51 +0200)
commit3608374d6dd549346066842544d521d7fa0bde37
tree88fce8b7decc100e4c7d918a0660ce01ead96a67
parent6df3662077824f15704e6fbc3c15fa07f527565e
BUG/MINOR: cfgcond: properly set the error pointer on evaluation error

cfg_eval_condition() says that the <errptr> pointer will be set upon
error. However, cfg_eval_cond_expr() can fail (e.g. failure to handle
a dynamic argument) but would branch to "done" and leave errptr unset.
Let's check for this case as well.

This bug was reported by OSS Fuzz here:
   https://issues.oss-fuzz.com/issues/499135825

The bug was introduced in 2.5 around commit ca81887599 ("MINOR:
cfgcond: insert an expression between the condition and the term") so
the fix must be backported as far as 2.6.
src/cfgcond.c