cbfs: Allow controlling decompression of unverified files
commit6e303aa89b906dc12b0bbf6024a23de339634eb1
authorJulius Werner <jwerner@chromium.org>
Fri, 26 May 2023 01:26:32 +0000 (25 18:26 -0700)
committerLean Sheng Tan <sheng.tan@9elements.com>
Mon, 19 Jun 2023 12:27:15 +0000 (19 12:27 +0000)
tree13c7fed064b5e00eed7a81744439619006fdff48
parent3f1e034835fc40b43b95746b37b291de8c860810
cbfs: Allow controlling decompression of unverified files

This patch adds a new Kconfig that controls whether CBFS APIs for
unverified areas will allow file decompression when CBFS verification is
enabled. This should be disallowed by default because it exposes the
attack surface of all supported decompression algorithms. Make
allowances for one legacy use case with CONFIG_SOC_INTEL_CSE_LITE_
COMPRESS_ME_RW that should become obsolete with VBOOT_CBFS_INTEGRATION.

Signed-off-by: Julius Werner <jwerner@chromium.org>
Change-Id: Ieae420f51cbc01dae2ab265414219cc9c288087b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/75457
Reviewed-by: Jakub Czapiga <jacz@semihalf.com>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
src/lib/Kconfig.cbfs_verification
src/lib/cbfs.c
src/soc/intel/common/block/cse/Kconfig