# Implement post-quantum cryptography on Arm Cortex-M4

## In this learning path

- [Introduction](https://learn.arm.com/learning-paths/embedded-and-microcontrollers/pqc_pqm4/)
- [Understand pqm4 and post-quantum cryptography](https://learn.arm.com/learning-paths/embedded-and-microcontrollers/pqc_pqm4/introduction/)
- [Set up the pqm4 development environment](https://learn.arm.com/learning-paths/embedded-and-microcontrollers/pqc_pqm4/setup-installation/)
- [Run pqm4 tests and benchmarks](https://learn.arm.com/learning-paths/embedded-and-microcontrollers/pqc_pqm4/running-tests-and-benchmarks/)
- [Add a KEM implementation to pqm4](https://learn.arm.com/learning-paths/embedded-and-microcontrollers/pqc_pqm4/adding-new-schemes/)
- [Next Steps](https://learn.arm.com/learning-paths/embedded-and-microcontrollers/pqc_pqm4/_next-steps/)

## About this Learning Path

|  |  |
| --- | --- |
| Skill level: | Advanced |
| Reading time: | 2 hrs |
| Last updated: | 13 Aug 2026 |

|  |
| --- |
| Authors: |
| Akash Malik , Arm<br>[GitHub](https://github.com/akashmalik19973)<br>[LinkedIn](https://linkedin.com/in/akash-malik-a65bab219)<br>Odin Shen , Arm<br>[GitHub](https://github.com/odincodeshen)<br>[LinkedIn](https://linkedin.com/in/odin-shen-lmshen) |
| Arm IP: |
| [Cortex-M](https://support.arm.com/?tab=compute-ip&Product%20Type=Microcontrollers) |
| Tags: |
| [Security](https://learn.arm.com/tag/security/) [Linux](https://learn.arm.com/tag/linux) [macOS](https://learn.arm.com/tag/macos) [C](https://learn.arm.com/tag/c) [Python](https://learn.arm.com/tag/python) [GCC](https://learn.arm.com/tag/gcc) [stlink](https://learn.arm.com/tag/stlink) [QEMU](https://learn.arm.com/tag/qemu) |

|  |  |
| --- | --- |
| Authors: | Akash Malik , Arm<br>[GitHub](https://github.com/akashmalik19973)<br>[LinkedIn](https://linkedin.com/in/akash-malik-a65bab219)<br>Odin Shen , Arm<br>[GitHub](https://github.com/odincodeshen)<br>[LinkedIn](https://linkedin.com/in/odin-shen-lmshen) |
| Arm IP: | [Cortex-M](https://support.arm.com/?tab=compute-ip&Product%20Type=Microcontrollers) |
| Tags: | [Security](https://learn.arm.com/tag/security/) [Linux](https://learn.arm.com/tag/linux) [macOS](https://learn.arm.com/tag/macos) [C](https://learn.arm.com/tag/c) [Python](https://learn.arm.com/tag/python) [GCC](https://learn.arm.com/tag/gcc) [stlink](https://learn.arm.com/tag/stlink) [QEMU](https://learn.arm.com/tag/qemu) |

## Who is this for?
This is an advanced topic for software developers and cryptography enthusiasts interested in implementing and testing post-quantum cryptographic algorithms on Arm Cortex-M4 microcontrollers.

## What will you learn?
After completing this Learning Path, you'll be able to perform the following tasks:
- Describe the design goals and supported algorithms of the pqm4 library.
- Set up the development environment for Arm Cortex-M4.
- Implement and test post-quantum cryptographic algorithms.
- Benchmark and profile cryptographic implementations.
- Integrate new cryptographic schemes into the pqm4 framework.

## Prerequisites
Before starting, you'll need the following prerequisites:
- Computer with Python 3.8 or higher
- Arm GNU Toolchain [installed](https://learn.arm.com/install-guides/gcc/arm-gnu/)
- An Arm Cortex-M4 development board such as NUCLEO-L4R5ZI, NUCLEO-L476RG, or STM32F4 Discovery, with stlink or OpenOCD for flashing. Alternatively, install QEMU to simulate the hardware without a physical board.

## Summary
You’ll use `pqm4` to test and benchmark post-quantum cryptography on Arm Cortex-M4. First, you’ll set up hardware or QEMU, build scheme binaries, and validate implementations against test vectors. Then, you’ll measure cycles, stack usage, and code size. You’ll add a key encapsulation mechanism under `crypto_kem/` so the build system discovers and compiles it.
