certificate_policies
Creates, updates, deletes, gets or lists a certificate_policies resource.
Overview
| Name | certificate_policies |
| Type | Resource |
| Id | azure.key_vault_certificates.certificate_policies |
Fields
The following fields are returned by SELECT queries:
- get_certificate_policy
| Name | Datatype | Description |
|---|---|---|
id | string | The certificate id. |
attributes | object | The certificate attributes. |
issuer | object | Parameters for the issuer of the X509 component of a certificate. |
key_props | object | Properties of the key backing a certificate. |
lifetime_actions | array | Actions that will be performed by Key Vault over the lifetime of a certificate. |
platformManaged | object | Configuration that enables the platform to manage the certificate on behalf of the user. This feature is currently intended for internal use only. |
secret_props | object | Properties of the secret backing a certificate. |
x509_props | object | Properties of the X509 component of a certificate. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_certificate_policy | select | certificate_name, vault_name | Lists the policy for a certificate. The GetCertificatePolicy operation returns the specified certificate policy resources in the specified key vault. This operation requires the certificates/get permission. | |
update_certificate_policy | update | certificate_name, vault_name | Updates the policy for a certificate. Set specified members in the certificate policy. Leave others as null. This operation requires the certificates/update permission. |
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 |
|---|---|---|
certificate_name | string | The name of the certificate in the given vault. Required. |
vault_name | string | Key vault name. (default: ) |
SELECT examples
- get_certificate_policy
Lists the policy for a certificate. The GetCertificatePolicy operation returns the specified certificate policy resources in the specified key vault. This operation requires the certificates/get permission.
SELECT
id,
attributes,
issuer,
key_props,
lifetime_actions,
platformManaged,
secret_props,
x509_props
FROM azure.key_vault_certificates.certificate_policies
WHERE certificate_name = '{{ certificate_name }}' -- required
AND vault_name = '{{ vault_name }}' -- required
;
UPDATE examples
- update_certificate_policy
Updates the policy for a certificate. Set specified members in the certificate policy. Leave others as null. This operation requires the certificates/update permission.
UPDATE azure.key_vault_certificates.certificate_policies
SET
key_props = '{{ key_props }}',
secret_props = '{{ secret_props }}',
x509_props = '{{ x509_props }}',
lifetime_actions = '{{ lifetime_actions }}',
issuer = '{{ issuer }}',
attributes = '{{ attributes }}',
platformManaged = '{{ platformManaged }}'
WHERE
certificate_name = '{{ certificate_name }}' --required
AND vault_name = '{{ vault_name }}' --required
RETURNING
id,
attributes,
issuer,
key_props,
lifetime_actions,
platformManaged,
secret_props,
x509_props;