Secure IOT with AWS and Hornbill ESP32 (Redirected from Setting Up AWS for ESP32 IOT)
Security of connected devices is of paramount concern. There are several possible ways to make the devices secure. One of the most essential and widely used options is to use end to end encryption. The widely used Transport Layer Security (TLS) version 1.2 is the latest standard used on web for secure connections including banking. There are very few micro-controller based solutions that implement TLS 1.2 due to lack of resources. ESP32 is one of the most affordable options out there. So let’s look at securely connecting Hornbill ESP32 Dev board to Amazon web services (AWS) IOT.
We will start with configuring AWS account, setting up the thing, generating the security certificates, testing with a MQTT desktop client and then communicating with the hardware.
AWS User Account
For using the AWS services you need to have a user account and login using the AWS Login link
Existing users can directly login and directly jump to next. New users should register first and link the credit card for payments. Basic plan is free for first Year, other plans are chargeable. Check this link for available plans.
Creating a new thing
Generate certificates for new thing
Click on the activate button to activate the certificates and download the certificate,private key and root CA as name them as below.
Define and Attach Policies
Verify the Attached Policies
Testing Using MQTT Fx tool
As we have a test thing and also the certificates assigned with required policies. We can test it using the MQTT Fx broker tool. Lets list all the info we had while creating the thing and it certificates.
Broker Address / HOST Name: a3jzsmkecjw9hn.iot.us-west-2.amazonaws.com
Broker Port : 8883
Industrial data Logger
Below is the sample code for logging the temperature and Current using HornBill ESP32.
Download the complete IDF project from this link.
Have an opinion, suggestion , question or feedback about the article let it out here!