Commit Graph

42 Commits (490286be7d46c5d903781e0a880f8602553dc4e3)

Author SHA1 Message Date
David Garske 490286be7d Support for sealing/unseal a secret based on an externally signed PCR policy.
* Added new `WOLFBOOT_TPM_SEAL` and `WOLFBOOT_TPM_SEAL_NV_BASE` config options.
* Added new `tools/tpm/policy_create` tool for assisting with creation of a policy digest. The sign keytool `--policy=file` signs the policy.
* Added new `WOLFBOOT_TPM_VERIFY` option to enable offloading of the asymmetric verification to the TPM. By default wolfCrypt will be used.
* Added example seal/unseal to update_flash for ARCH_SIM.
* Renamed `WOLFBOOT_TPM_KEYSTORE_NV_INDEX` to `WOLFBOOT_TPM_KEYSTORE_NV_BASE` to support multiple public keys.
* Refactored most TPM code into tpm.c.
* Refactored the keystore ROT to use new `wolfBoot_check_rot` API.
* Refactored the sign keytool to have a sign_digest function to allow signing firmware and policy for sealing/unsealing.
* Fix for make distclean && make using the wrong key tools.
2023-09-12 12:26:48 +02:00
jordan e23d450e45 LMS wolfBoot support. 2023-09-06 07:57:10 +02:00
jordan f966f18229 config.mk: tiny spelling cleanup. 2023-09-05 17:03:39 +02:00
Daniele Lacamera 75444cf93b Support for ATA Security feature set 2023-09-04 18:05:37 +02:00
David Garske 6ea1a1e4a5 Added GitHub action build tests for NXP parts (iMX RT, Kinetis and LPC). 2023-08-21 11:08:48 +02:00
Daniele Lacamera efa28e3787 x86_64: support SP_MATH on x86_64 architecture
Signed-off-by: Marco Oliverio <marco@wolfssl.com>
2023-07-24 18:12:13 +00:00
David Garske db15f9b0f1 Further NXP P1021 fixes and improvements:
* Added ELF32 and ELF64 loader support (config `ELF=1` or build option `WOLFBOOT_ELF`).
* Add ELF support to `update_ram.c` loader.
* Add support for loading entire flash image to RAM when `EXT_FLASH=1` and `NO_XIP=1` (or `WOLFBOOT_USE_RAMBOOT`).
* Added QUICC Engine support to load microcode and enable.
* Add multiple core support for NXP P1021.
* Fixes to resolve first stage boot ROM relocation.
  - Implemented temporary workaround to resolve stack traps.
* Added PPC GOT relocation support.
* Fix for the PPC `isr_empty` handler address.
* Fix to allow stack to use DDR by having assembly setup DDR TLB. After relocating wolfBoot use stack on DDR.
* Cleanup wolfBoot output.
  - Only remove extra .bin/.elf created unless `make distclean` is used.
  - Don't output the key grep test (only check result).
  - Adjust build order (first stage, wolfboot, test app, key, sign test app and factory).
  - Fix to make sure linker script is rebuilt before objects.

Sample NXP P1021 Output:

```
Relocating BOOT ROM to DDR
Loading wolfBoot to DDR
Jumping to full wolfBoot
wolfBoot HAL Init
Flash Init: Ret 0, ID 0x76207620
QE: Length 63732, Count 1
QE: uploading 'Microcode for P1021 r1.0' version 0.0.1
QE: Traps 0
MP: Starting core 2 (spin table 0xFFFFF240)
Versions: Boot 1, Update 0
Trying Boot partition at 0x200000
Loading header 512 bytes to 0x1DFFFE00
Loading image 3170724 bytes to 0x1E000000
Image size 3170724
Firmware Valid
Loading elf at 0x1E000000
Found valid elf32 (big endian)
Booting at 0x6000
```
2023-07-05 17:03:57 +02:00
David Garske 3b90e32356 Switch to small page size by default. Capture read_id return code. Add SPMATHALL to config.mk. 2023-04-21 16:41:00 +02:00
Daniele Lacamera 43fa7b17f1 Added WOLFBOOT_HUGE_STACK option
The option can be enabled to use RSA4096 with fast math.
2023-03-21 17:06:22 +01:00
David Garske 8dd0ee347f Support for the STM32 OCTOSPI peripheral. 2023-02-02 12:11:23 -08:00
David Garske a9526bab8f STM32 QSPI Flash support. Refactor SPI to allow different GPIO base/AF for each pin. Adds `DEBUG_UART` support for H7. 2022-12-20 13:31:28 +01:00
Daniele Lacamera 5a15fe1138 Added armored panic() function form arm cortex-m 2022-03-14 13:06:13 +01:00
Daniele Lacamera 43a5a38629 Fixes to AES-CTR encryption after testing 2022-01-31 16:46:09 +01:00
Daniele Lacamera 34341f96f7 Change FLASH origin for stm32f4 to 0x08000000 2022-01-21 00:07:19 +01:00
Daniele Lacamera 13541ec046 Delta updates, draft update mechanism with hdr replacement 2021-08-16 11:56:13 +02:00
Daniele Lacamera 4c4d7d69f8 Add support for WOLFBOOT_SMALL_STACK 2021-07-09 10:15:37 +02:00
Daniele Lacamera 98fa5e707e Added missing config entry in config.mk (see #93) 2021-02-05 10:52:16 +01:00
Dimitar Tomov a2ff8f1d8e Make sure wolfTPM support is included when measured boot is enabled
Signed-off-by: Dimitar Tomov <dimi@wolfssl.com>
2020-12-10 17:46:51 +02:00
Daniele Lacamera 4e27d9197f Added compile-time option to invert FLAGS logic (FLAGS_INVERT=1) 2020-11-03 11:05:14 +01:00
Daniele Lacamera cbe002fad7 Merge branch 'update-flags-in-boot-partition' into stm32l5 2020-09-28 17:10:28 +02:00
Daniele Lacamera b0fbafe014 Added DISABLE_BACKUP option 2020-09-14 16:31:07 +02:00
Daniele Lacamera 75898806eb Added option FLAGS_HOME to store UPDATE flags in the BOOT partition 2020-09-11 11:25:51 +02:00
Daniele Lacamera d642231344 Disable TZEN by default on all platforms 2020-09-09 14:26:30 -07:00
Daniele Lacamera 61890b0bdb Fixed stm32l5 artifacts 2020-09-09 14:26:30 -07:00
David Garske 43c2e3dd79 Experimental support for STM32L5 2020-09-09 14:26:30 -07:00
Daniele Lacamera 17707b7a37 Support for PSOC6 crypto support: added compile option 2020-06-05 11:49:57 +02:00
David Garske 93d62112e9
Merge pull request #52 from danielinux/mpu
Added support for memory protection on ARM using MPU
2020-05-26 06:42:01 -07:00
David Garske 782d4b685c Fix to allow .config to define WOLFTPM variable (and others). 2020-05-25 07:01:05 -07:00
Daniele Lacamera 7ade0ee2c0 Added support for memory protection on ARM using MPU 2020-05-25 15:14:41 +02:00
Daniele Lacamera f3d0d8fc83 PSoC6 support: updated configuration, docs added to Targets.md, revert
custom NVM_CACHE_SIZE
2020-05-20 06:53:00 -07:00
Daniele Lacamera 3db37a6b5c Updated NVM_CACHE_SIZE to match different configurations.
Progress on psoc6 HAL, fixed memory mapping and test app
2020-05-20 06:53:00 -07:00
Daniele Lacamera 75638394b1 Initial draft for psoc6 support 2020-05-20 06:53:00 -07:00
Daniele Lacamera 7ffcdca098 External, emulated non-volatile memory over UART 2020-04-03 14:27:42 +02:00
David Garske c0b534edd7 wolfBoot Aarch64 support (Xilinx Zynq and Raspberry Pi):
* Added Aarch64 boot/startup support
* Added configuration templates for Raspberry Pi 3 and Xilinx ZynqMP UltraScale+
* Added Xilinx Zynq QSPI bare-metal Driver
* Added `NO_XIP` option for full `ext_flash_*` API on all partitions
* Added Xilinx SDK Project Template
* Added support for DTS image partitions
* Added wolfBoot signing tool in Native C (`tools/keytools/sign.c`).
* Added libwolfboot functions `int wolfBoot_fallback_is_possible(void);` and `int wolfBoot_dualboot_candidate(void);`
* Performance improvement to only hash application firmware image once
2020-03-04 12:04:46 -08:00
Daniele Lacamera c32c5da6a1 Renamed KINETIS to MCUXPRESSO, added initial support for LPC family 2020-03-04 08:01:05 +01:00
Daniele Lacamera d33c5acac8 Added support for SHA3 2020-01-07 20:35:31 +01:00
David Garske 79277d60ce Progress on expanding STM32WB testing support. Including external SPI/TPM and RSA. Fixes to prevent STM32WB macro collisions with PKA. Makefile improvements for combinations of PKA, SIGN and WOLFTPM. 2019-12-20 19:08:31 +01:00
David Garske 041ca75793 Added support for TPM2.0 module via wolfTPM. Tested with STM32F4. Build using `make SIGN=ECC256 WOLFTPM=1`. 2019-12-17 10:59:11 -08:00
David Garske fae6a974c8 Adds RSA support to wolfBoot using "SIGN=RSA2048". Includes RSA signing script tool in Python and instructions. 2019-12-17 09:44:02 -08:00
Daniele Lacamera 0b822cefbb Fixes to kinetis K82F 2019-11-11 14:27:16 -08:00
Daniele Lacamera c78f0d7026 Added support for STM32 PKA 2019-11-11 15:06:04 +01:00
Daniele Lacamera ca9ffbab7c Configuration (via .config), single entry point for options 2019-10-10 20:39:25 +02:00