1# MCUboot release notes
2
3- Table of Contents
4{:toc}
5
6## Version 2.0.0
7
8Note that this release, 2.0.0 is a new major number, and contains a small API
9change in the interface between mcuboot and the platform.  All platforms
10contained within the MCUboot tree have been updated, but any external platforms
11will have to be adjusted.  The following commit makes the API change, in the
12function `boot_save_shared_data`.
13
14    commit 3016d00cd765e7c09a14af55fb4dcad945e4b982
15    Author: Jamie McCrae <jamie.mccrae@nordicsemi.no>
16    Date:   Tue Mar 14 12:35:51 2023 +0000
17
18        bootutil: Add active slot number and max app size to shared data
19
20### About this release
21
22- Add error when flash device fails to open.
23- Panic bootloader when flash device fails to open.
24- Fixed issue with serial recovery not showing image details for
25  decrypted images.
26- Fixes issue with serial recovery in single slot mode wrongly
27  iterating over 2 image slots.
28- CDDL auto-generated function code has been replaced with zcbor function
29  calls, this now allows the parameters to be supplied in any order.
30- Added currently running slot ID and maximum application size to
31  shared data function definition.
32- Make the ECDSA256 TLV curve agnostic and rename it to ECDSA_SIG.
33- imgtool: add P384 support along with SHA384.
34- espressif: refactor after removing IDF submodule
35- espressif: add ESP32-C6, ESP32-C2 and ESP32-H2 new chips support
36- espressif: adjustments after IDF v5.1 compatibility, secure boot build and memory map organization
37- Serial recovery image state and image set state optional commands added
38- imgtool: add 'dumpinfo' command for signed image parsing.
39- imgtool: add 'getpubhash' command to dump the sha256 hash of the public key
40- imgtool's getpub can print the output to a file
41- imgtool can dump the raw versions of the public keys
42- Drop ECDSA P224 support
43- Fixed an issue with boot_serial repeats not being processed when
44  output was sent, this would lead to a divergence of commands
45  whereby later commands being sent would have the previous command
46  output sent instead.
47- Fixed an issue with the boot_serial zcbor setup encoder function
48  wrongly including the buffer address in the size which caused
49  serial recovery to fail on some platforms.
50- zcbor library files have been updated to version 0.7.0
51- Reworked boot serial extensions so that they can be used by modules
52  or from user repositories by switching to iterable sections.
53- Removed Zephyr custom img list boot serial extension support.
54- (Zephyr) Adds support for sharing boot information with
55  application via retention subsystem
56- Zephyr no longer builds in optimize for debug mode, this saves a
57  significant amount of flash space.
58- Reworked image encryption support for Zephyr, static dummy key files
59  are no longer in the code, a pem file must be supplied to extract
60  the private and public keys. The Kconfig menu has changed to only
61  show a single option for enabling encryption and selecting the key
62  file.
63- Serial recovery can now read and handle encrypted seondary slot
64  partitions.
65- Serial recovery with MBEDTLS no longer has undefined operations which
66  led to usage faults when the secondary slot image was encrypted.
67
68## Version 1.10.0
69
70The 1.10.0 release of MCUboot contains...
71
72### About this release
73
74- Various fixes to boot serial.
75- Various fixes to the mbed target.
76- Various fixes to the Espressif native target.
77- Various fixes to the Zephyr target.
78- Workflow improvements with Zephyr CI.
79- Add multi image support to the espressif esp32 target.
80- Improvements and corrections to the simulator.
81- Improve imgtool, including adding 3rd party signing support.
82- Various fixes to the mynewt target.
83- Various fixes to the nuttx target.
84- Dates to dependencies for doc generation.
85- Add downgrade prevention for modes using swap.
86- Various general fixes to the boot code.
87- Prefer swap move on zephyr if the scratch partition is not enabled.
88- Upgrade fault-injection hardening, improving cases injections are detected.
89- Add a new flash api `flash_area_get_sector`, along with support for each
90  target, that replaces `flash_area_sector_from_off`. This is a step in cleaning
91  up the flash API used by MCUboot.
92
93### Security fixes
94
95There are no security vulnerabilities reported on the MCUboot code for this
96release. There have been several updates to the dependencies in the Ruby code
97used to generate the documentation. This should only affect users that generate
98their own documentation.
99
100## Version 1.9.0
101
102The 1.9.0 release of MCUboot contains various bug fixes, improves
103support on some recent targets, and adds support for devices with a
104write alignment larger than 8.
105
106This change introduces a potentially incompatible change to the format
107of the image trailer.  If `BOOT_MAX_ALIGN` is kept at 8, the trailer
108format does not change.  However, to support larger write alignments,
109this value can be increased, which will result in a different magic
110number value.  These targets were previously unsupported in MCUboot,
111so this change should not affect any existing targets.  The change has
112been tested with a `BOOT_MAX_ALIGN` up to 32 bytes.
113
114### About this release
115
116- Add native flash encryption to Espressif targets
117- Numerous documentation improvements
118- Increase coverage of large images in the simulator
119- Add stm32 watchdog support
120- Add support for the `mimxrt685_evk` board
121- Add support for "partial multi-image booting"
122- Add support for clear image generation with encryption capability to
123  imgtool
124- Fix Zephyr when `CONFIG_BOOT_ENCRYPTION_KEY_FILE` is not defined
125- Remove zephyr example test running in shell.  The Go version is
126  primary and much more featureful.
127- imgtool: make `--max-align` default reasonable in most cases.
128- Implement the mcumgr echo command in serial boot mode
129
130### Security fixes
131
132## Version 1.8.0
133
134The 1.8.0 release of MCUboot contains numerous fixes, and adds support
135for the NuttX RTOS, and the Espressif ESP32 SDK.
136
137### About this release
138
139- Add support for the NuttX RTOS.
140- Add support for the Espressif ESP32 SDK.
141- `boot_serial` changed to use cddl-gen, which removes the dependency
142  on tinycbor.
143- Add various hooks to be able to change how image data is accessed.
144- Cypress supports Mbed TLS for encryption.
145- Support using Mbed TLS for ECDSA.  This can be useful if Mbed TLS is
146  brought in for another reason.
147- Add simulator support for testing direct-XIP and ramload.
148- Support Mbed TLS 3.0.  Updates the submodule for Mbed TLS to 3.0.
149- Enable direct-xip mode in Mbed-OS port.
150- extract `bootutil_public` library, a common interface for MCUboot
151  and the application.
152- Allow to boot primary image if secondary one is unreachable.
153- Add AES256 image encryption support.
154- Add Multiimage boot for direct-xip and ram-load mode.
155- Cargo files moved to top level, now `cargo test` can be run from the
156  top level directory.
157- Fault injection tests use updated TF-M.
158- Thingy:53 now supports multi-image DFU.
159- ram load and image encryption can be used together, allowing the
160  entire contents of flash to always remain encrypted.
161
162### Security fixes
163
164- [GHSA-gcxh-546h-phg4](https://github.com/mcu-tools/mcuboot/security/advisories/GHSA-gcxh-546h-phg4)
165  has been published.  There is not a fix at this time, but a caution
166  to be sure to follow the instructions carefully, and make sure that
167  the development keys in the repo are never used in a production
168  system.
169
170## Version 1.7.0
171
172The 1.7.0 release of MCUboot adds support for the Mbed-OS platform,
173Equal slots (direct-xip) upgrade mode, RAM loading upgrade mode,
174hardening against hardware level fault injection and timing attacks
175and single image mode.
176There are bug fixes, and associated imgtool updates as well.
177
178### About this release
179
180- Initial support for the Mbed-OS platform.
181- Added possibility to enter deep sleep mode after MCUboot app execution
182  for cypress platform.
183- Added hardening against hardware level fault injection and timing attacks.
184- Introduced Abstract crypto primitives to simplify porting.
185- Added RAM-load upgrade mode.
186- Renamed single-image mode to single-slot mode.
187- Allow larger primary slot in swap-move
188- Fixed boostrapping in swap-move mode.
189- Fixed issue causing that interrupted swap-move operation might brick device
190  if the primary image was padded.
191- Abstracting MCUboot crypto functions for cleaner porting
192- Droped flash_area_read_is_empty() porting API.
193- boot/zephyr: Added watchdog feed on nRF devices.
194  See `CONFIG_BOOT_WATCHDOG_FEED` option.
195- boot/zephyr: Added patch for turning off cache for Cortex M7 before
196  chain-loading.
197- boot/zephyr: added option to relocate interrupts to application
198- boot/zephyr: clean ARM core configuration only when selected by user
199- boot/boot_serial: allow nonaligned last image data chunk
200- imgtool: added custom TLV support.
201- imgtool: added possibility to set confirm flag for hex files as well.
202- imgtool: Print image digest during verify.
203
204### Zephyr-RTOS compatibility
205
206This release of MCUboot works with the Zephyr "main" at the time of the
207release. It was tested as of has 7a3b253ce. This version of MCUboot also
208works with the Zephyr v2.4.0, however it is recommended to enable
209`CONFIG_MCUBOOT_CLEANUP_ARM_CORE` while using that version.
210
211## Version 1.6.0
212
213The 1.6.0 release of MCUboot adds support for the PSOC6 platform,
214X25519 encrypted images, rollback protection, hardware keys, and a
215shared boot record to communicate boot attestation information to
216later boot stages.  There are bug fixes, and associated imgtool
217updates as well.
218
219### About this release
220
221- Initial support for the Cypress PSOC6 plaformt.  This platform
222  builds using the Cypress SDK, which has been added as submodules.
223- CBOR decoding in serial recovery replaced by code generated from a
224  CDDL description.
225- Add support for X25519 encrypted images.
226- Add rollback protection.  There is support for a HW rollback counter
227  (which must be provided as part of the platform), as well as a SW
228  solution that protects against some types of rollback.
229- Add an optional boot record in shared memory to communicate boot
230  attributes to later-run code.
231- Add support for hardware keys.
232- Various fixes to work with the latest Zephyr version.
233
234### Security issues addressed
235
236- CVE-2020-7595 "xmlStringLenDecodeEntities in parser.c in libxml2
237  2.9.10 has an infinite loop in a certain end-of-file situation." Fix
238  by updating a dependency in documentation generation.
239
240### Zephyr-RTOS compatibility
241
242This release of MCUboot works the Zephyr "main" at the time of the
243release.  It was tested as of has 1a89ca1238.  When Zephyr v2.3.0 is
244released, there will be a possible 1.6.1 or similar release of Zephyr
245if needed to address any issues.  There also may be branch releases of
246MCUboot specifically for the current version of Zephyr, e.g.
247v1.6.0-zephyr-2.2.1.
248
249## Version 1.5.0
250
251The 1.5.0 release of MCUboot adds support for encrypted images using
252ECIES with secp256r1 as an Elliptic Curve alternative to RSA-OAEP. A
253new swap method was added which allows for upgrades without using a
254scratch partition. There are also lots of bug fixes, extra simulator
255testing coverage and some imgtool updates.
256
257### About this release
258
259- TLVs were updated to use 16-bit lengths (from previous 8). This
260  should work with no changes for little-endian targets, but will
261  break compatibility with big-endian targets.
262- A benchmark framework was added to Zephyr
263- ed25519 signature validation can now build without using Mbed TLS
264  by relying on a bundled tinycrypt based sha-512 implementation.
265- imgtool was updated to correctly detect trailer overruns by image.
266- Encrypted image TLVs can be saved in swap metadata during a swap
267  upgrade instead of the plain AES key.
268- imgtool can dump private keys in C format (getpriv command), which
269  can be added as decryption keys. Optionally can remove superfluous
270  fields from the ASN1 by passing it `--minimal`.
271- Lots of other smaller bugs fixes.
272- Added downgrade prevention feature (available when the overwrite-based
273  image update strategy is used)
274
275### Known issues
276
277- TLV size change breaks compatibility with big-endian targets.
278
279## Version 1.4.0
280
281The 1.4.0 release of MCUboot primarily adds support for multi-image
282booting.  With this release, MCUboot can manage two images that can be
283updated independently.  With this, it also supports additions to the
284TLV that allow these dependencies to be specified.
285
286Multi-image support adds backward-incompatible changes to the format
287of the images: specifically adding support for protected TLV entries.
288If multiple images and dependencies are not used, the images will be
289compatible with previous releases of MCUboot.
290
291### About this release
292
293- Fixed CVE-2019-5477, and CVE-2019-16892.  These fix issue with
294  dependencies used in the generation of the documentation on github.
295- Numerous code cleanups and refactorings
296- Documentation updates for multi-image features
297- Update imgtool.py to support the new features
298- Updated the Mbed TLS submodule to current stable version 2.16.3
299- Moved the Mbed TLS submodule from within sim/mcuboot-sys to ext.
300  This will make it easier for other board supports to use this code.
301- Added some additional overflow and bound checks to data in the image
302  header, and TLV data.
303- Add a `-x` (or `--hex_addr`) flag to imgtool to set the base address
304  written to a hex-format image.  This allows the image to be flashed
305  at an offset, without having to use additional tools to modify the
306  image.
307
308## Version 1.3.1
309
310The 1.3.1 release of MCUboot consists mostly of small bug fixes and updates.
311There are no breaking changes in functionality. This release should work with
312Mynewt 1.6.0 and up, and any Zephyr `main` after sha
313f51e3c296040f73bca0e8fe1051d5ee63ce18e0d.
314
315### About this release
316
317- Fixed a revert interruption bug
318- Added ed25519 signing support
319- Added RSA-3072 signing support
320- Allow ec256 to run on CC310 interface
321- Some preparation work was done to allow for multi image support, which
322  should land in 1.4.0. This includes a simulator update for testing
323  multi-images, and a new name for slot0/slot1 which are now called
324  "primary slot" and "secondary slot".
325- Other minor bugfixes and improvements
326
327## Version 1.3.0
328
329The 1.3.0 release of MCUboot brings in many fixes and updates.  There
330are no breaking changes in functionality.  Many of the changes are
331refactorings that will make the code easier to maintain going forward.
332In addition, support has been added for encrypted images.  See [the
333docs](encrypted_images.md) for more information.
334
335### About this release
336
337- Modernize the Zephyr build scripts.
338- Add a `ptest` utility to help run the simulator in different
339  configurations.
340- Migrate the simulator to Rust 2018 edition.  The sim now requires at
341  least Rust 1.32 to build.
342- Simulator cleanups.  The simulator code is now built the same way
343  for every configuration, and queries the MCUboot code for how it was
344  compiled.
345- Abstract logging in MCUboot.  This was needed to support the new
346  logging system used in Zephyr.
347- Add multiple flash support.  Allows slot1/scratch to be stored in an
348  external flash device.
349- Add support for [encrypted images](encrypted_images.md).
350- Add support for flash devices that read as '0' when erased.
351- Add support to Zephyr for the `nrf52840_pca10059`.  This board
352  supports serial recovery over USB with CDC ACM.
353- imgtool is now also available as a python package on pypi.org.
354- Add an option to erase flash pages progressively during recovery to
355  avoid possible timeouts (required especially by serial recovery
356  using USB with CDC ACM).
357- imgtool: big-endian support
358- imgtool: saves in intel-hex format when output filename has `.hex`
359  extension; otherwise saves in binary format.
360
361## Version 1.2.0
362
363The 1.2.0 release of MCUboot brings a lot of fixes/updates, where much of the
364changes were on the boot serial functionality and imgtool utility. There are
365no breaking changes in MCUboot functionality, but some of the CLI parameters
366in imgtool were changed (either removed or added or updated).
367
368### About this release
369
370- imgtool accepts .hex formatted input
371- Logging system is now configurable
372- Most Zephyr configuration has been switched to Kconfig
373- Build system accepts .pem files in build system to autogenerate required
374  key arrays used internally
375- Zephyr build switched to using built-in flash_map and TinyCBOR modules
376- Serial boot has substantially decreased in space usage after refactorings
377- Serial boot build doesn't require newlib-c anymore on Zephyr
378- imgtool updates:
379  + "create" subcommand can be used as an alias for "sign"
380  + To allow imgtool to always perform the check that firmware does not
381    overflow the status area, `--slot-size` was added and `--pad` was updated
382    to act as a flag parameter.
383  + `--overwrite-only` can be passed if not using swap upgrades
384  + `--max-sectors` can be used to adjust the maximum amount of sectors that
385    a swap can handle; this value must also be configured for the bootloader
386  + `--pad-header` substitutes `--included-header` with reverted semantics,
387    so it's not required for firmware built by Zephyr build system
388
389### Known issues
390
391None
392
393## Version 1.1.0
394
395The 1.1.0 release of MCUboot brings a lot of fixes/updates to its
396inner workings, specially to its testing infrastructure which now
397enables a more thorough quality assurance of many of the available
398options. As expected of the 1.x.x release cycle, no breaking changes
399were made. From the tooling perpective the main addition is
400newt/imgtool support for password protected keys.
401
402### About this release
403
404- serial recovery functionality support under Zephyr
405- simulator: lots of refactors were applied, which result in the
406  simulator now leveraging the Rust testing infrastructure; testing
407  of ecdsa (secp256r1) was added
408- imgtool: removed PKCS1.5 support, added support for password
409  protected keys
410- tinycrypt 0.2.8 and the Mbed TLS ASN1 parser are now bundled with
411  MCUboot (eg secp256r1 is now free of external dependencies!)
412- Overwrite-only mode was updated to erase/copy only sectors that
413  actually store firmware
414- A lot of small code and documentation fixes and updates.
415
416### Known issues
417
418None
419
420## Version 1.0.0
421
422The 1.0.0 release of MCUboot introduces a format change.  It is
423important to either use the `imgtool.py` also from this release, or
424pass the `-2` to recent versions of the `newt` tool in order to
425generate image headers with the new format.  There should be no
426incompatible format changes throughout the 1.x.y release series.
427
428### About this release
429
430- Header format change.  This change was made to move all of the
431  information about signatures out of the header and into the TLV
432  block appended to the image.  This allows
433  - The signature to be replaced without changing the image.
434  - Multiple signatures to be applied.  This can be used, for example,
435    to sign an image with two algorithms, to support different
436    bootloader configurations based on these image.
437  - The public key is referred to by its SHA1 hash (or a prefix of the
438    hash), instead of an index that has to be maintained with the
439    bootloader.
440  - Allow new types of signatures in the future.
441- Support for PKCS#1 v1.5 signatures has been dropped.  All RSA
442  signatures should be made with PSS.  The tools have been changed to
443  reflect this.
444- The source for Tinycrypt has been placed in the MCUboot tree.  A
445  recent version of Tinycrypt introduced breaking API changes.  To
446  allow MCUboot to work across various platforms, we stop using the
447  Tinycrypt bundled with the OS platform, and use our own version.  A
448  future release of MCUboot will update the Tinycrypt version.
449- Support for some new targets:
450  - Nordic nRF51 and nRF52832 dev kits
451  - Hexiwear K64
452- Clearer sample applications have been added under `samples`.
453- Test plans for [zephyr](testplan-zephyr.md), and
454  [mynewt](testplan-mynewt.md).
455- The simulator is now able to test RSA signatures.
456- There is an unimplemented `load_addr` header for future support for
457  RAM loading in the bootloader.
458- Numerous documentation.
459
460### Known issues
461
462None
463
464## Version 0.9.0
465
466This is the first release of MCUboot, a secure bootloader for 32-bit MCUs.
467It is designed to be operating system-agnostic and works over any transport -
468wired or wireless. It is also hardware independent, and relies  on hardware
469porting layers from the operating system it works with. For the first release,
470we have support for three open source operating systems: Apache Mynewt, Zephyr
471and RIOT.
472
473### About this release
474
475- This release supports building with and running Apache Mynewt and Zephyr
476  targets.
477- RIOT is supported as a running target.
478- Image integrity is provided with SHA256.
479- Image originator authenticity is provided supporting the following
480  signature algorithms:
481  - RSA 2048 and RSA PKCS#1 v1.5 or v2.1
482  - Elliptic curve DSA with secp224r1 and secp256r1
483- Two firmware upgrade algorithms are provided:
484  - An overwrite only which upgrades slot 0 with the image in slot 1.
485  - A swapping upgrade which enables image test, allowing for rollback to a
486    previous known good image.
487- Supports both Mbed TLS and tinycrypt as backend crypto libraries. One of them
488  must be defined and the chosen signing algorithm will require a particular
489  library according to this list:
490  - RSA 2048 needs Mbed TLS
491  - ECDSA secp224r1 needs Mbed TLS
492  - ECDSA secp256r1 needs tinycrypt as well as the ASN.1 code from Mbed TLS
493    (so still needs that present).
494
495### Known issues
496
497- The image header and TLV formats are planned to change with release 1.0:
498  https://runtimeco.atlassian.net/browse/MCUB-66
499