env: Implement support for AES encryption into fw_* tools

Implement support for encrypting/decrypting the environment block
into the tools/env/fw_* tools. The cipher used is AES 128 CBC and
the implementation depends solely on components internal to U-Boot.

To allow building against the internal AES library, the library did
need minor adjustments to not include U-Boot's headers which are not
wanted to be included and define missing types.

Signed-off-by: Marek Vasut <marex@denx.de>
This commit is contained in:
Marek Vasut
2014-03-05 19:59:52 +01:00
committed by Tom Rini
parent a4223b746d
commit a8a752c084
5 changed files with 151 additions and 8 deletions

View File

@ -22,7 +22,11 @@
* REDISTRIBUTION OF THIS SOFTWARE.
*/
#ifndef USE_HOSTCC
#include <common.h>
#else
#include <string.h>
#endif
#include "aes.h"
/* forward s-box */