[U-Boot] [PATCH 3/3] Atmel TPM: Fix potential buffer overruns

2018-02-12 Thread Jeremy Boone
From: Jeremy Boone Ensure that the Atmel TPM driver performs sufficient validation of the length returned in the TPM response header. This patch prevents memory corruption if the header contains a length value that is larger than the destination buffer. Signed-off-by: Jeremy Boone --- drivers

[U-Boot] [PATCH 0/3] Fix potential buffer overruns in TPM driver

2018-02-12 Thread Jeremy Boone
From: Jeremy Boone The TPM response packet often contains a variable-length payload. It is the responsibility of U-Boot driver code to ensure that the length value that has been extracted from the response packet's header or body is appropriately sized before copying that data into an

[U-Boot] [PATCH 1/3] STMicro TPM: Fix potential buffer overruns

2018-02-12 Thread Jeremy Boone
From: Jeremy Boone This patch prevents integer underflow when the length was too small, which could lead to memory corruption. Signed-off-by: Jeremy Boone --- drivers/tpm/tpm_tis_st33zp24_i2c.c | 5 +++-- drivers/tpm/tpm_tis_st33zp24_spi.c | 5 +++-- 2 files changed, 6 insertions(+), 4

[U-Boot] [PATCH 2/3] Infineon TPM: Fix potential buffer overruns

2018-02-12 Thread Jeremy Boone
From: Jeremy Boone Ensure that the Infineon I2C and SPI TPM driver performs adequate validation of the length extracted from the TPM response header. This patch prevents integer underflow when the length was too small, which could lead to memory corruption. Signed-off-by: Jeremy Boone