Skip to main content
Visitor II
April 9, 2024
Question

STM32H573I-DK_aws_ri_tz certificate

  • April 9, 2024
  • 1 reply
  • 2880 views

I'm working with the stm32h573i-dk kit and I need a connection to AWS. I performed the step-by-step procedure as described in the webinar https://content.st.com/stm32h5-connects-smart-things-in-a-secure-way.html, however, I got stuck at the end, where I didn't understand how to add the root_CA certificate on the hardware. When I turn on the board it gives the following status:

ffjunq_2-1712689414514.png

Does anyone know how I should proceed? Remembering that in AWS I created something with the same name as the hardware, I downloaded the certificates generated by AWS, however, I didn't understand how to upload the certificate to the hardware correctly. Can anyone get help?

    This topic has been closed for replies.

    1 reply

    ST Employee
    May 22, 2024

    Hi @ffjunq ,

    according to this other question Solved: Porting STM32CubeExpansion_Cloud_AWS to STM32H563Z... - STMicroelectronics Community, you finally managed to get your device to connect to AWS IoT Core.

    So you certainly found how to import the root CA certificate of Amazon server into the device by using the embedded CLI, as explained in the readme file of the application: 

    > pki import cert root_ca_cert
    -----BEGIN CERTIFICATE-----
    MIIBtjCCAVugAwIBAgITBmyf1XSXNmY/Owua2eiedgPySjAKBggqhkjOPQQDAjA5
    MQswCQYDVQQGEwJVUzEPMA0GA1UEChMGQW1hem9uMRkwFwYDVQQDExBBbWF6b24g
    Um9vdCBDQSAzMB4XDTE1MDUyNjAwMDAwMFoXDTQwMDUyNjAwMDAwMFowOTELMAkG
    A1UEBhMCVVMxDzANBgNVBAoTBkFtYXpvbjEZMBcGA1UEAxMQQW1hem9uIFJvb3Qg
    Q0EgMzBZMBMGByqGSM49AgEGCCqGSM49AwEHA0IABCmXp8ZBf8ANm+gBG1bG8lKl
    ui2yEujSLtf6ycXYqm0fc4E7O5hrOXwzpcVOho6AF2hiRVd9RFgdszflZwjrZt6j
    QjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgGGMB0GA1UdDgQWBBSr
    ttvXBp43rDCGB5Fwx5zEGbF4wDAKBggqhkjOPQQDAgNJADBGAiEA4IWSoxe3jfkr
    BqWTrBqYaGFy+uGh0PsceGCmQ5nFuMQCIQCcAu/xlJyzlvnrxir4tiz+OpAUFteM
    YyRIHN8wfdVoOw==
    -----END CERTIFICATE-----

    May you please indicate whether this step was sufficient, or if you faced other trouble?

    Best regards,

    -grd

    ffjunqAuthor
    Visitor II
    May 24, 2024

    Hello.

    Exactly, I was able to successfully complete the device registration on AWS.

    And yes, that step worked perfectly. The only problem I faced was that, contrary to the README, in item 4.3 - 3:

    aws iot list-certificates-by-ca --ca-certificate-id <ca_cert_id> \
     --query 'certificates[?status==`PENDING_ACTIVATION`].certificateId|join(`, `, @)'

    it uses single quotes, however, I needed to change to double quotes:

    aws iot list-certificates-by-ca --ca-certificate-id <ca_cert_id> \
     --query "certificates[?status==`PENDING_ACTIVATION`].certificateId|join(`, `, @)"

     And the next steps and I had to do the same thing.

    ST Employee
    May 24, 2024

    The command line examples work in bash (unless the strong quotes get unproperly converted into some character encodings?).

    Out of curiosity, what command shell do you use?