BUG/MINOR: lua: Check argument type to convert it to IP mask in arg validation
authorChristopher Faulet <cfaulet@haproxy.com>
Fri, 7 Aug 2020 07:11:22 +0000 (09:11 +0200)
committerWilly Tarreau <w@1wt.eu>
Tue, 11 Aug 2020 09:37:19 +0000 (11:37 +0200)
commit1f02e529ad337243931edb33ce6777b6f3a1c3a7
treebdf8903c6a9127310588bf87eb7e2569e990f6e1
parent63a92c32004e634bdd41eb4d446d74e2a8a4e5a9
BUG/MINOR: lua: Check argument type to convert it to IP mask in arg validation

In hlua_lua2arg_check() function, before converting an argument to an IPv4 or
IPv6 mask, we must be sure to have an integer or a string argument (ARGT_SINT or
ARGT_STR).

This patch must be backported to all supported versions.

(cherry picked from commit e663a6e326c3d4d465d5aa66e4fbe3acde69aac3)
Signed-off-by: Willy Tarreau <w@1wt.eu>
(cherry picked from commit 2ef95fa486eae674cb32c491c7f5ca5da3299fee)
Signed-off-by: Willy Tarreau <w@1wt.eu>
src/hlua.c