cancel
Showing results for 
Search instead for 
Did you mean: 

STM32 Trusted Package Creator ignoring Security Counter

Christian Keydel
Associate III

Using STM32TRUSTEE-SM framework, the non-secure application is built by the project.py script which in turn calls

STM32TrustedPackageCreator_CLI.exe -pb SM_Code_Image_bin.xml

to generate the application .bin file in MCUboot format.

The xml file has

	<Param>
		<Name>Security Counter</Name>
		<Value>auto</Value>
		<Type>Data</Type>
		<Command>-s</Command>
		<Hidden>1</Hidden>
		<Default>auto</Default>
	</Param>

It is my understanding that with this setting, an incrementing counter should be placed in the image header's ih_ver.iv_build_num field. But this field stays 0 no matter what I put under <Value>, auto or direct number.

There is a command "-s" which according to the documentation would be passed on to the imgtool executable, which, however, is described as this

ChristianKeydel_0-1763027708869.png

and therefore would have nothing to do with any counter.

Could anybody shed some light on it, please? I am using the latest version 2.20.0 of CubeProgrammer/TPC.

0 REPLIES 0