Skip to content

Latest commit

 

History

History
60 lines (43 loc) · 2 KB

File metadata and controls

60 lines (43 loc) · 2 KB

Wio Terminal Public Key Encryption Example

This repository demonstrates public key encryption on the Seeed Wio Terminal.

Overview

This project implements public key encryption functionality on the Seeed Wio Terminal, utilizing mbedTLS for cryptographic operations. It's built with PlatformIO and uses various Seeed Arduino libraries to handle storage, encryption, and communication.

Hardware Requirements

Dependencies

The project relies on several Seeed Arduino libraries:

Key Generation and Storage

Before running the project, you need to generate RSA keys using OpenSSL:

  1. Generate an RSA private key:
openssl genrsa -out private.key 2048
  1. Convert private key to DER format (DER is a binary format that is easier to work with mbedTLS):
openssl pkcs8 -topk8 -inform PEM -outform DER -nocrypt -in private.key -out private.der
  1. Extract public key in DER format:
openssl rsa -in private.key -pubout -outform DER -out public.der
  1. Place the private.der and public.der files at the root of your SD card

Building and Running

  1. Install PlatformIO
    • vscode will prompt you to install PlatformIO when you open the project
  2. Clone this repository
  3. Open in VS Code with PlatformIO extension
  4. Build and upload to your Wio Terminal:
pio run -t upload
  1. Monitor serial output:
pio run -t monitor

License

This project is licensed under the MIT License.