Topics In Demand
Notification
New

No notification found.

Mission-critical embedded systems: High reliability for improved security (Part-1)
Mission-critical embedded systems: High reliability for improved security (Part-1)

February 16, 2024

12

0

Security of embedded systems

The word “security” immediately invokes related terms such as “confidentiality” and “privacy”, while conjuring up mental pictures of malicious hackers! It also brings to mind closely related security parlance, such as password, OTP, encryption etc. However, the term “security” encompasses much more in reality, including diverse aspects such as integrity, authentication, non-repudiation and availability of the system.

Security of an embedded system has been traditionally mapped to secure boot, and for good reason. Secure boot ensures that only authorized executable code is granted permission to run on the silicon. Being the very first piece of code that gets to execute on the CPU, it activates the security mechanisms, and verifies the authenticity and the integrity of the application firmware code to be executed on the hardware platform after the boot up stage. Secure Boot is indeed the foundation of device security, also known as the Root of Trust (RoT) of the device. RoT is further extended by Secure Firmware Update, sometimes called Secure FOTA update, a key ability that allows the device to get its application firmware securely updated.

Secure boot

Secure boot uses cryptography to verify (Authentication + Integrity) the application firmware code and metadata (containing version info, hardware configuration, boot conditions etc.). It grants execution permission only if verification performed on both the firmware code and the metadata is successful. Being immutable code that is launched at each system reset, secure boot code is typically protected by the write protection mechanism of the flash memory chip from which it boots up. To minimize the risk of having vulnerabilities in itself, secure boot code is concise, simple and verifiable. Complex steps are usually deferred to later stages, like a secondary bootloader. Secure boot is sometimes confused with high availability boot, although they have common objectives, the mechanisms and interfaces provided by the silicon vendor have considerable differences.

Security in mission critical applications

However, authentication and integrity check of executable code aren’t the only aspects of security in an embedded system. Take for instance the scenario where a user of a battery powered device is unable to boot up due to failure of the normal boot device or corruption of its bootable image. Does this incident compromise system security? Well, it sounds more like a typical field failure rather than a security incident, right?

Now, what if the said device is supposed to serve a mission critical function, like a military field device being operated by an infantry soldier on an active frontier, or a medical equipment being used on critically ill patients in a rural area by a paramedic! We can now begin to see that in spite of the absence of any external threat agent, and in spite of having authentication and integrity checks in place to safeguard against accidental execution of rogue code, the failure to boot simply compromises the device’s availability to perform its designated mission critical function, thereby compromising security. Therefore, we can see that for a mission critical embedded system, higher system reliability directly translates to improved security.

System design for improved reliability

Reliability in system design starts early with hardware component selection, which is MIL-grade by default for defence applications. Reliability engineering extends to the software level by implementing extensive error handling and recovery logic that is designed into the embedded firmware. In spite of these best design practices, component failures and firmware corruptions cannot be ruled out in the operational lifetime of the product. In fact, we need to plan and design for such failures, especially in the case of devices intended for outdoor operation in harsh climatic and operating conditions. As the sharp contrast between the Chandrayaan missions 2 versus 3 has been a recent revelation to system designers of all mission critical systems, we must adopt the philosophy right from start that “if something could go wrong, it will go wrong!”, and design accordingly for all kinds of potential failures and build appropriate mitigation mechanisms.

Reliability mechanisms in embedded systems

Silicon vendors usually provide a built-in redundant boot feature for system designers in their respective microcontrollers. In the eventuality of failure of the normal boot device or corruption of its bootable image, the redundant boot mechanism permits booting up from an alternative boot device. The idea is to be able to have redundancy in the boot process in spite of boot failure in the field. From a reliability metrics point of view, the redundant boot feature improves  “availability”, while helping to extend overall “MTTF” (Mean Time To Failure) and drastically reducing, if not eliminating, the contribution of a boot failure scenario to “MTTR” (Mean Time To Repair). And as mentioned earlier, higher system availability of a mission critical system translates to its improved security.

Implementing redundant boot requires more than just experience with the microcontroller’s development environment and compiler toolchain. Critical design decisions are involved as to the scope of the redundant boot function, understanding the system hooks into the detection of normal boot failure and protection of the redundant bootable image against unauthorized access. It also requires knowledge of configuring the microcontroller correctly for redundant boot, creation of bootable redundant image file with the appropriate memory configuration, flashing the boot image into the redundant boot device and a test plan for validating the redundant boot functionality and establishing reliability metrics.

https://en.wikipedia.org/wiki/United_States_Military_Standard

https://en.wikipedia.org/wiki/MIL-STD-810

https://www.ndtv.com/india-news/chandrayaan-3-indias-moon-mission-chandrayaan-2-vs-chandrayaan-3-know-the-difference-4321770


That the contents of third-party articles/blogs published here on the website, and the interpretation of all information in the article/blogs such as data, maps, numbers, opinions etc. displayed in the article/blogs and views or the opinions expressed within the content are solely of the author's; and do not reflect the opinions and beliefs of NASSCOM or its affiliates in any manner. NASSCOM does not take any liability w.r.t. content in any manner and will not be liable in any manner whatsoever for any kind of liability arising out of any act, error or omission. The contents of third-party article/blogs published, are provided solely as convenience; and the presence of these articles/blogs should not, under any circumstances, be considered as an endorsement of the contents by NASSCOM in any manner; and if you chose to access these articles/blogs , you do so at your own risk.


Download Attachment

embeddedSecurity.pdf

NeST Digital, the software arm of the NeST Group, has been transforming businesses, providing customized and innovative software solutions and services for customers across the globe. A leader in providing end-to-end solutions under one roof, covering contract manufacturing and product engineering services, NeST has 25 years of proven experience in delivering industry-specific engineering and technology solutions for customers, ranging from SMBs to Fortune 500 enterprises, focusing on Transportation, Aerospace, Defense, Healthcare, Power, Industrial, GIS, and BFSI domains.

© Copyright nasscom. All Rights Reserved.