<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>How to reject old firmware version from AWS FOTA at NRF9160 side?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/82847/how-to-reject-old-firmware-version-from-aws-fota-at-nrf9160-side</link><description>Hi Nordic team 
 Customer Delta was running a street lamp project. 
 For AWS FOTA, they applied a AWS account and firmware update already can work. 
 However, it looks like no version control ability. No matter new or old firmware from AWS, 
 NRF9160</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 12 May 2022 14:53:51 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/82847/how-to-reject-old-firmware-version-from-aws-fota-at-nrf9160-side" /><item><title>RE: How to reject old firmware version from AWS FOTA at NRF9160 side?</title><link>https://devzone.nordicsemi.com/thread/367688?ContentTypeID=1</link><pubDate>Thu, 12 May 2022 14:53:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:62da2d79-23d0-4c02-bffc-c17d180732fe</guid><dc:creator>Miro Petrak</dc:creator><description>[quote userid="72692" url="~/f/nordic-q-a/82847/how-to-reject-old-firmware-version-from-aws-fota-at-nrf9160-side/344900#344900"]&lt;p&gt;*I had to enable these in mcuboot.conf, then &amp;quot;Unable to find bootable image..&amp;quot; went away&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div class="evolution-code-editor theme-clouds" style="width:624px;height:30px;position:relative;"&gt;&lt;a href="#" class="fullscreen"&gt;&lt;/a&gt;&lt;/div&gt;[/quote]
&lt;p&gt;CONFIG_PARTITION_MANAGER_ENABLED=y&lt;br /&gt;CONFIG_FLASH_MAP_CUSTOM=y&lt;/p&gt;
&lt;p&gt;is still needed even for NCS 1.9.1&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to reject old firmware version from AWS FOTA at NRF9160 side?</title><link>https://devzone.nordicsemi.com/thread/345632?ContentTypeID=1</link><pubDate>Mon, 03 Jan 2022 11:09:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b7f45041-b45c-4120-81b0-518430c3b28f</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;&lt;span&gt;In your last reply, you replied to an answer I gave eariler, which placed your reply in the middle of the stack of replies, and&amp;nbsp;made it not very easy to find. I provider a counter reply after your reply in the middle and copied it in here at the top as well, to make it more orderly and easier to find.&lt;/span&gt;&lt;/p&gt;
&lt;hr /&gt;
&lt;p&gt;&lt;span&gt;This is the struct used to store the image version (bootloader/mcuboot/boot/bootutil/include/bootutil/image.h):&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;struct image_version {
    uint8_t iv_major;
    uint8_t iv_minor;
    uint16_t iv_revision;
    uint32_t iv_build_num;
};&lt;/pre&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;The format is the following:&amp;nbsp;&lt;em&gt;maj.min.rev+build&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;As you can see the major and minor fields are 1 byte long and can store numbers as large as 255. For the revision field (2 byte), the largest number you can store is 65536 and for build_num (4 bytes), the largest number you can store is 2^32.&lt;/p&gt;
&lt;p&gt;Be aware that I have not done any tests using large numbers, so you may want to test yourself first to be certain.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to reject old firmware version from AWS FOTA at NRF9160 side?</title><link>https://devzone.nordicsemi.com/thread/345629?ContentTypeID=1</link><pubDate>Mon, 03 Jan 2022 11:04:32 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1819872d-1479-4efb-a152-d58bc71971a4</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;This is the struct used to store the image version (bootloader/mcuboot/boot/bootutil/include/bootutil/image.h):&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;struct image_version {
    uint8_t iv_major;
    uint8_t iv_minor;
    uint16_t iv_revision;
    uint32_t iv_build_num;
};
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;The format is the following:&amp;nbsp;&lt;em&gt;maj.min.rev+build&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;As you can see the major and minor fields are 1 byte long and can store numbers as large as 255. For the revision field (2 byte), the largest number you can store is 65536 and for build_num (4 bytes), the largest number you can store is 2^32.&lt;/p&gt;
&lt;p&gt;Be aware that I have not done any tests using large numbers, so you may want to test yourself first to be certain.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to reject old firmware version from AWS FOTA at NRF9160 side?</title><link>https://devzone.nordicsemi.com/thread/345565?ContentTypeID=1</link><pubDate>Mon, 03 Jan 2022 06:49:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fabb059a-6d33-4969-bcfd-f994a705acfd</guid><dc:creator>Jeffery</dc:creator><description>&lt;p&gt;Hi Simon&lt;/p&gt;
&lt;p&gt;Thanks for your support. Now, preventing downgrade for AWS FOTA can work at v1.3.0 example.&lt;/p&gt;
&lt;p&gt;By the way, we know&amp;nbsp;&lt;span&gt;CONFIG_MCUBOOT_IMAGE_VERSION string is formatted as &amp;quot;A.B.C+D&amp;quot;.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;What is maximum value for each digit (A, B, C and D)? Only from 0 to 9?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;I cannot find the information at google serach.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Jeff&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to reject old firmware version from AWS FOTA at NRF9160 side?</title><link>https://devzone.nordicsemi.com/thread/345151?ContentTypeID=1</link><pubDate>Mon, 27 Dec 2021 17:09:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:deb8bc14-2358-4add-b349-90ca0a169c36</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;I just tested the sample mcuboot_prevent_downgrade I uploaded in my last reply with &lt;strong&gt;NCS v1.3.0&lt;/strong&gt;, with the following addition in CMakeLists.txt&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;set(mcuboot_CONFIG_BOOT_SWAP_USING_MOVE n)&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;I followed&amp;nbsp;the same instructions as in my last reply and I got this output&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;** Booting Zephyr OS build v2.3.0-rc1-ncs1  ***
[00:00:00.003,540] &amp;lt;inf&amp;gt; mcuboot: Starting bootloader
[00:00:00.009,613] &amp;lt;inf&amp;gt; mcuboot: Swap type: test
[00:00:00.014,801] &amp;lt;err&amp;gt; mcuboot: insufficient version in secondary slot
[00:00:09.301,605] &amp;lt;inf&amp;gt; mcuboot: Bootloader chainload address offset: 0x10000
[00:00:09.309,387] &amp;lt;inf&amp;gt; mcuboot: Jumping to the first image slot
*** Booting Zephyr OS build v2.3.0-rc1-ncs1  ***
Flash regions           Domain          Permissions
00 02 0x00000 0x18000   Secure          rwxl
03 31 0x18000 0x100000  Non-Secure      rwxl

Non-secure callable region 0 placed in flash region 2 with size 32.

SRAM region             Domain          Permissions
00 07 0x00000 0x10000   Secure          rwxl
08 31 0x10000 0x40000   Non-Secure      rwxl

Peripheral              Domain          Status
00 NRF_P0               Non-Secure      OK
01 NRF_CLOCK            Non-Secure      OK
02 NRF_RTC0             Non-Secure      OK
03 NRF_RTC1             Non-Secure      OK
04 NRF_NVMC             Non-Secure      OK
05 NRF_UARTE1           Non-Secure      OK
06 NRF_UARTE2           Secure          SKIP
07 NRF_TWIM2            Non-Secure      OK
08 NRF_SPIM3            Non-Secure      OK
09 NRF_TIMER0           Non-Secure      OK
10 NRF_TIMER1           Non-Secure      OK
11 NRF_TIMER2           Non-Secure      OK
12 NRF_SAADC            Non-Secure      OK
13 NRF_PWM0             Non-Secure      OK
14 NRF_PWM1             Non-Secure      OK
15 NRF_PWM2             Non-Secure      OK
16 NRF_PWM3             Non-Secure      OK
17 NRF_WDT              Non-Secure      OK
18 NRF_IPC              Non-Secure      OK
19 NRF_VMC              Non-Secure      OK
20 NRF_FPU              Non-Secure      OK
21 NRF_EGU1             Non-Secure      OK
22 NRF_EGU2             Non-Secure      OK
23 NRF_DPPIC            Non-Secure      OK
24 NRF_GPIOTE1          Non-Secure      OK
25 NRF_REGULATORS       Non-Secure      OK

SPM: NS image at 0x1c200
SPM: NS MSP at 0x20020620
SPM: NS reset vector at 0x1d151
SPM: prepare to jump to Non-Secure image.
*** Booting Zephyr OS build v2.3.0-rc1-ncs1  ***
MCUBOOT IMAGE VERSION: 1.0.0
Hello World! nrf9160dk_nrf9160&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="text-decoration:underline;"&gt;So the downgrade prevention should work fine in NCS v1.3.0.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;I guess the issue is with the file &lt;em&gt;app_update.bin from your AWS &amp;quot;nrfconnectsdk.s3.eu-central-1.amazonaws.com&amp;quot;.&amp;nbsp;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;How do you know what version app_update.bin using, and that it is less than 1.0.0?&lt;/p&gt;
&lt;p&gt;Please create a new&amp;nbsp;&lt;em&gt;app_update.bin&amp;nbsp;&lt;/em&gt;&amp;nbsp;(should be generated into &lt;em&gt;&amp;lt;application&amp;gt;/build/zephyr/app_update.bin&lt;/em&gt;)&amp;nbsp;&lt;span&gt;with&amp;nbsp;&lt;/span&gt;&lt;span&gt;CONFIG_MCUBOOT_IMAGE_VERSION&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&amp;quot;0.0.0&amp;quot; and upload it to &amp;lt;&lt;em&gt;your&amp;nbsp;cloud server&amp;gt;&lt;/em&gt;, then try again.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to reject old firmware version from AWS FOTA at NRF9160 side?</title><link>https://devzone.nordicsemi.com/thread/345085?ContentTypeID=1</link><pubDate>Mon, 27 Dec 2021 09:59:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d4f2b4d6-81ce-48ee-8e0f-4fff23db80ce</guid><dc:creator>Jeffery</dc:creator><description>&lt;p&gt;Hi Simon&lt;/p&gt;
&lt;p&gt;&lt;span&gt;1.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt; Added the MCUBoot configs in the CMakeListst.tx of sdk v1.8.0 application_update, preventing downgrade did work.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;set(mcuboot_CONFIG_MCUBOOT_DOWNGRADE_PREVENTION&lt;br /&gt; y&lt;br /&gt;)&lt;br /&gt;set(mcuboot_CONFIG_BOOT_UPGRADE_ONLY&lt;br /&gt; y&lt;br /&gt;)&lt;/p&gt;
&lt;p&gt;2.&lt;/p&gt;
&lt;p&gt;However, my project was based on sdk connect v1.3.0 http_application_update.&lt;/p&gt;
&lt;p&gt;When I tried FOTA, it can download new app_update.bin from your AWS &amp;quot;&lt;span&gt;nrfconnectsdk.s3.eu-central-&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;1.amazonaws.com&lt;/span&gt;&amp;quot;. But, swap failed. Log show error and secondary image was invalid.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Jeffery&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to reject old firmware version from AWS FOTA at NRF9160 side?</title><link>https://devzone.nordicsemi.com/thread/344900?ContentTypeID=1</link><pubDate>Thu, 23 Dec 2021 09:37:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:34bfa037-016a-4d48-8ad3-dcf87cbd42b5</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;I tested this myself, and it seems like there is some bugs with the OVERLAY_CONFIG functionality. I will report internally as a bug*&lt;/p&gt;
&lt;p&gt;Instead I added the MCUBoot configs in the CMakeListst.txt like this:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;set(mcuboot_CONFIG_MCUBOOT_DOWNGRADE_PREVENTION
    y
)
set(mcuboot_CONFIG_BOOT_UPGRADE_ONLY
    y
)
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Could you test the following sample with NCS v1.8.0:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/mcuboot_5F00_prevent_5F00_downgrade.zip"&gt;devzone.nordicsemi.com/.../mcuboot_5F00_prevent_5F00_downgrade.zip&lt;/a&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Build it using the board nrf9160dk_nrf9160_ns&lt;/li&gt;
&lt;li&gt;You should get the following output:&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;...
...
...
29 NRF_PDM              Non-Secure      OK
30 NRF_I2S              Non-Secure      OK
31 NRF_GPIOTE1          Non-Secure      OK

SPM: NS image at 0x20200
SPM: NS MSP at 0x200154d0
SPM: NS reset vector at 0x216cd
SPM: prepare to jump to Non-Secure image.
*** Booting Zephyr OS build v2.7.0-ncs1  ***
MCUBOOT IMAGE VERSION: 1.0.0
Hello World! nrf9160dk_nrf9160&lt;/pre&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Next, change CONFIG_MCUBOOT_IMAGE_VERSION to &amp;quot;0.0.0&amp;quot; in mcuboot_prevent_downgrade/prj.conf&lt;/li&gt;
&lt;li&gt;Build the sample again (pristine) without flashing it
&lt;ul&gt;
&lt;li&gt;Make sure&amp;nbsp;&lt;span&gt;CONFIG_MCUBOOT_IMAGE_VERSION is &amp;quot;0.0.0&amp;quot; in &amp;lt;sample&amp;gt;/build/zephyr/.config&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Open the command line in ../mcuboot_prevent_downgrade/build/zephyr and run the following command:&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;nrfjprog --program app_moved_test_update.hex&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Read more about the file&amp;nbsp;app_moved_test_update.hex&amp;nbsp;in the &lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/1.8.0/mcuboot/readme-ncs.html#using-mcuboot-in-nrf-connect-sdk"&gt;MCUBoot documentation&lt;/a&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Reset the nRF9160 DK and you should see the following output:&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;*** Booting Zephyr OS build v2.7.0-ncs1  ***
I: Starting bootloader
I: Swap type: test
E: insufficient version in secondary slot
I: Bootloader chainload address offset: 0x10000
*** Booting Zephyr OS build v2.7.0-ncs1  ***
Flash regions           Domain          Permissions
00 03 0x00000 0x20000   Secure          rwxl
...
...
...
SPM: prepare to jump to Non-Secure image.
*** Booting Zephyr OS build v2.7.0-ncs1  ***
MCUBOOT IMAGE VERSION: 1.0.0
Hello World! nrf9160dk_nrf9160&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Report back to me if this works for you or not&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;hr /&gt;
&lt;p&gt;*I had to enable these in mcuboot.conf, then &amp;quot;Unable to find bootable image..&amp;quot; went away&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;CONFIG_PARTITION_MANAGER_ENABLED=y
CONFIG_FLASH_MAP_CUSTOM=y&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Then I added the below configs to mcuboot.conf as well, but they were not propogated to the file &amp;lt;sample&amp;gt;/build/mcuboot/zephyr/.config&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;CONFIG_MCUBOOT_DOWNGRADE_PREVENTION=y
CONFIG_BOOT_UPGRADE_ONLY=y&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;I will report this internally and get back to you in this ticket when we find a solution&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to reject old firmware version from AWS FOTA at NRF9160 side?</title><link>https://devzone.nordicsemi.com/thread/344528?ContentTypeID=1</link><pubDate>Tue, 21 Dec 2021 09:36:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7594cb13-1a54-4a99-81e1-c13fffda3315</guid><dc:creator>Jeffery</dc:creator><description>&lt;p&gt;Hi Simon&lt;/p&gt;
&lt;p&gt;1.config =&amp;gt;v1.8.0...\app_test\build_nrf9160dk_nrf9160_ns\zephyr\.config&lt;/p&gt;
&lt;p&gt;2.config=&amp;gt;&lt;span&gt;v1.8.0...&lt;/span&gt;&lt;span&gt;\app_test\build_nrf9160dk_nrf9160_ns\mcuboot\zephyr\.config&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Also, I attached CMakeLists.txt and log result.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;The log result was different to what I said at previous message after I put&amp;nbsp;set(mcuboot_OVERLAY_CONFIG~ just under&amp;nbsp;cmake_minimum_required at&amp;nbsp;CMakeLists.txt.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;As to&amp;nbsp;the file&amp;nbsp;&lt;em&gt;&amp;lt;sample&amp;gt;/build/zephyr/.config&lt;/em&gt;&amp;nbsp;of the firmware to be updated (where version is 0.0.0), I don&amp;#39;t have it. I used your demo AWS FOTA to verify as below in prj.conf.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;CONFIG_DOWNLOAD_HOST=&amp;quot;nrfconnectsdk.s3.eu-central-1.amazonaws.com&amp;quot;&lt;br /&gt;CONFIG_DOWNLOAD_FILE=&amp;quot;app_update.bin&amp;quot;&lt;br /&gt;CONFIG_APPLICATION_VERSION=1&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/1_2E00_config"&gt;devzone.nordicsemi.com/.../1_2E00_config&lt;/a&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/2_2E00_config"&gt;devzone.nordicsemi.com/.../2_2E00_config&lt;/a&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/7701.CMakeLists.txt"&gt;devzone.nordicsemi.com/.../7701.CMakeLists.txt&lt;/a&gt;&lt;img alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/1033.LOG.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/8880.mcuboot.conf"&gt;devzone.nordicsemi.com/.../8880.mcuboot.conf&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to reject old firmware version from AWS FOTA at NRF9160 side?</title><link>https://devzone.nordicsemi.com/thread/344498?ContentTypeID=1</link><pubDate>Tue, 21 Dec 2021 08:04:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:89ce0f0d-37e1-4912-a725-739cfdce2ce3</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;Could you show me the files &lt;em&gt;&amp;lt;sample&amp;gt;/build/zephyr/.config&lt;/em&gt; and &lt;em&gt;&amp;lt;sample&amp;gt;/build/mcuboot/zephyr/.config&lt;/em&gt;&amp;nbsp;of&amp;nbsp;the firmware on the DK (where version is 1.0.0).&lt;/p&gt;
&lt;p&gt;Can you also show me the file&amp;nbsp;&lt;span&gt;&lt;em&gt;&amp;lt;sample&amp;gt;/build/zephyr/.config&lt;/em&gt;&amp;nbsp;of the firmware to be updated (where version is 0.0.0).&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Best regards,&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Simon&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to reject old firmware version from AWS FOTA at NRF9160 side?</title><link>https://devzone.nordicsemi.com/thread/344477?ContentTypeID=1</link><pubDate>Tue, 21 Dec 2021 05:24:17 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a874f48f-0cff-45e8-b5d1-8f55eac2d630</guid><dc:creator>Jeffery</dc:creator><description>&lt;p&gt;Hi Simon&lt;/p&gt;
&lt;p&gt;1.&amp;nbsp;It can compile now. My test project is v1.8.0 application update. What I did as below.&lt;/p&gt;
&lt;p&gt;A. Added below string at CMakeLists.txt&lt;/p&gt;
&lt;p&gt;set(mcuboot_OVERLAY_CONFIG&lt;br /&gt; ${CMAKE_CURRENT_LIST_DIR}/mcuboot.conf&lt;br /&gt;)&lt;/p&gt;
&lt;p&gt;B. Create mcuboot.conf at project folder. Then, fill below settngs.&lt;/p&gt;
&lt;p&gt;CONFIG_BOOTLOADER_MCUBOOT=y &lt;br /&gt;CONFIG_MCUBOOT_DOWNGRADE_PREVENTION=y&lt;br /&gt;CONFIG_BOOT_UPGRADE_ONLY=y&lt;/p&gt;
&lt;p&gt;C. Added below setting at prj.conf&lt;/p&gt;
&lt;p&gt;CONFIG_MCUBOOT_IMAGE_VERSION=&amp;quot;0.1.0&amp;quot;&lt;/p&gt;
&lt;p&gt;2. AWS address was default and not overwritten. So, nrf9160 will connect to Nordic&amp;#39;s AWS account.&lt;/p&gt;
&lt;p&gt;3. After press button1, it started downloading data. As reached to 100%, reset DK for swap test.&lt;/p&gt;
&lt;p&gt;&amp;nbsp; &amp;nbsp;The FOTA was done.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp; &amp;nbsp;However, it shall not be successfully since mcuboot version at my DK (1.0.0) is newer than version&lt;/p&gt;
&lt;p&gt;&amp;nbsp; &amp;nbsp;from AWS(0.0.0). Why is it successful to be downgraded?&lt;/p&gt;
&lt;p&gt;Jeffery&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to reject old firmware version from AWS FOTA at NRF9160 side?</title><link>https://devzone.nordicsemi.com/thread/344290?ContentTypeID=1</link><pubDate>Mon, 20 Dec 2021 09:56:55 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5770e369-6636-4ebf-aae1-72d3c024eb69</guid><dc:creator>Simon</dc:creator><description>[quote user="Jeffery"]&amp;nbsp;However, it popped error as the project was opened. Anything wrong?[/quote]
&lt;p&gt;If you look at this command&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;west build -b board application -- \
-DCONFIG_BOOTLOADER_MCUBOOT=y \
-DCONFIG_MCUBOOT_IMAGE_VERSION=\&amp;quot;0.1.2\+3\&amp;quot; \
-Dmcuboot_CONFIG_MCUBOOT_DOWNGRADE_PREVENTION=y \
-Dmcuboot_CONFIG_BOOT_UPGRADE_ONLY=y&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;You can see that some of the configs are meant for the application (&amp;lt;application&amp;gt;/prj.conf), and some of the configs are meant for mcuboot (&amp;lt;ncs&amp;gt;/bootloader/mcuboot). Specifically the configs written like &amp;quot;-D&amp;lt;config&amp;gt;&amp;quot; are for the application, while the configs written like &amp;quot;-Dmcuboot&amp;lt;config&amp;gt;&amp;quot; are for mcuboot. The reason it doesn&amp;#39;t work is because you have added everything to the application prj.conf file.&lt;/p&gt;
&lt;p&gt;You can also take a look at the ticket &lt;a href="https://devzone.nordicsemi.com/support-private/support/281432#permalink=718478"&gt;mcuboot customer config&lt;/a&gt;&amp;nbsp;to see how to set mcuboot configurations from the application.&lt;/p&gt;
[quote user="Jeffery"]2. The project customer referred to was v1.3.0. So, does it support mcuboot preventing downgrade?[/quote]
&lt;p&gt;Yes, downgrade preventions should be possible in NCS v1.3.0. I could not find any information about it in the NCS v1.3.0 documentation, but I found some lines mentioning it in the MCUBoot v1.3.0&amp;nbsp;documentation:&amp;nbsp;&lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/1.3.0/mcuboot/design.html#downgrade-prevention"&gt;https://developer.nordicsemi.com/nRF_Connect_SDK/doc/1.3.0/mcuboot/design.html#downgrade-prevention&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;In the above link, both SW based and HW based downgrade preventions are described. I forgot to mention the HW based method in my initial answer.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to reject old firmware version from AWS FOTA at NRF9160 side?</title><link>https://devzone.nordicsemi.com/thread/344248?ContentTypeID=1</link><pubDate>Mon, 20 Dec 2021 07:21:58 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8a766ecc-7458-469d-9a5c-0e64ca2470c6</guid><dc:creator>Jeffery</dc:creator><description>&lt;p&gt;Hi Simon&lt;/p&gt;
&lt;p&gt;1. I tried sdk connect v1.8.0 application update example. Added configuration settings to prevent downgrade.&lt;/p&gt;
&lt;p&gt;&amp;nbsp; &amp;nbsp;However, it popped error as the project was opened. Anything wrong?&lt;/p&gt;
&lt;p&gt;&lt;img alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/Open-solution.jpg" /&gt;&lt;img alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/2018.error.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/prj_5F00_conf.png" /&gt;&lt;/p&gt;
&lt;p&gt;2. The project customer referred to was v1.3.0. So, does it support mcuboot preventing downgrade?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Jeffery&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to reject old firmware version from AWS FOTA at NRF9160 side?</title><link>https://devzone.nordicsemi.com/thread/343876?ContentTypeID=1</link><pubDate>Thu, 16 Dec 2021 11:56:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d0ca5214-c346-489c-a19c-2ea6ba1af251</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;Take a look at&amp;nbsp;&lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/1.8.0/nrf/ug_fw_update.html#preventing-downgrades-using-mcuboot"&gt;https://developer.nordicsemi.com/nRF_Connect_SDK/doc/1.8.0/nrf/ug_fw_update.html#preventing-downgrades-using-mcuboot&lt;/a&gt;&lt;strong&gt;&amp;nbsp;&lt;/strong&gt;to see how to prevent downgrades with MCUboot.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>