herunterladen

1 Introduction
Firmware upgrade is an essential feature of many
microcontroller systems. It is very important to encrypt
firmware to protect the intellectual property especially when
manufacturers provide firmware to third parties.
Freescale has provided broad examples of bootloaders for
microcontrollers. This application note describes the
implementation of the advanced encryption standard (AES) on
the following two USB mass storage bootloaders:
• USB Mass Storage Host Bootloader. See AN4368: USB
Mass Storage Host Bootloader, available on
freescale.com
• USB Mass Storage Device Bootloader. See AN4379:
Freescale USB Mass Storage Device Bootloader,
available on freescale.com
.
2 Implementation of AES
AES is a symmetric key algorithm and the same key is used
for encryption and decryption. It is a block cipher which
means each time it encrypts or decrypts a block of data. The
block size is 128 bits with an optional key size of 128, 192 or
256 bits. The block size of 128 bits is used in the AES
implementation given in this application note. Random initial
Freescale Semiconductor
Document Number:AN4605
Application Note
Rev. 0, 10/2012
Secure Bootloader Implementation
by:
Derek Lau
© 2012 Freescale Semiconductor, Inc.
Contents
1 Introduction................................................................1
2 Implementation of AES.............................................1
2.1 PC software....................................................2
3 AES bootloader firmware.........................................3
3.1 Add AES to bootloader..................................3
4 Customization...........................................................4
5 Conclusion.................................................................4
6 References.................................................................4