The proposed thesis requires to design a firmware for a HSM (Hardware Secure Module) Peripheral of a commercial Microcontroller. HSM firmware shall manage MCU’s security mechanisms like memory protection, secure boot, firmware validation, secure firmware update, secure communication. The thesis requires also to build a POC (Proof of Concept) of the firmware for a chosen off-the-shelf commercial hardware platform