AWS IoT Core MQTT Connect

0

When making an MQTT connection to AWS IoT Core, the connection is made through an X.509 certificate issued by AWS IoT Core. When connecting to AWS IoT Core from the server, can I use the AWS account IAM Access Key and Secret Key instead of the X.509 certificate file to connect to AWS IoT Core MQTT? Thank you

preguntada hace un año938 visualizaciones
2 Respuestas
2

Hi. The AWS IoT Core message broker supports SigV4 authentication for HTTPS and for MQTT over WebSocket, but not for MQTT: https://docs.aws.amazon.com/iot/latest/developerguide/protocols.html

You can make a WebSocket connection using the AWS IoT Device SDKs. Examples for Python and JS:

Or to publish using HTTPS, you can use the regular SDKs. Here are the relevant Python and JS SDK methods:

It's not possible to subscribe using HTTPS.

That all said, you may reconsider whether your server should even make an MQTT connection to AWS IoT Core. If you want to subscribe to receive messages, you should be aware that you're limited to 100 messages per second per connection. This will not scale as your device fleet grows. You might instead look to use AWS IoT Core rules engine to ingest into a storage service, or KDS or SQS to decouple your server.

profile pictureAWS
EXPERTO
Greg_B
respondido hace un año
0

From the documentation here, it appears that IAM access key authentication methods are not supported.
https://docs.aws.amazon.com/iot/latest/developerguide/protocols.html

profile picture
EXPERTO
respondido hace un año

No has iniciado sesión. Iniciar sesión para publicar una respuesta.

Una buena respuesta responde claramente a la pregunta, proporciona comentarios constructivos y fomenta el crecimiento profesional en la persona que hace la pregunta.

Pautas para responder preguntas