Commit graph xserver/Xext/render/filter.c
Author SHA1 Message Date
Enrico Weigelt, metux IT consult
6a97f6d38e render: filter: fix integer-overflow bypass of convolution size check
convolutionFilterValidateParams() derives w/h from client-supplied
xFixed values via the sign-extending xFixedToInt(), then checked
'w * h > nparams' as a plain (signed) int product. A client can choose
negative w/h so the mathematical product is huge but the signed int
product wraps to a small or negative value, defeating the bounds check
that is supposed to reject a convolution kernel larger than the actual
parameter list.

Reject negative w/h outright and compare the product as int64_t so it
cannot wrap before the comparison.

Signed-off-by: Enrico Weigelt, metux IT consult <enrico.weigelt@vnc.biz>
2026-07-03 19:59:53 +02:00
Enrico Weigelt, metux IT consult
876c782094 treewide: clean up includes of misc.h
adding include/ prefix to it.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2026-06-19 19:24:57 +02:00
Enrico Weigelt, metux IT consult
561168cfa1 render: move it under Xext/
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2026-06-17 14:29:57 +02:00
Renamed from render/filter.c (Browse further)