Creare un certificato client utilizzando il certificato CA - AWS IoT Core

Le traduzioni sono generate tramite traduzione automatica. In caso di conflitto tra il contenuto di una traduzione e la versione originale in Inglese, quest'ultima prevarrà.

Creare un certificato client utilizzando il certificato CA

È possibile utilizzare la propria autorità di certificazione (CA) per creare certificati client. Il certificato client deve essere registrato con AWS IoT prima dell'uso. Per informazioni sulle opzioni di registrazione per i certificati client, consulta Registrare un certificato client.

Crea un certificato client (CLI)

Nota

Non è possibile eseguire questa procedura in AWS IoT console.

Per creare un certificato client utilizzando AWS CLI
  1. Genera una coppia di chiavi.

    openssl genrsa -out device_cert_key_filename.key 2048
  2. Crea un certificato CSR per il client.

    openssl req -new \ -key device_cert_key_filename.key \ -out device_cert_csr_filename.csr

    Ti verrà richiesto di immettere alcune informazioni, come mostrato qui.

    You are about to be asked to enter information that will be incorporated into your certificate request. What you are about to enter is what is called a Distinguished Name or a DN. There are quite a few fields but you can leave some blank For some fields there will be a default value, If you enter '.', the field will be left blank. ----- Country Name (2 letter code) [AU]: State or Province Name (full name) []: Locality Name (for example, city) []: Organization Name (for example, company) []: Organizational Unit Name (for example, section) []: Common Name (e.g. server FQDN or YOUR name) []: Email Address []: Please enter the following 'extra' attributes to be sent with your certificate request A challenge password []: An optional company name []:
  3. Crea un certificato client daCSR.

    openssl x509 -req \ -in device_cert_csr_filename.csr \ -CA root_CA_cert_filename.pem \ -CAkey root_CA_key_filename.key \ -CAcreateserial \ -out device_cert_filename.pem \ -days 500 -sha256

A questo punto, il certificato client è stato creato, ma non è ancora stato registrato presso AWS IoT. Per informazioni su come e quando registrare il certificato client, vedereRegistrare un certificato client.