Create or update a trusted certificate

Purpose

Creates or updates a trusted certificate's security profile by applying the trusted certificate to Eclipse Amlen. A certificate profile is used by a security profile to define the server certificate that is used to control Transport Layer Security (TLS).

URI

Use the Eclipse Amlen REST API POST method with the following Eclipse Amlen configuration URI:

http://<admin-endpoint-IP:Port>/ima/v1/configuration/

Object configuration data

Provide TrustedCertificate object configuration data in the payload of the POST method by using the following schema. Content-type is set to application/json:


{ "TrustedCertificate": [     
     { "TrustedCertificate":"<NameOfTrustedCertificate>",
      "SecurityProfileName": "string",      
      "Overwrite": true|false
     }
  ]
}
Where:
NameOfTrustedCertificate
Required.
Specifies a name for the trusted certificate.
The name can be a maximum of 255 alphanumeric characters.
The name must not have leading or trailing spaces and cannot contain control characters, commas, double quotation marks, backslashes, or equal signs. The first character must not be a number.
After the profile is created, this name cannot be changed.
SecurityProfileName
Required if you are creating a trusted certificate.
Specifies the name of the security profile that the trusted certificate is associated with.
Overwrite: true|false
Specifies whether an existing certificate is overwritten if it has the same name.
The default value is false which means that an existing certificate is not overwritten if it has the same name.

Usage NotesĀ®

  • You must copy the certificate to the server before you can apply it. Copy a file from the local machine to Eclipse Amlen to copy the certificate.
  • The certificate must be a pem format certificate.
  • You can upload a maximum of 100 trusted client certificates for every security profile.
  • Capitalization and double quotation marks must be used as shown.

Related REST Administration APIs

Example

Creates a trusted certificate called "MyTrustedCertificate" by using cURL:

curl -X POST \
   -H 'Content-Type: application/json'  \
   -d  '{"TrustedCertificate": [{   
         "SecurityProfileName": "exampleSecProfile",
         "TrustedCertificate": "MyTrustedCertificate",
         "Overwrite": true          
        }]}
      '  \
http://127.0.0.1:9089/ima/v1/configuration/
An example response to the POST method:

{        
  "Version": "v1",
  "Code": "CWLNA6011",
  "Message": "The requested configuration change has completed successfully."
}