media: venus: hfi_parser: add check to avoid out of bound access
There is a possibility that init_codecs is invoked multiple times during manipulated payload from video firmware. In such case, if codecs_count can get incremented to value more than MAX_CODEC_NUM, there can be OOB access. Reset the count so that it always starts from beginning. Cc: stable@vger.kernel.org Fixes: 1a73374a ("media: venus: hfi_parser: add common capability parser") Reviewed-by:Bryan O'Donoghue <bryan.odonoghue@linaro.org> Signed-off-by:
Vikash Garodia <quic_vgarodia@quicinc.com> Signed-off-by:
Hans Verkuil <hverkuil@xs4all.nl>
Loading
-
mentioned in commit c8f0ff7b
-
mentioned in commit d8f16145
-
mentioned in commit 85b3fe01
-
mentioned in commit 93c1fabd
-
mentioned in commit b70ef278
-
mentioned in commit ae96c048
-
mentioned in commit 7a105fce
-
mentioned in commit c7d679fa
-
mentioned in commit f56d6e6c
-
mentioned in commit 20b885bc
-
mentioned in commit a9add14f
-
mentioned in commit a617d670
-
mentioned in commit 1f5999c5
Please sign in to comment