AR# 59460

2013.4 FSBL: MD5 Checksum failure for encrypted images


The FSBL MD5 checksum is failing for encrypted images.

The failure is due to incorrect length fields being considered for validating the MD5 checksum for encrypted images.

For encrypted images, PartitionImageLength and PartitionDataLen are not the same.

The whole Partition Image length should be copied for checksum validation.

However, when copying the partition for checksum validation, FSBL is using both
PartitionImageLength and PartitionDataLen for PCAP DMA which results in some bytes being missed.


The fix for this issue would be to use only one of these variables (for example PartitionImageLength) consistently.
u32 PartitionMove(u32 ImageBaseAddress, PartHeader *Header)
                // Update the length fields for header
                 * For Signed or checksum enabled partition,
                 * Total partition image need to copied to DDR
                if (SignedPartitionFlag || PartitionChecksumFlag) {
                                ImageWordLen = Header->PartitionWordLen;
                                DataWordLen = Header->PartitionWordLen;
                // For Linear devices, copy data to DDR using PCAP
                Status = PcapDataTransfer((u32*)SourceAddr,
                // For non-linear devices copy data using MoveImage

AR# 59460
Date 05/16/2014
Status Active
Type Known Issues