Import a Trusted Certificate into a KSS Keystore

Imports a trusted certificate into a Keystore Service (KSS) keystore.

REST Request

POST /idaas/platform/admin/v1/keystoreservice/certificates

Request Body

Media Types: application/json

The response body contains information about the import request, including:

Attribute Description
"keyAlias" Alias for the trusted certificate.
"keystoreEntry" Base64-encoded certificate.
"keystoreEntryType" Keystore entry type. Valid values include: Certificate, TrustedCertificate, or SecretKey.
"keystoreName" Name of the KSS keystore.
"keystorePassword" Password for the KSS keystore.
"stripeName" Name of the stripe.

Response Body

Media Types: application/json

The response body returns the status of the import operation, including:

Attribute Description
"ERROR_CODE" If "STATUS" is set to "Failed", provides the error code.
"ERROR_MSG" If "STATUS" is set to "Failed", provides the contents of the error message.
"STATUS" Status of operation. For example, "Succeeded" or "Failed".
"SUBJECT_DN" Subject DN list that was imported.

cURL Example

The following example shows how to create a KSS keystore by submitting a POST request on the REST resource using cURL. For more information, see "cURL Access".

curl -i -X POST -u username:password --data @importcertkss.json -H Content-Type:application/json http://myhost:7001/idaas/platform/admin/v1/keystoreservice/certificates

Example of Request Body

The following shows an example of the request body in JSON format.

{
    "keyAlias" : "myAlias",
    "keystoreEntry":
"Base64-encoded certificate",
    "keystoreEntryType" : "TrustedCertificate",
    "keystoreName" : "myKeystore",
    "stripeName" : "myStripe",
    "keystorePassword" : "password"
}

Example of Response Header

The following shows an example of the response header.

HTTP/1.1 200 OK

Example of Response Body

The following shows an example of the response body in JSON format.

{
    "STATUS": "Succeeded"
    "SUBJECT_DN": "CN=y,OU=y,O=y,L=y,ST=y,C=y"
}