GET Certificates ID

The GET /Certificates/{id} operation returns details for the certificate with the specified ID. On success, the operation returns HTTP 200 OK with  certificate details.

Tip:  The following permissions (see Security Roles and Claims) are required to use this feature:
/certificates/collections/read/
OR
/certificates/collections/read/#/
OR
/certificate_stores/read/
OR
/certificate_stores/read/#/

Permissions for certificates can be set at the system-wide or resource-specific level. The appropriate level depends on how the certificates are accessed. See Certificate CollectionClosed The certificate search function allows you to query the Keyfactor Command database for certificates from any available source based on any criteria of the certificates and save the results as a collection that will be available in other places in the Management Portal (for example expiration alerts and certain reports). Permissions and Application Permissions for more information.

In permission strings, # represents a specific resource identifier. In /certificates/collections/ permission strings it refers to a certificate collection ID (for example, CollectionId) and in /certificate_stores/ permission strings it refers to a certificate store application ID (for example, containerId).

Table 280: GET Certificates {id} Input Parameters

Name In Description
id Path Required. An integer indicating the Keyfactor Command reference ID of the certificate.

Use the GET Certificates operation to retrieve a list of multiple certificates to determine the desired certificate's ID.

includeLocations Query A Boolean that sets whether to include the Locations data in the response (True or False). If False is selected, the LocationsCount and Locations fields will still appear in the response, but they will contain no data. The default is False.
includeMetadata Query A Boolean that sets whether to include the Metadata data in the response (True or False). If False is selected, the Metadata field will still appear in the response, but it will contain no data. The default is False.
CollectionId Query

An optional integer that specifies the certificate collection (CollectionId) to validate whether the user has sufficient permissions to perform the action. If a CollectionId is not provided, the user must have appropriate permissions granted system-wide or via certificate store applications.

Providing a CollectionId allows the system to check the user's permissions at the certificate collection level. Permissions are evaluated in the following order:

  1. System-wide certificate permissions
  2. Granular certificate permissions

Use either ContainerId or CollectionId, not both. If both are specified, CollectionId takes precedence, and the ContainerId is ignored (defaults to 0).

See Certificate Collection Permissions for more information.

ContainerId Query

An optional integer that specifies the certificate store application (ContainerId) to validate whether the user has sufficient permissions to perform the action. If a ContainerId is not provided, the user must have appropriate permissions granted system-wide or via certificate collections.

Providing a ContainerId allows the system to check the user's permissions at the application level. Permissions are evaluated in the following order:

  1. System-wide certificate store application permissions
  2. Granular certificate store application permissions

Use either ContainerId or CollectionId, not both. If both are specified, CollectionId takes precedence, and the ContainerId is ignored (defaults to 0).

See Application Permissions for more information.

Table 281: GET Certificates {id} Response Data

Name Description
AltKeySizeInBits An integer specifying the alternative key size in bits.
AltKeyType

This is considered deprecated and may be removed in a future release. See AltKeyAlgorithm.

AltKeyAlgorithm A string containing the OID in the format Friendly Name (OID).

For a full list of supported key algorithms in Keyfactor Command, see Algorithms and Key Types.

AltKeyTypeString

A string containing the alternative key type description (for example, ML-DSA-44).

For a full list of supported key algorithms in Keyfactor Command, see Algorithms and Key Types.

AltSigningAlgorithm

A string indicating the signing algorithm used by the CA to generate the alternative signature.

For a full list of supported key algorithms in Keyfactor Command, see Algorithms and Key Types.

ArchivedKey A Boolean that indicates whether the certificate has a key archived in the issuing CA (True or False).
CARecordId A string containing the CA's reference ID for certificate.
CARowIndex

An integer containing the CA's reference ID for certificate.

Note:  The CARowIndex has been replaced by CARecordId, but will remain for backward compatibility. It will only contain a non-zero value for certificates issued by Microsoft CAs. For Microsoft CA certificates, the CARowIndex will be equal to the CARecordId value parsed to an integer.
CertificateAuthorityId An integer indicating the Keyfactor Command reference ID of the certificate authority that issued the certificate.
CertificateAuthorityName A string indicating the certificate authority that issued the certificate.
CertRequestId An integer containing the Keyfactor Command reference ID of the certificate request.
CertState

An integer specifying the state of the certificate. ClosedShow certificate state details.

CertStateString A string containing the certificate state. The possible values are (see descriptions under CertState):
  • Unknown (0)
  • Active (1)
  • Revoked (2)
  • Certificate Authority (6)
  • Parent Certificate Authority (7)
CertStoreTypeShortNames An array of comma-separated strings indicating the certificate stores types associated with each certificate.
ContentBytes A string containing the certificate as bytes.
CRLDistributionPoints

An array of objects containing the distribution points for the certificate revocation lists the certificate could be in. ClosedShow CRL distribution point details.

Curve

A string indicating the OID of the elliptic curve algorithm configured for the certificate, for ECC templates. Well-known OIDs include:

  • 1.2.840.10045.3.1.7 = P-256/prime256v1/secp256r1

  • 1.3.132.0.34 = P-384/secp384r1

  • 1.3.132.0.35 = P-521/secp521r1

DetailedKeyUsage

An object containing details of the key usage configured for the certificate. ClosedShow detailed key usage details.

EnrollmentPatternId An integer indicating the enrollment pattern used for the certificate.
ExtendedKeyUsages

An array of objects containing the extended key usages associated with the certificate. ClosedShow Extended Key details.

HasAltPrivateKey A Boolean that indicates whether the certificate has an alternative private key stored in Keyfactor Command (True or False).
HasPrivateKey A Boolean that indicates whether the certificate has a private key stored in Keyfactor Command (True or False).
Id

An integer indicating the Keyfactor Command reference ID of the certificate.

Tip:  Certificate Id and Keyfactor Id both refer to the same value—the Keyfactor Command–assigned reference ID for a certificate. You may see either name in different parts of the Management Portal or Keyfactor API because Certificate Id was the original term, and Keyfactor Id is its newer replacement. The updated name helps avoid confusion with a different value—the certificate’s identifier on the issuing CA—which is now called the CA Record ID.
ImportDate The date, in UTC, on which the certificate was imported into Keyfactor Command.
IsCACertificate A Boolean that indicates whether the certificate is a CA certificate (True), or (False). It is only included in GET /Certificates/{id} (not GET /Certificates ). Returned for all certificates.
IssuedCN A string indicating the common name of the certificate.
IssuedDN A string indicating the distinguished name of the certificate.
IssuedEmail A string indicating the email address of the certificate.
IssuedOU A string indicating the organizational unit of the certificate.
IssuerDN A string indicating the distinguished name of the issuer.
KeyAlgorithm A string containing the OID in the format Friendly Name (OID).

For a full list of supported key algorithms in Keyfactor Command, see Algorithms and Key Types.

KeyRecoverable A Boolean that indicates whether the certificate key is recoverable at the CA level (True) or not (False).
KeySizeInBits An integer specifying the key size in bits.
KeyType

This is considered deprecated and may be removed in a future release. See KeyAlgorithm.

KeyTypeString

A string containing the key type description (for example, RSA).

For a full list of supported key algorithms in Keyfactor Command, see Algorithms and Key Types.

KeyUsage

An integer indicating the total key usage of the certificate. Key usage is stored in Keyfactor Command as a single value made up of a combination of values. ClosedShow value details.

For example, a value of 160 would represent a key usage of digital signature with key encipherment. A value of 224 would add nonrepudiation to those.

Lifespan The number of days of the beginning to end lifespan of a certificate, not to be confused with remaining validity.
Locations

An array of objects containing the locations where the certificate is found using certificate store inventorying. ClosedShow certificate store location details.

LocationsCount An array of objects containing a count of how many certificates are in each location type. This returns a list of type and count combination. For example:
Copy
"LocationsCount": [
   {
      "Type": "IIS",
      "Count": 2
   },
   {
      "Type": "F5-SL-REST",
      "Count": 1
   }
]
Metadata An object containing the metadata fields populated for the certificate.
NotAfter The date, in UTC, on which the certificate expires.
NotBefore The date, in UTC, on which the certificate was issued by the certificate authority.
OwnerRoleId An integer indicating the Keyfactor Command reference ID of the security role assigned as the certificate owner of the certificate.
OwnerRoleName

A string containing the name of the security role assigned as the certificate owner of the certificate.

PathLengthConstraint A value is only displayed if the certificate is a CA certificate which has a PathLenConstraint basic constraint defined. The value represents the maximum number of intermediate certificates allowed. It is included only in GET /Certificates/{id} (not GET /Certificates ). Returned only for CA certificates.
PrincipalId An integer indicating the Keyfactor Command reference ID of the principal (UPN) that requested the certificate. Typically, this field is only populated for end user certificates requested through Keyfactor Command. See also PrinicpalName.
PrincipalName A string containing the name of the principal (UPN) that requested the certificate. Typically, this field is only populated for end user certificates requested from Microsoft CAs through Keyfactor Command (for example, auto-enrolled certificates).
RequesterId An integer indicating the Keyfactor Command reference ID of the identity that requested the certificate. See also RequesterName.
RequesterName A string containing the name of the identity that requested the certificate.
RevocationComment An internally used Keyfactor Command field.
RevocationEffDate The date, in UTC, on which the certificate was revoked, if applicable.
RevocationReason

An integer indicating the reason the certificate was revoked. ClosedShow revocation reason details.

SerialNumber A string indicating the serial number of the certificate.
SigningAlgorithm A string indicating the signing algorithm used by the CA to generate the signature.
SSLLocations

An array of objects containing the locations where the certificate is found using SSL discovery. ClosedShow SSL location details.

SubjectAltNameElements

An array of objects containing the subject alternative name elements of the certificate. ClosedShow SAN details.

TemplateId An integer indicating the Keyfactor Command reference ID of the template associated with the certificate.
TemplateName A string indicating the display name of the template that was used when issuing the certificate.
Thumbprint A string indicating the thumbprint of the certificate.