trusts
Creates, updates, deletes, gets or lists a trusts resource.
Overview
| Name | trusts |
| Type | Resource |
| Id | aws.ds.trusts |
Fields
The following fields are returned by SELECT queries:
- describe_trusts
| Name | Datatype | Description |
|---|---|---|
created_date_time | string (date-time) | The date and time that the trust relationship was created. |
directory_id | string | The Directory ID of the Amazon Web Services directory involved in the trust relationship. (pattern: <code>^d-[0-9a-f]{10}$</code>) |
last_updated_date_time | string (date-time) | The date and time that the trust relationship was last updated. |
remote_domain_name | string | The Fully Qualified Domain Name (FQDN) of the external domain involved in the trust relationship. (pattern: <code>^([a-zA-Z0-9]+[\.-])+([a-zA-Z0-9])+[.]?$</code>) |
selective_auth | string | Current state of selective authentication for the trust. (Enabled, Disabled) |
state_last_updated_date_time | string (date-time) | The date and time that the TrustState was last updated. |
trust_direction | string | The trust relationship direction. (One-Way: Outgoing, One-Way: Incoming, Two-Way) |
trust_id | string | The unique ID of the trust relationship. (pattern: <code>^t-[0-9a-f]{10}$</code>) |
trust_state | string | The trust relationship state. (Creating, Created, Verifying, VerifyFailed, Verified, Updating, UpdateFailed, Updated, Deleting, Deleted, Failed) |
trust_state_reason | string | The reason for the TrustState. |
trust_type | string | The trust relationship type. Forest is the default. (Forest, External) |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
describe_trusts | select | region | Obtains information about the trust relationships for this account. If no input parameters are provided, such as DirectoryId or TrustIds, this request describes all the trust relationships belonging to the account. | |
create_trust | insert | region, DirectoryId, RemoteDomainName, TrustPassword, TrustDirection | Directory Service for Microsoft Active Directory allows you to configure trust relationships. For example, you can establish a trust between your Managed Microsoft AD directory, and your existing self-managed Microsoft Active Directory. This would allow you to provide users and groups access to resources in either domain, with a single set of credentials. This action initiates the creation of the Amazon Web Services side of a trust relationship between an Managed Microsoft AD directory and an external domain. You can create either a forest trust or an external trust. | |
update_trust | update | region, TrustId | Updates the trust that has been set up between your Managed Microsoft AD directory and an self-managed Active Directory. | |
delete_trust | delete | region | Deletes an existing trust relationship between your Managed Microsoft AD directory and an external domain. | |
verify_trust | exec | region, TrustId | Directory Service for Microsoft Active Directory allows you to configure and verify trust relationships. This action verifies a trust relationship between your Managed Microsoft AD directory and an external domain. |
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_trusts
Obtains information about the trust relationships for this account. If no input parameters are provided, such as DirectoryId or TrustIds, this request describes all the trust relationships belonging to the account.
SELECT
created_date_time,
directory_id,
last_updated_date_time,
remote_domain_name,
selective_auth,
state_last_updated_date_time,
trust_direction,
trust_id,
trust_state,
trust_state_reason,
trust_type
FROM aws.ds.trusts
WHERE region = '{{ region }}' -- required
;
INSERT examples
- create_trust
- Manifest
Directory Service for Microsoft Active Directory allows you to configure trust relationships. For example, you can establish a trust between your Managed Microsoft AD directory, and your existing self-managed Microsoft Active Directory. This would allow you to provide users and groups access to resources in either domain, with a single set of credentials. This action initiates the creation of the Amazon Web Services side of a trust relationship between an Managed Microsoft AD directory and an external domain. You can create either a forest trust or an external trust.
INSERT INTO aws.ds.trusts (
DirectoryId,
RemoteDomainName,
TrustPassword,
TrustDirection,
TrustType,
ConditionalForwarderIpAddrs,
ConditionalForwarderIpv6Addrs,
SelectiveAuth,
region
)
SELECT
'{{ DirectoryId }}' /* required */,
'{{ RemoteDomainName }}' /* required */,
'{{ TrustPassword }}' /* required */,
'{{ TrustDirection }}' /* required */,
'{{ TrustType }}',
'{{ ConditionalForwarderIpAddrs }}',
'{{ ConditionalForwarderIpv6Addrs }}',
'{{ SelectiveAuth }}',
'{{ region }}'
RETURNING
trust_id
;
# Description fields are for documentation purposes
- name: trusts
props:
- name: region
value: "{{ region }}"
description: Required parameter for the trusts resource.
- name: DirectoryId
value: "{{ DirectoryId }}"
description: |
The Directory ID of the Managed Microsoft AD directory for which to establish the trust relationship.
- name: RemoteDomainName
value: "{{ RemoteDomainName }}"
description: |
The Fully Qualified Domain Name (FQDN) of the external domain for which to create the trust relationship.
- name: TrustPassword
value: "{{ TrustPassword }}"
description: |
The trust password. The trust password must be the same password that was used when creating the trust relationship on the external domain.
- name: TrustDirection
value: "{{ TrustDirection }}"
description: |
The direction of the trust relationship.
valid_values: ['One-Way: Outgoing', 'One-Way: Incoming', 'Two-Way']
- name: TrustType
value: "{{ TrustType }}"
description: |
The trust relationship type. Forest is the default.
valid_values: ['Forest', 'External']
- name: ConditionalForwarderIpAddrs
value:
- "{{ ConditionalForwarderIpAddrs }}"
description: |
The IP addresses of the remote DNS server associated with RemoteDomainName.
- name: ConditionalForwarderIpv6Addrs
value:
- "{{ ConditionalForwarderIpv6Addrs }}"
description: |
The IPv6 addresses of the remote DNS server associated with RemoteDomainName.
- name: SelectiveAuth
value: "{{ SelectiveAuth }}"
description: |
Optional parameter to enable selective authentication for the trust.
valid_values: ['Enabled', 'Disabled']
UPDATE examples
- update_trust
Updates the trust that has been set up between your Managed Microsoft AD directory and an self-managed Active Directory.
UPDATE aws.ds.trusts
SET
TrustId = '{{ TrustId }}',
SelectiveAuth = '{{ SelectiveAuth }}'
WHERE
region = '{{ region }}' --required
AND TrustId = '{{ TrustId }}' --required
RETURNING
request_id,
trust_id;
DELETE examples
- delete_trust
Deletes an existing trust relationship between your Managed Microsoft AD directory and an external domain.
DELETE FROM aws.ds.trusts
WHERE region = '{{ region }}' --required
;
Lifecycle Methods
- verify_trust
Directory Service for Microsoft Active Directory allows you to configure and verify trust relationships. This action verifies a trust relationship between your Managed Microsoft AD directory and an external domain.
EXEC aws.ds.trusts.verify_trust
@region='{{ region }}' --required
@@json=
'{
"TrustId": "{{ TrustId }}"
}'
;