Skip to main content

certificates

Creates, updates, deletes, gets or lists a certificates resource.

Overview​

Namecertificates
TypeResource
Idaws.ds.certificates

Fields​

The following fields are returned by SELECT queries:

NameDatatypeDescription
certificate_idstringThe identifier of the certificate. (pattern: <code>^c-[0-9a-f]{10}$</code>)
client_cert_auth_settingsobjectA ClientCertAuthSettings object that contains client certificate authentication settings.
common_namestringThe common name for the certificate.
expiry_date_timestring (date-time)The date and time when the certificate will expire.
registered_date_timestring (date-time)The date and time that the certificate was registered.
statestringThe state of the certificate. (Registering, Registered, RegisterFailed, Deregistering, Deregistered, DeregisterFailed)
state_reasonstringDescribes a state change for the certificate.
typestringThe function that the registered certificate performs. Valid values include ClientLDAPS or ClientCertAuth. The default value is ClientLDAPS. (ClientCertAuth, ClientLDAPS)

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
describe_certificateselectregionDisplays information about the certificate registered for secure LDAP or client certificate authentication.
list_certificatesselectregionFor the specified directory, lists all the certificates registered for a secure LDAP or client certificate authentication.
register_certificateinsertregion, DirectoryId, CertificateDataRegisters a certificate for a secure LDAP or client certificate authentication.
deregister_certificatedeleteregionDeletes from the system the certificate that was registered for secure LDAP or client certificate authentication.

Parameters​

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples​

Displays information about the certificate registered for secure LDAP or client certificate authentication.

SELECT
certificate_id,
client_cert_auth_settings,
common_name,
expiry_date_time,
registered_date_time,
state,
state_reason,
type
FROM aws.ds.certificates
WHERE region = '{{ region }}' -- required
;

INSERT examples​

Registers a certificate for a secure LDAP or client certificate authentication.

INSERT INTO aws.ds.certificates (
DirectoryId,
CertificateData,
Type,
ClientCertAuthSettings,
region
)
SELECT
'{{ DirectoryId }}' /* required */,
'{{ CertificateData }}' /* required */,
'{{ Type }}',
'{{ ClientCertAuthSettings }}',
'{{ region }}'
RETURNING
certificate_id
;

DELETE examples​

Deletes from the system the certificate that was registered for secure LDAP or client certificate authentication.

DELETE FROM aws.ds.certificates
WHERE region = '{{ region }}' --required
;