certificates
Creates, updates, deletes, gets or lists a certificates resource.
Overview
| Name | certificates |
| Type | Resource |
| Id | aws.ds.certificates |
Fields
The following fields are returned by SELECT queries:
- describe_certificate
- list_certificates
| Name | Datatype | Description |
|---|---|---|
certificate_id | string | The identifier of the certificate. (pattern: <code>^c-[0-9a-f]{10}$</code>) |
client_cert_auth_settings | object | A ClientCertAuthSettings object that contains client certificate authentication settings. |
common_name | string | The common name for the certificate. |
expiry_date_time | string (date-time) | The date and time when the certificate will expire. |
registered_date_time | string (date-time) | The date and time that the certificate was registered. |
state | string | The state of the certificate. (Registering, Registered, RegisterFailed, Deregistering, Deregistered, DeregisterFailed) |
state_reason | string | Describes a state change for the certificate. |
type | string | The function that the registered certificate performs. Valid values include ClientLDAPS or ClientCertAuth. The default value is ClientLDAPS. (ClientCertAuth, ClientLDAPS) |
| Name | Datatype | Description |
|---|---|---|
certificate_id | string | The identifier of the certificate. (pattern: <code>^c-[0-9a-f]{10}$</code>) |
common_name | string | The common name for the certificate. |
expiry_date_time | string (date-time) | The date and time when the certificate will expire. |
state | string | The state of the certificate. (Registering, Registered, RegisterFailed, Deregistering, Deregistered, DeregisterFailed) |
type | string | The 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:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
describe_certificate | select | region | Displays information about the certificate registered for secure LDAP or client certificate authentication. | |
list_certificates | select | region | For the specified directory, lists all the certificates registered for a secure LDAP or client certificate authentication. | |
register_certificate | insert | region, DirectoryId, CertificateData | Registers a certificate for a secure LDAP or client certificate authentication. | |
deregister_certificate | delete | region | Deletes 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.
| Name | Datatype | Description |
|---|---|---|
region | string | AWS region (default: us-east-1) |
SELECT examples
- describe_certificate
- list_certificates
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
;
For the specified directory, lists all the certificates registered for a secure LDAP or client certificate authentication.
SELECT
certificate_id,
common_name,
expiry_date_time,
state,
type
FROM aws.ds.certificates
WHERE region = '{{ region }}' -- required
;
INSERT examples
- register_certificate
- Manifest
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
;
# Description fields are for documentation purposes
- name: certificates
props:
- name: region
value: "{{ region }}"
description: Required parameter for the certificates resource.
- name: DirectoryId
value: "{{ DirectoryId }}"
description: |
The identifier of the directory.
- name: CertificateData
value: "{{ CertificateData }}"
description: |
The certificate PEM string that needs to be registered.
- name: Type
value: "{{ Type }}"
description: |
The function that the registered certificate performs. Valid values include ClientLDAPS or ClientCertAuth. The default value is ClientLDAPS.
valid_values: ['ClientCertAuth', 'ClientLDAPS']
- name: ClientCertAuthSettings
description: |
A ClientCertAuthSettings object that contains client certificate authentication settings.
value:
OCSPUrl: "{{ OCSPUrl }}"
DELETE examples
- deregister_certificate
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
;