The AWS Greengrass PKCS11 Provider enables the ability to interact with Trusted Platform Module (TPM) storing IoT thing's private key and certificate to connect to AWS IoT and other AWS services. This PKCS11 provider is meant to run with Greengrass Nucleus as a plugin.
This PKCS11 Provider takes the following parameters:
- name: A unique string identifier for the configuration.
- library: Absolute path to PKCS11 library on the device.
- slot: Slot ID of the slot which holds the key. Not to be confused with slot index or slot label.
- userPin: User pin needed to access the slot.
- Thing private key and certificate need to be imported to the TPM on the device.
- config.yaml containing the following additional config:
aws.greengrass.crypto.Pkcs11Provider:
configuration:
name: sample_name
library: /absolute/path/to/library
slot: 12345
userPin: abc123
sudo -E java -Droot="<root>" -Dlog.store=FILE \
-jar ./GreengrassCore/lib/Greengrass.jar \
--aws-region <region> \
--init-config config.yaml \
--component-default-user ggc_user:ggc_group \
--setup-system-service true
--trusted-plugin <path_to_plugin>/aws.greengrass.crypto.Pkcs11Provider.jar
- Thing private key and certificate need to be imported to the TPM on the device.
Create a deployment and merge the parameters as shown below:
{
"targetArn": "<arn_of_target>",
"components": {
"aws.greengrass.crypto.Pkcs11Provider": {
"componentVersion": "1.0.0",
"configurationUpdate": {
"merge": "{\"name\":\"sample_name\",\"library\":\"/absolute/path/to/library\",\"slot\":12345,\"userPin\":\"abc123\"}"
}
}
}
See CONTRIBUTING for more information.
This project is licensed under the Apache-2.0 License.