docs: IA reorganization (#5838)

* docs: IA reorganization

* docs: Updates

* docs: Updates

* docs: Fix links

* docs: Updates

* docs: Fix a typo

* docs: Fix client agent topic

* docs: Update Client Agent nav

* docs: Fix conflict

* docs: Fix a typo in Client Agent docs (#5853)

* docs: Fix client agent topic

* docs: Updates

* docs: Updates

* docs: Updates

* docs: Updates

* docs: Fixes get started and operations links

* docs: Update nav

* docs: Partials

* docs: Unix partials

* docs: Worker partials

* docs: Updates

* docs: Update workers and targets

* docs: Updates

* docs: Updates

* docs: Fixes link

* docs: Updates after sync review

* docs: Updates from review feedback

* docs: Move worker filter examples

* docs: Fix links

* docs: Updates for filters based on working session

* docs: Fixes broken links

* docs: Add links to other filter topics

* docs: Update list intro

* docs: Adds link

* docs: Fixes redirects

* docs: Fixes redirects

* docs: Deleted mysql page from TOC

* docs: Add versioned redirect

* docs: Adds versioned redirects

* docs: Adds versioned redirects

* docs: Update redirects

* docs: Update redirects

* docs: Redirect fixes

* docs: Update redirect format

* docs: Fix a typo

* docs: Fixes redirects

* docs: Fixes redirect

* docs: Adds links out to client agent troubleshooting

* uses /etc/boundary.d/ as recommended installation directory (#6003)

* docs: Updates legacy io links

* docs: Fixes redirects

* docs: Fix redirect

* docs: Restoring deleted file

---------

Co-authored-by: Robin Beck <stellarsquall@users.noreply.github.com>
This commit is contained in:
Dan HeathandRobin Beck authored and GitHub committed 2025-09-03 15:45:38 -04:00
1 parent 21fce7c5eb
commit 5ce6515156
253 files changed
+7897 -5673

No files matched your search

@@ -134,7 +134,7 @@ The `api_rate_limit` configuration stanza contains the following fields:
- `unlimited` - Indicates that the corresponding resources and actions should not be rate limited.
If you set this value to `true`, you should not specify values for the `limit` and `period` or you will receive an error.
For more information about how API rate limiting works, refer to the [API rate limiting](/boundary/docs/api-clients/api#rate-limiting) documentation.
For more information about how API rate limiting works, refer to the [API rate limiting](/boundary/docs/api/rate-limiting) documentation.
- `api_rate_limit_disable` - Disables API rate limiting, if set to `true`.
If `api_rate_limit_disable` is set to `true`, and you have provided any `api_rate_limit` stanzas, you will receive an error.
@@ -1,78 +0,0 @@
---
layout: docs
page_title: Configure targets with credential brokering
description: >-
Configure credential brokering workflows so that Boundary centrally manages credentials and returns them to users when they successfully connect to a target.
---
# Configure targets with credential brokering
The following section provides steps to configure your targets with credential brokering.
When you use credential brokering, Boundary returns credentials to the user when they successfully connect to a target.
## Requirements
- You must have an existing target available. To use brokered credentials to connect to a target that runs SSH, you must use a TCP target type.
- You must have configured either a static credential store or a Vault credential store:
- To configure a static credential store, refer to [Create static credential stores](/boundary/docs/configuration/credential-management/static-cred-boundary).
- To configure a Vault credential store and credential library, refer to [Create Vault credential stores](/boundary/docs/configuration/credential-management/static-cred-vault).
- You must have a static credential saved in your static credential store or Vault credential store. The credential must correspond to the target you want to authenticate to.
## Configuration
Complete the following steps to configure credential brokering for a target:
<Tabs>
<Tab heading="UI" group="ui">
1. Log in to Boundary.
1. Select **Orgs** on the navigation pane.
1. Select your desired org.
1. Select the project where your target resides.
1. Click **Targets** on the navigation pane.
1. Click on the target you want to configure for credential brokering.
1. Click on the **Brokered Credential** tab.
1. Click **Managed** and select **Add Brokered Credential** in the pull down menu.
1. Do one of the following:
- **If you are using a static credential store**: Select the credential that corresponds to your target and click **Add Brokered Credentials**.
- **If you are using a Vault credential store**: Select the credential library that corresponds to your target and click **Add Brokered Credentials**.
</Tab>
<Tab heading="CLI" group="cli">
1. Log into Boundary.
```shell-session
$ boundary authenticate
Please enter the login name (it will be hidden):
Please enter the password (it will be hidden):
```
1. Add brokered credentials to target.
```shell-session
$ boundary targets add-credential-sources \
-id ttcp_vO60a7TwpI \
-application-credential-source csvlt_Xqa6V6QwfM
```
<Tip>
If you are using a static credential store, `brokered-credential-source` refers to the ID of a **credential** in the static credential store.
If you are using a Vault credential store, `brokered-credential-source` refers to the ID of a **credential library** in the Vault credential store.
</Tip>
</Tab>
</Tabs>
## More information
Refer to the following topics for more information:
- [Create static credential stores](/boundary/docs/configuration/credential-management/static-cred-boundary)
- [Create Vault credential stores](/boundary/docs/configuration/credential-management/static-cred-vault)
- [Target types](/boundary/docs/concepts/domain-model/targets#target-types)
@@ -1,85 +0,0 @@
---
layout: docs
page_title: Configure targets with credential injection
description: >-
Configure credential injection so Boundary provides users with a passwordless experience when connecting to targets. Availabile exclusively for Enterprise users.
---
# Configure targets with credential injection
<EnterpriseAlert product="boundary">This feature requires <a href="https://www.hashicorp.com/products/boundary">HCP Boundary or Boundary Enterprise</a></EnterpriseAlert>
The following section provides steps to configure your targets with credential injection.
Credential injection provides end users with a passwordless experience when they connect to targets.
## Requirements
- This feature requires either <a href="https://www.hashicorp.com/products/boundary">HCP Boundary or Boundary Enterprise</a>
- You must have an existing target available. If you use the SSH target type, the target must be configured with an injected application credential.
- You must have configured either a static credential store or a Vault credential store:
- To configure a static credential store, refer to [Create static credential stores](/boundary/docs/configuration/credential-management/static-cred-boundary).
- To configure a Vault credential store and credential library, refer to [Create Vault credential stores](/boundary/docs/configuration/credential-management/static-cred-vault).
- You must have a static credential saved in your static credential store or Vault credential store. The credential must correspond to the target to which you want to authenticate.
- Keyboard-interactive authentication is not supported. When you use Username password credentials, ensure that your SSH server is configured to allow password authentication.
## Configuration
Complete the following steps to configure targets with credential injection:
<Tabs>
<Tab heading="UI" group="ui">
1. Log in to Boundary.
1. Select **Orgs** on the navigation pane.
1. Select your desired org.
1. Select the project where your target resides.
1. Click **Targets** on the navigation pane.
1. Click on your target you want to configure for credential injection.
1. Click on the **Injected Application Credential** tab.
1. Click **Managed** and select **Add Injected Application Credential** in the pull down menu.
1. Do one of the following:
- **If you are using a static credential store**: Select the credential that corresponds to your target and click **Add Injected Application Credential**.
- **If you are using a Vault credential store**: Select the credential library that corresponds to your target and click **Add Injected Application Credential**.
</Tab>
<Tab heading="CLI" group="cli">
1. Log into Boundary.
```shell-session
$ boundary authenticate
Please enter the login name (it will be hidden):
Please enter the password (it will be hidden):
```
1. Add credential injection to target.
```shell-session
$ boundary targets add-credential-sources \
-id ttcp_vO60a7TwpI \
-injected-application-credential-source csvlt_Xqa6V6QwfM
```
<Tip>
If you are using a static credential store, `brokered-credential-source` refers to the ID of a **credential** in the static credential store.
If you are using a Vault credential store, `brokered-credential-source` refers to the ID of a **credential library** in the Vault credential store.
</Tip>
</Tab>
</Tabs>
## More information
Refer to the following topics for more information:
- [Create static credential stores](/boundary/docs/configuration/credential-management/static-cred-boundary)
- [Create Vault credential stores](/boundary/docs/configuration/credential-management/static-cred-vault)
- [Target types](/boundary/docs/concepts/domain-model/targets#target-types)
- [Credentials](/boundary/docs/concepts/domain-model/credentials)
@@ -1,46 +0,0 @@
---
layout: docs
page_title: Credential management with Boundary
description: >-
Credential stores let you store and manage credentials in Boundary. Learn about configuring user workflows with credential management or credential injection.
---
# Overview
When users connect to a target machine, they typically need a set of credentials for authentication. Rather than requiring users to securely store and manage credentials for every target resource, Boundary centralizes credential management to enhance security.
## Credential stores
Boundary supports credential management using [credential stores](/boundary/docs/concepts/domain-model/credential-stores), which are resources that store credentials for various targets.
There are two types of credential stores:
1. Static credential store
1. Vault credential store
Static credential stores are built into Boundary and only store static credentials like username and password, or keypairs. Vault credential stores point to a HashiCorp Vault instance, which provides additional capabilities like generating short-lived dynamic credentials.
Boundary can retrieve credentials from the credential stores and present them back to the user when they connect to targets. This workflow is referred to as **credential brokering**. Boundary can also inject credentials directly into the session on behalf of the user. This workflow is referred to as **credential injection**.
## End user workflows
End users can experience three workflows when they connect to a target. In the first workflow, when an end user connects to a target, Boundary initiates the session, but the end user must know the credentials to authenticate into the session. This workflow is available for testing purposes, but it is not recommended because it places the burden on the users to securely store and manage credentials.
The second workflow uses a feature called credential brokering, where credentials are retrieved from a credentials store and returned back to the end user. The end user then enters the credentials into the session when prompted by the target. This workflow is more secure than the first workflow since credentials are centrally managed through Boundary. For more information, refer to the the [Credential brokering](/boundary/docs/concepts/credential-management#credential-brokering) concepts page.
The third workflow uses a featured called credential injection, where credentials are retrieved from a credential store and injected directly into the session on behalf of the end user. This workflow is the most secure because credentials are not exposed to the end user, reducing the chances of a leaked credential. This workflow is also more streamlined as the user goes through a passwordless experience. For more information, refer to the [Credential injection](/boundary/docs/concepts/credential-management#credential-injection) concepts page.
The type of target you connect to also determines which credential workflows you can configure.
An SSH target must have at least one injected application credential to establish the SSH connection.
A TCP target cannot have any injected application credentials.
For more information, refer to the [Target types](/boundary/docs/concepts/domain-model/targets#target-types) documentation.
## Next steps
The following pages provide steps to configure static credentials using both a static credential store and a Vault credential store. You can also configure targets for either credential brokering or credential injection workflows.
- [Create a static credential store](/boundary/docs/configuration/credential-management/static-cred-boundary)
- [Create a Vault credential store](/boundary/docs/configuration/credential-management/static-cred-vault)
- [Configure targets with credential brokering](/boundary/docs/configuration/credential-management/configure-credential-brokering)
- [Configure targets with credential injection](/boundary/docs/configuration/credential-management/configure-credential-injection)
@@ -1,110 +0,0 @@
---
layout: docs
page_title: Manage static credentials with Boundary
description: >-
Create a static credential store to manage static credentials. Credential stores let you configure targets for credential brokering or injection.
---
# Create a static credential store
You can manage credentials in Boundary using [credential stores](/boundary/docs/concepts/domain-model/credential-stores), which are resources that store credentials for various targets.
Static credential stores are built into Boundary and only store static credentials like username and password or keypairs.
## Requirements
Ensure that you have an [Org scope and a project scope](/boundary/docs/commands/scopes/create) created in your Boundary instance.
## Configuration
Complete the following steps to create a static credential store:
<Tabs>
<Tab heading="UI" group="ui">
1. Log in to Boundary
1. Select **Orgs** on the navigation pane.
1. Select your desired org.
1. Select the project to which your static credential store should belong.
1. Select **Credential Stores** on the navigation pane.
1. Select **New Credential Store**.
1. Provide a name for your credential store and select type **Static**.
1. Click **Save**. You now have a static credential store where you can store static credentials.
1. (Optional) If you have a static credential, you can add it into the static credential store. Static credential types can be a username and password, username and private key, or JSON blob.
a. In your static credential store, click on the **Credentials** tab.
b. Click **Manage**, and then select **New Credential** from the pull down menu.
c. Complete the following fields to add static credentials to your static credential store:
- Name (optional) - The name is optional, but if you enter a name, it must be unique.
- Description (optional) - An optional description of the credential for identification purposes.
- Type - The type of static credential you want to add. Select between username and password, username and keypair, or a JSON blob.
- Credential data - Depending on the credential type selected, enter the credential data.
d. Click **Save**.
</Tab>
<Tab heading="CLI" group="cli">
1. Log into Boundary.
```shell-session
$ boundary authenticate
Please enter the login name (it will be hidden):
Please enter the password (it will be hidden):
```
1. Create a credential store and provide a name and project ID.
```shell-session
$ boundary credential-stores create static \
-scope-id p_VHAKTCEKcU \
-name "my-static-credential-store"
```
1. (Optional) If you have a static credential, you can add it into the static credential store using one of the following commands, based on the type of credential. Static credential types can be a username and password, username and keypair, or JSON blob.
- For username and password credentials:
```shell-session
$ boundary credentials create username-password \
-name "test-credentials" \
-credential-store-id csst_O8utI0b3XC \
-username <username> \
-password env://<MY_PASSWORD_ENV_VAR>
```
To prevent credentials from being logged in the terminal, you must place passwords in an environment variable or file, and pass them to the `-password` option using the `env://` or `file://` syntax.
- For username and private key credentials:
```shell-session
$ boundary credentials create ssh-private-key \
-credential-store-id csst_O8utI0b3XC \
-username <username> \
-private-key file://<my_ssh_key_file>
```
To prevent credentials from being logged in the terminal, you must place SSH private keys in an environment variable or file, and pass them to the `-private-key` option using the `env://` or `file://` syntax.
- For JSON blob credentials:
```shell-session
$ boundary credentials create json \
-credential-store-id csst_O8utI0b3XC \
-object file://<my_json_file_path>
```
To prevent credentials from being logged in the terminal, you must place the JSON map value in a file, and pass it to the `-object` option using the `file://` syntax.
</Tab>
</Tabs>
## Next steps
Once you have created a credential store, you can configure targets for credential brokering or credential injection.
When you use credential brokering, Boundary centrally manages credentials and returns them to the user when they attempt to connect to a target.
Credential injection requires HCP Boundary or Boundary Enterprise, and it provides end users with a passwordless experience when they connect to targets.
- [Configure a target for credential brokering](/boundary/docs/configuration/credential-management/configure-credential-brokering)
- [Configure a target for credential injection](/boundary/docs/configuration/credential-management/configure-credential-brokering)
@@ -1,105 +0,0 @@
---
layout: docs
page_title: Manage static credentials with Vault
description: >-
Create a Vault credential store to manage credentials. Credential stores let you configure targets for credential brokering or credential injection.
---
# Create a Vault credential store
You can manage credentials in Boundary using [credential stores](/boundary/docs/concepts/domain-model/credential-stores), which are resources that store credentials for various targets.
Vault credential stores point to a HashiCorp Vault instance, which provides capabilities like generating short-lived dynamic credentials.
## Requirements
- You must have a Vault instance available with an address or URL that is reachable from your Boundary instance. This will be used to connect Boundary to Vault.
- You must have static credentials stored in Vault’s key/value secrets engine. Examples of static credential types include username and password or username and SSH private key.
- You must have a Vault token for Boundary to authenticate and access your static credentials.
## Configuration
Complete the following steps to create a Vault credential store:
<Tabs>
<Tab heading="UI" group="ui">
1. Log in to Boundary.
1. Select **Orgs** on the navigation pane.
1. Select your desired org.
1. Select the project to which your static credential store should belong.
1. Select **Credential Stores** on the navigation pane.
1. Select **New Credential Store**.
1. Provide a name for your credential store and select type **Vault**.
1. Complete the fields related to your Vault instance:
- **Address** - The address of your Vault instance.
- **Worker Filter** (optional) - If your Vault instance does not have a publicly accessible address and instead is proxied through a Boundary worker, enter the worker filter. This should be a boolean expression. To generate a worker filter in the correct format, toggle the **Show filter generator** switch. Refer to the examples in the [Worker tags](/boundary/docs/concepts/filtering/worker-tags) documentation.
- **Token** - Token provided by Vault that provides access to the static credentials within your Vault instance.
- **Namespace** (optional) - Vault namespace. Requires Vault Enterprise.
- **TLS Server Name** (optional) - Name to use as the SNI host if you connect to Vault via TLS.
- **Client Certificate** (optional) - A PEM-encoded client certificate to use for TLS authentication to the Vault server.
- **Client Certificate key** (optional) - A PEM-encoded private key that matches the client certificate from client certificate.
- **CA Certificate** (optional) - A PEM-encoded CA certificate to verify the Vault server's TLS certificate.
1. Click **Save**. You now have a static credential store where you can store static credentials.
1. In your newly created Vault credential store, click on the **Credential Libraries** tab.
1. Click **Manage**, and then select **New Credential Library** in the pull down menu.
1. Complete the fields related to the static credentials stored in your Vault instance:
- **Name** (optional) - The name is optional, but if you enter a name, it must be unique within the parent credential store.
- **Type** - Select **Generic Secrets**.
- **Vault Path** - Enter the path for the location of your static credentials stored in Vault. Boundary uses this field to locate the static credentials inside Vault.
- **Credential Type** - Select the appropriate credential type that matches the static credential stored in Vault.
- **HTTP Method** - Select **GET**.
1. Click **Save**.
</Tab>
<Tab heading="CLI" group="cli">
1. Log into Boundary.
```shell-session
$ boundary authenticate
Please enter the login name (it will be hidden):
Please enter the password (it will be hidden):
```
1. Create a credential store and provide a name and project ID.
```shell-session
$ boundary credential-stores create vault \
-scope-id p_VHAKTCEKcU \
-name "vault-cred-store-test"
```
1. Create a credential library using one of the following commands, based on the type of credential.
- For username and password credentials:
```shell-session
$ boundary credential-libraries create vault-generic \
-name "vault-cred-lib-test" \
-credential-store-id csvlt_Xqa6V6QwfM \
-credential-type username_password \
-vault-path "path/to/vault/credentials"
```
- For username and private key credentials:
```shell-session
$ boundary credential-libraries create vault-generic \
-name "vault-cred-lib-test" \
-credential-store-id csvlt_Xqa6V6QwfM \
-credential-type ssh_private_key \
-vault-path "path/to/vault/credentials"
```
</Tab>
</Tabs>
## Next steps
Once you have created a credential store, you can configure targets for credential brokering or credential injection.
When you use credential brokering, Boundary centrally manages credentials and returns them to the user when they attempt to connect to a target.
Credential injection requires HCP Boundary or Boundary Enterprise, and it provides end users with a passwordless experience when they connect to targets.
- [Configure a target for credential brokering](/boundary/docs/configuration/credential-management/configure-credential-brokering)
- [Configure a target for credential injection](/boundary/docs/configuration/credential-management/configure-credential-brokering)
@@ -0,0 +1,22 @@
---
layout: docs
page_title: Common sink parameters
description: |-
The common sink parameters for all sink types.
---
# Common sink parameters
@include '/configuration-reference/events/common-sink-intro.mdx'
## `audit_config` parameters
@include '/configuration-reference/events/common-audit_config-parameters.mdx'
### `audit_filter_overrides` parameters
@include '/configuration-reference/events/common-audit_filter_overrides-parameters.mdx'
## `audit_config` examples
@include '/configuration-reference/events/common-audit_config-examples.mdx'
@@ -1,86 +0,0 @@
---
layout: docs
page_title: Controller/worker - events - common sink parameters
description: |-
The common sink parameters for all sink types.
---
# Common sink parameters
These parameters are shared across all sink types:
- `name` - Specify a name for the sink.
- `description` - Specify a description for the sink.
- `event_types` - Specifies a list of event types that will be sent to the sink.
Can be `*`, `audit`, `error`, `observation`, `system`, or `telemetry`.
- `event_source_url` - Specifies an optional event source URL for the sink. If
not specified, the default source will be composed of the
`https://hashicorp.com/boundary.io/ServerName/Path/FileName`.
- `allow_filters` - Specifies a set of predicates for including an event in the
sink. If any filter matches, the event will be included. For more information,
on using filters see: [event filtering](/boundary/docs/concepts/filtering/events)
- `deny_filters` - Specifies a set predicates for excluding an event in the
sink. If any filter matches, the event will be excluded. For more information
on using filters see: [event filtering](/boundary/docs/concepts/filtering/events)
- `format` - Specifies the format for the sink. Can be `cloudevents-json`,
`cloudevents-text`, `hclog-json`, or `hclog-text`.
- `type` - Specifies the type of sink. Can be `stderr` or `file`.
- `audit_config` - Specifies configuration for the processing of audit events
for the sink. This is ignored if the sink is not configured to receive
`audit` events.
## `audit_config` parameters
- `audit_filter_overrides` - Specifies overrides for the filter operations that
are applied to audit events.
### `audit_filter_overrides` parameters
- `sensitive` `(string: "", "encrypt", "hmac-sha256", "redact")` - Specifies
the filter operation to apply to fields that are classified as sensitive.
- `secret` `(string: "", "encrypt", "hmac-sha256", "redact")` - Specifies
the filter operation to apply to fields that are classified as secret.
## `audit_config` examples
This example is equivalent to the default settings if no `audit_config` stanza
is provided.
```hcl
audit_config {
audit_filter_overrides {
sensitive = "redact"
secret = "redact"
}
}
```
This example will HMAC sensitive fields, and encrypt secrets.
```hcl
audit_config {
audit_filter_overrides {
sensitive = "hmac-sha256"
secret = "encrypt"
}
}
```
This example will not apply a filter to sensitive fields.
```hcl
audit_config {
audit_filter_overrides {
sensitive = ""
}
}
```
@@ -0,0 +1,18 @@
---
layout: docs
page_title: File sink - configuration reference
description: |-
The file sink configures Boundary to send events to a file.
---
# `file` sink
@include '/configuration-reference/events/file-sink-intro.mdx'
## Common parameters
These parameters are shared across all sink types: [common sink parameters](/boundary/docs/monitor/events/common)
## `file` parameters
@include '/configuration-reference/events/file-parameters.mdx'
@@ -1,47 +0,0 @@
---
layout: docs
page_title: Controller/worker - events - file sink - configuration
description: |-
The file sink configures Boundary to send events to a file.
---
# `file` sink
The file sink configures Boundary to send events to a file.
```hcl
sink {
name = "obs-sink"
description = "Observations sent to a file"
event_types = ["observation"]
format = "cloudevents-json"
file {
path = "/var/log/boundary"
file_name = "events.ndjson"
}
}
```
The `sink` stanza may be specified more than once to make Boundary send events
to multiple sinks; however, each file sink must have a unique `path` +
`file_name`.
## Common parameters
These parameters are shared across all sink types: [common sink parameters](/boundary/docs/configuration/events/common)
## `file` parameters
These parameters are only valid for a `file` sink.
- `file_name` - Specifies the file name for the sink.
- `path` - Optionally specifies the file path for the sink.
- `rotate_bytes` - Optionally specifies the number of bytes that should trigger rotation of
a file sink.
- `rotate_duration` - Optionally specifies how often a file sink should be rotated.
- `rotate_max_files` - Optionally specifies how many historical rotated files should be kept
for a file sink.
@@ -1,68 +1,14 @@
---
layout: docs
page_title: Controller/worker - events
page_title: Events configuration reference
description: |-
The events stanza configures events-specific parameters.
Reference document for configuring event parameters
---
# `events` stanza
The `events` stanza configures Boundary events-specific parameters.
Example:
```hcl
events {
observations_enabled = true
sysevents_enabled = true
telemetry_enabled = false
sink "stderr" {
name = "all-events"
description = "All events sent to stderr"
event_types = ["*"]
format = "hclog-text"
}
sink {
name = "obs-sink"
description = "Observations sent to a file"
event_types = ["observation"]
format = "cloudevents-json"
file {
path = "/var/log/boundary"
file_name = "events.ndjson"
}
}
}
```
- `audit_enabled` - Specifies if audit events should be emitted.
- `observations_enabled` - Specifies if observation events should be emitted.
- `sysevents_enabled` - Specifies if system events should be emitted.
- `telemetry_enabled` - Specifies if telemetry events should be emitted.
To receive telemetry events, you must also set `observations_enabled` to `true`.
- `sink` - Specifies the configuration of an event sink. Currently, two types of
sink are supported: [file](/boundary/docs/configuration/events/file) and [stderr](/boundary/docs/configuration/events/stderr). If no sinks are configured then all
events will be sent to a default [stderr](/boundary/docs/configuration/events/stderr) sink. Events may be sent to multiple
sinks.
@include '/configuration-reference/events/events-stanza-intro.mdx'
## Default events stanza
If no event stanza is specified then the following default is used:
```hcl
events {
audit_enabled = false
observations_enabled = true
sysevents_enabled = true
telemetry_enabled = false
sink "stderr" {
name = "default"
event_types = ["*"]
format = "cloudevents-json"
}
}
```
@include '/configuration-reference/events/default-events-stanza.mdx'
@@ -0,0 +1,18 @@
---
layout: docs
page_title: stderr sink - configuration reference
description: |-
The stderr sink configures Boundary to send events to a stderr.
---
# `stderr` sink
@include '/configuration-reference/events/stderr-intro.mdx'
## Common parameters
These parameters are shared across all sink types: [common sink parameters](/boundary/docs/monitor/events/common)
## `stderr` parameters
@include '/configuration-reference/events/stderr-parameters.mdx'
@@ -1,28 +0,0 @@
---
layout: docs
page_title: Controller - events - stderr sink - configuration
description: |-
The stderr sink configures Boundary to send events to a stderr.
---
# `stderr` sink
The stderr sink configures Boundary to send events to a stderr.
```hcl
sink "stderr" {
name = "all-events"
description = "All events sent to stderr"
event_types = ["*"]
format = "hclog-text"
}
```
## Common parameters
These parameters are shared across all sink types: [common sink parameters](/boundary/docs/configuration/events/common)
## `stderr` parameters
There are parameters are only valid for a `stderr` sink.
@@ -1,104 +0,0 @@
---
layout: docs
page_title: Assignable permissions
description: >-
Learn about using actions and output fields to grant users permissions to any resources that are identified by ID or Type.
---
# Assignable permissions
You can grant users permissions to any Boundary resources that are identified by ID or Type selectors.
There are two types of assigned permissions:
- An `actions` field indicating which actions to allow the client to perform on
the resources matched by `id` and `type`
- An `output_fields` field indicating which top-level fields to return in the
response.
## Actions
Actions convey the ability to perform some operation against a resource or
collection.
They include common CRUD operations (`create`, `read`, `update`,
`delete`), but some resources also have actions that are specific to their type.
For example, a `target` has an `authorize-session` action that allows you to request
making a connection to that target.
The `auth-method` resources have an `authenticate` action that allows you to authenticate to Boundary.
Most actions represent common operations, however there are some special cases to note.
### Subactions
Some subactions are also supported. Subactions have a format
`top_level_action:subaction`, such as `read:self`.
When you grant a top level action to a principal, they also inherit all subactions.
For example, if a grant conveys `read`, it also matches the API actions `read` and `read:self`.
However, if a grant conveys `read:self`, it does not grant the top-level action `read`.
### The `no-op` action and listing visibility
Boundary contains a `no-op` action that is not used for any real operations.
However, you can use the `no-op` action for listing visibility.
When a user runs a `list` operation, Boundary only shows the resources for which a user has been granted at least one action.
Without the `no-op` action, you would have to grant the user another action such as `read` to ensure they could view the resource.
Granting additional actions to users could result in exposing more information to the user than intended.
This is especially true for listing scopes and authentication methods, such as when users perform the initial authentication to Boundary.
Instead, you can grant the `no-op` action to users to ensure that they can view the output of a list command, without granting them other unnecessary actions.
### Anonymous user restrictions
There are limits to the actions that you can assign to the anonymous user `u_anon`.
The limitations are meant to prevent you from accidentally adding the anonymous user to a role that provides more privileges than you would intend to grant to an unauthenticated user.
For anonymous users, actions are restricted to listing scopes and auth methods,
and authentication to auth methods.
You can also grant the `no-op` action for listing visibility.
Boundary does not return a special error message when access is denied to an action because it is not allowed for an anonymous user.
You can still assign grants to a role on which the anonymous user is a principal, but they can never match the anonymous user.
## Output fields
Grant strings can contain an `output_fields` value. This setting gives you fine-grained
control over the visibility of data returned to users.
The `output_fields` reference the field names of the JSON object reponse.
They are composed just like other parts of the RBAC model, and are action-specific.
For example, the following grant:
`ids=*;type=auth-methods;actions=list,no-op;output_fields=scope_id,name,description`
results in the three identified output fields (scope ID, name, and description) applying to any `list` and `no-op` actions for all auth methods in the scope.
If a user performed a `list` operation under this example grant, each item returned would only have the three fields populated: `scope_id`, `name`, and `description`.
Any other actions, such as `read` or `update`, would be unaffected and would return the default information.
This grant:
`ids=*;type=auth-methods;output_fields=id`
means that only the `id` will be returned for any action performed against auth methods in this scope.
Grants are composable.
Therefore, if both of the example grants above are added, the final set of output fields would be `id`, `scope_id`, `name`, and `description` for the `list` and `no-op` actions.
For all other actions, the output field would be `id`.
### Default output fields
If none of the grants applicable to the resource or action for a given request contain `output_fields` definitions, Boundary uses the default settings.
The default settings vary based on whether the user is anonymous:
- If the user is anonymous, Boundary returns a restricted set of fields.
They include `id`, `scope_id`, `scope`, `name`, and `description`.
- If the user is authenticated, Boundary returns the full set of fields.
## More information
1. Refer to [Permission grant formats](/boundary/docs/configuration/identity-access-management/permission-grant-formats) for more information about grant strings and example formats.
1. Refer to the [Resource table](/boundary/docs/configuration/identity-access-management/resource-table) for a cheat sheet to help you manage your permissions.
## Next steps
Refer to [Manage roles and permissions](/boundary/docs/common-workflows/manage-roles) for instructions to configure roles and grant scopes for principals.
@@ -1,85 +0,0 @@
---
layout: docs
page_title: Permissions index
description: >-
Learn about Boundary's RBAC (Role-based access control), allow-only permissions model. Understand how permissions are configured using grant strings and roles.
---
# Permissions in Boundary
Boundary's permissions model is a composable, RBAC, allow-only model that
attempts to marry flexibility with usability.
The following pages discuss the permission model's fundamental concepts, provide examples of the specific forms of allowed grants, and contain a table that acts as a cheat sheet to help you craft roles.
Boundary's [domain model](/boundary/docs/concepts/domain-model) is based on resource
types. You can implement resource types directly, such as with targets, or they can be
abstract types that you implement using concrete types within the system. As an
example of the latter, a host catalog is an abstract type and a static host
catalog is a concrete type.
From a permissions standpoint, all actions take place against directly
implemented or abstract types. There may be actions that are only implemented by
some concrete types, for example, not all `auth-method` implementations support a
`change-password` action. But the permissions model still defines these
capabilities at the abstract type level.
At a very high level, permissions within Boundary are declared via grant strings
and mapped to users via roles.
## Grant strings
Each grant string is a mapping that describes a resource or set of resources and
the permissions that should be granted on them.
A grant string has a form similar to:
`ids=<id>;type=<type>;actions=<action list>;output_fields=<fields list>`
Selectors are used to indicate the resources on which the grant should apply,
using specific IDs or wildcard IDs and type selectors.
You can supply grant strings using a human-friendly string syntax or using JSON.
### Assigned permissions
You can grant users permissions to any Boundary resources that are identified by ID or Type selectors.
There are two types of assigned permissions:
- An `actions` field indicating which actions to allow the client to perform on
the resources matched by `id` and `type`
- An `output_fields` field indicating which top-level fields to return in the
response.
## Roles
Roles map grant strings to principals, which are users, groups, and managed groups.
Every role assigns grants within a scope, as determined by the role's grant scope IDs.
You can assign roles to multiple scopes to grant permissions to users who need access to resources across multiple scopes.
Child scopes can inherit roles from parents.
For example, the global scope could have multiple child scopes called "orgs".
When you create a role in the global scope, you can configure it to apply to those children org scopes.
When a user makes a request, the client may provide the scope or Boundary may look it up using the resource's ID.
This scope ID, along with the user's ID and the IDs of the groups the user belongs to, control which roles Boundary fetches to provide grants for the request.
A role provides grants for a request if the grant scope ID matches the request's
scope ID and one or more of the following are true:
- The user's ID is contained in the principal IDs set on the role
- A group the user belongs to is contained in the principal IDs set on the role
- The user is logged in and the `u_auth` user is contained in the principal IDs
set on the role
- The role contains the `u_anon` user in the in the principal IDs set on the
role
Roles are composable; a user's final set of grants will be composed of grants
that originate from all matching roles.
## Next steps
1. Refer to [Assignable permissions](/boundary/docs/configuration/identity-access-management/assignable-permissions) for more information about the permissions you can assign to Boundary principals.
1. Refer to [Permission grant formats](/boundary/docs/configuration/identity-access-management/permission-grant-formats) for more information about grant strings and example formats.
1. Refer to [Manage roles and permissions](/boundary/docs/common-workflows/manage-roles) for instructions to configure roles and grant scopes for principals.
1. Refer to the [Resource table](/boundary/docs/configuration/identity-access-management/resource-table) for a cheat sheet to help you manage your permissions.
@@ -1,158 +0,0 @@
---
layout: docs
page_title: Permission grant formats
description: >-
Learn how to construct grant strings that map resources and permissions. Understand ID, Type, Pinned, and Wildcard grant formats. View possible grant templates.
---
# Permission grant formats
Each grant string is a mapping that describes a resource or set of resources and
the permissions that should be granted on them.
Refer to [Assignable permissons](/boundary/docs/configuration/identity-access-management/assignable-permissions) for more information about the permissions you can include in grants.
A grant string has a form similar to:
`ids=<id>;type=<type>;actions=<action list>;output_fields=<fields list>`
There are two types of selectors:
- An `ids` field that indicates a specific resource or a wildcard to match all.
You can enter multiple comma-separated ID values in a grant string.
- A `type` field that indicates a specific resource type or a wildcard to match
all; this might also be used to grant permissions on collections of resources.
Selectors are used to indicate the resources on which the grant should apply,
using specific IDs or wildcard IDs and type selectors.
You can supply grant strings using a human-friendly string syntax or using JSON.
The following examples use the canonical string syntax.
The JSON equivalents are an object with a string `id` value, a string `type` value, a string array `actions` value, and a string array `output_fields` value.
In the following examples, `output_fields` is omitted for brevity, but they are valid for each example.
It is also valid to omit `actions` and specify only `output_fields`.
## ID only
The simplest form of grant allows the specified actions for a given resource.
Refer to the following example:
`ids=hsst_1234567890;actions=read,update`
This example grants `read` and `update` actions to the resource `hsst_1234567890`. It is invalid
to specify `create` or `list` as actions in this format, because this format
explicitly identifies a resource.
The `create` and `list` actions are only supported for collections.
You can enter multiple comma-separated ID values in a grant string:
`ids=hsst_1234567890,hsst_0987654321;actions=read,update`
This example grants the `read` and `update` actions to both resources `hsst_1234567890` and `hsst_0987654321`.
## Type only
You can configure a grant to allow the specified actions for a given type.
Refer to the following example:
`type=host-catalog;actions=create,list`
Because type specifies only a collection as opposed to specific resources within
that collection, only collection actions are allowed in this format. Currently,
this includes the `create` and `list` actions.
There is one additional restriction: this grant format is only valid against "top-level"
resource types, which include:
- Auth methods
- Auth tokens
- Groups
- Host catalogs
- Roles
- Scopes
- Sessions
- Targets
- Users
The reason for this is that other types of resources are contained within one of
these resource types.
For example, accounts are instantiated within an auth
method. To specify actions against an auth method, you must also specify the
specific containing resource you want to apply the grants to.
You can update those resources using the pinned format shown below.
## Pinned ID
This form "pins" actions to a non-top-level type within a specific ID.
Refer to the following example:
`ids=hcst_1234567890;type=host-set;actions=create,read,update`
In this example, the user is able to create, read, or update host sets within
the scope, but only the host sets belonging to host catalog `hcst_1234567890`.
Pinning is essentially a way to use top-level resources to create mini
permission boundaries for their subordinate resources.
## Wildcards
You can use wildcards in grants.
Refer to the following sections for the various wildcard possibilities that are supported.
### Wildcard ID
When just the ID is `*`, it matches all IDs of the given type. You can use this grant format
with both top-level resource types and non-top-level resource types.
Refer to the following example:
`ids=*;type=host-set;actions=create,read,update,set-hosts`
### Wildcard type
For non-top-level resources with pinned IDs, the `type` can be a wildcard.
Refer to the following example:
`ids=hcst_1234567890;type=*;actions=create,read,update`
This grant format would allow `create`, `read`, and `update` actions for all types of
subordinate resources underneath the host
catalog with ID `hcst_1234567890`.
In this example, that would include host sets and hosts.
### Wildcard ID and type
If the ID and type are both wildcards, the grant is essentially a catch-all that matches any resource of any type within the scope and allows the given actions.
Refer to the following example:
`ids=*;type=*;actions=read,list`
### Wildcard ID, type, and actions
ID, type, and actions can all be wildcards.
Refer to the following example:
`ids=*;type=*;actions=*`
Such a grant is essentially a full administrator grant for a scope.
## Templates
A few template possibilities exist for grants.
The following templates substitute a given value into the ID field of the grant string at evaluation time:
- `{{.Account.Id}}`: The substituted value is the account ID associated with the
token used to perform the action. As an example,
`ids={{.Account.Id}};actions=read,change-password"` is one of Boundary's
default grants to allow users that have authenticated with the Password auth
method to change their own password.
- `{{.User.Id}}`: The substituted value is the user ID associated with the token
used to perform the action.
## More information
1. Refer to [Assignable permissions](/boundary/docs/configuration/identity-access-management/assignable-permissions) for more information about the permissions you can assign to Boundary principals.
1. Refer to the [Resource table](/boundary/docs/configuration/identity-access-management/resource-table) for a cheat sheet to help you manage your permissions.
## Next steps
Refer to [Manage roles and permissions](/boundary/docs/common-workflows/manage-roles) for instructions to configure roles and grant scopes for principals.
@@ -1,238 +0,0 @@
---
layout: docs
page_title: Resource table
description: >-
View a list of resources and their available permissions parameters and actions to help you configure and manage permissions.
---
# Resource tables
The following tables work as a quick cheat sheet to help you manage your
permissions. Note that the tables are not exhaustive; for brevity they do _not_ show
wildcard or templated grant strings.
Additionally, these tables do not include available output fields; see the [service
documentation](/boundary/api-docs) for guidance.
Refer to the tables for more information about the following resource types:
<!-- BEGIN TABLE -->
- [Account](#account)
- [Alias](#alias)
- [Auth method](#auth-method)
- [Auth token](#auth-token)
- [Billing](#billing)
- [Credential](#credential)
- [Credential library](#credential-library)
- [Credential store](#credential-store)
- [Group](#group)
- [Host](#host)
- [Host catalog](#host-catalog)
- [Host set](#host-set)
- [Managed group](#managed-group)
- [Policy](#policy)
- [Role](#role)
- [Scope](#scope)
- [Session](#session)
- [Session recording](#session-recording)
- [Storage bucket](#storage-bucket)
- [Target](#target)
- [User](#user)
- [Worker](#worker)
## Account
The **Account** resource type supports the following scopes: **Global**, **Org**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/accounts</code> | <ul><li>Type</li><ul><li><code>account</code></li></ul></ul> | <ul><li><code>create</code>: Create an account</li><ul><li>`type=<type>;actions=create`</li></ul><li><code>list</code>: List accounts</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/accounts/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Pin</li><ul><li><code>&lt;auth-method-id&gt;</code></li></ul><li>Type</li><ul><li><code>account</code></li></ul></ul> | <ul><li><code>read</code>: Read an account</li><ul><li>`ids=<id>;actions=read`</li><li>`ids=<pin>;type=<type>;actions=read`</li></ul><li><code>update</code>: Update an account</li><ul><li>`ids=<id>;actions=update`</li><li>`ids=<pin>;type=<type>;actions=update`</li></ul><li><code>delete</code>: Delete an account</li><ul><li>`ids=<id>;actions=delete`</li><li>`ids=<pin>;type=<type>;actions=delete`</li></ul><li><code>change-password</code>: Change a password on an account given the current password</li><ul><li>`ids=<id>;actions=change-password`</li><li>`ids=<pin>;type=<type>;actions=change-password`</li></ul><li><code>set-password</code>: Set a password on an account, without requiring the current password</li><ul><li>`ids=<id>;actions=set-password`</li><li>`ids=<pin>;type=<type>;actions=set-password`</li></ul></ul> |
## Alias
The **Alias** resource type supports the following scopes: **Global**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/aliases</code> | <ul><li>Type</li><ul><li><code>alias</code></li></ul></ul> | <ul><li><code>create</code>: Create an alias</li><ul><li>`type=<type>;actions=create`</li></ul><li><code>list</code>: List aliass</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/aliases/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Type</li><ul><li><code>alias</code></li></ul></ul> | <ul><li><code>read</code>: Read an alias</li><ul><li>`ids=<id>;actions=read`</li></ul><li><code>update</code>: Update an alias</li><ul><li>`ids=<id>;actions=update`</li></ul><li><code>delete</code>: Delete an alias</li><ul><li>`ids=<id>;actions=delete`</li></ul></ul> |
## Auth method
The **Auth method** resource type supports the following scopes: **Global**, **Org**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/auth-methods</code> | <ul><li>Type</li><ul><li><code>auth-method</code></li></ul></ul> | <ul><li><code>create</code>: Create an auth method</li><ul><li>`type=<type>;actions=create`</li></ul><li><code>list</code>: List auth methods</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/auth-methods/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Type</li><ul><li><code>auth-method</code></li></ul></ul> | <ul><li><code>read</code>: Read an auth method</li><ul><li>`ids=<id>;actions=read`</li></ul><li><code>update</code>: Update an auth method</li><ul><li>`ids=<id>;actions=update`</li></ul><li><code>delete</code>: Delete an auth method</li><ul><li>`ids=<id>;actions=delete`</li></ul><li><code>authenticate</code>: Authenticate to an auth method</li><ul><li>`ids=<id>;actions=authenticate`</li></ul><li><code>change-state</code>: </li><ul><li>`ids=<id>;actions=change-state`</li></ul></ul> |
## Auth token
The **Auth token** resource type supports the following scopes: **Global**, **Org**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/auth-tokens</code> | <ul><li>Type</li><ul><li><code>auth-token</code></li></ul></ul> | <ul><li><code>list</code>: List auth tokens</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/auth-tokens/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Type</li><ul><li><code>auth-token</code></li></ul></ul> | <ul><li><code>read</code>: Read an auth token</li><ul><li>`ids=<id>;actions=read`</li></ul><li><code>delete</code>: Delete an auth token</li><ul><li>`ids=<id>;actions=delete`</li></ul><li><code>delete:self</code>: </li><ul><li>`ids=<id>;actions=delete:self`</li></ul><li><code>read:self</code>: </li><ul><li>`ids=<id>;actions=read:self`</li></ul></ul> |
## Billing
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/billing</code> | <ul><li>Type</li><ul><li><code>billing</code></li></ul></ul> | <ul><li><code>monthly-active-users</code>: </li><ul><li>`type=<type>;actions=monthly-active-users`</li></ul></ul> |
## Credential
The **Credential** resource type supports the following scopes: **Project**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/credentials</code> | <ul><li>Type</li><ul><li><code>credential</code></li></ul></ul> | <ul><li><code>create</code>: Create a credential</li><ul><li>`type=<type>;actions=create`</li></ul><li><code>list</code>: List credentials</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/credentials/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Pin</li><ul><li><code>&lt;credential-store-id&gt;</code></li></ul><li>Type</li><ul><li><code>credential</code></li></ul></ul> | <ul><li><code>read</code>: Read a credential</li><ul><li>`ids=<id>;actions=read`</li><li>`ids=<pin>;type=<type>;actions=read`</li></ul><li><code>update</code>: Update a credential</li><ul><li>`ids=<id>;actions=update`</li><li>`ids=<pin>;type=<type>;actions=update`</li></ul><li><code>delete</code>: Delete a credential</li><ul><li>`ids=<id>;actions=delete`</li><li>`ids=<pin>;type=<type>;actions=delete`</li></ul></ul> |
## Credential library
The **Credential library** resource type supports the following scopes: **Project**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/credential-libraries</code> | <ul><li>Type</li><ul><li><code>credential-library</code></li></ul></ul> | <ul><li><code>create</code>: Create a credential library</li><ul><li>`type=<type>;actions=create`</li></ul><li><code>list</code>: List credential librarys</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/credential-libraries/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Pin</li><ul><li><code>&lt;credential-store-id&gt;</code></li></ul><li>Type</li><ul><li><code>credential-library</code></li></ul></ul> | <ul><li><code>read</code>: Read a credential library</li><ul><li>`ids=<id>;actions=read`</li><li>`ids=<pin>;type=<type>;actions=read`</li></ul><li><code>update</code>: Update a credential library</li><ul><li>`ids=<id>;actions=update`</li><li>`ids=<pin>;type=<type>;actions=update`</li></ul><li><code>delete</code>: Delete a credential library</li><ul><li>`ids=<id>;actions=delete`</li><li>`ids=<pin>;type=<type>;actions=delete`</li></ul></ul> |
## Credential store
The **Credential store** resource type supports the following scopes: **Project**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/credential-stores</code> | <ul><li>Type</li><ul><li><code>credential-store</code></li></ul></ul> | <ul><li><code>create</code>: Create a credential store</li><ul><li>`type=<type>;actions=create`</li></ul><li><code>list</code>: List credential stores</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/credential-stores/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Type</li><ul><li><code>credential-store</code></li></ul></ul> | <ul><li><code>read</code>: Read a credential store</li><ul><li>`ids=<id>;actions=read`</li></ul><li><code>update</code>: Update a credential store</li><ul><li>`ids=<id>;actions=update`</li></ul><li><code>delete</code>: Delete a credential store</li><ul><li>`ids=<id>;actions=delete`</li></ul></ul> |
## Group
The **Group** resource type supports the following scopes: **Global**, **Org**, **Project**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/groups</code> | <ul><li>Type</li><ul><li><code>group</code></li></ul></ul> | <ul><li><code>create</code>: Create a group</li><ul><li>`type=<type>;actions=create`</li></ul><li><code>list</code>: List groups</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/groups/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Type</li><ul><li><code>group</code></li></ul></ul> | <ul><li><code>read</code>: Read a group</li><ul><li>`ids=<id>;actions=read`</li></ul><li><code>update</code>: Update a group</li><ul><li>`ids=<id>;actions=update`</li></ul><li><code>delete</code>: Delete a group</li><ul><li>`ids=<id>;actions=delete`</li></ul><li><code>add-members</code>: Add members to a group</li><ul><li>`ids=<id>;actions=add-members`</li></ul><li><code>remove-members</code>: Remove members from a group</li><ul><li>`ids=<id>;actions=remove-members`</li></ul><li><code>set-members</code>: Set the full set of members on a group</li><ul><li>`ids=<id>;actions=set-members`</li></ul></ul> |
## Host
The **Host** resource type supports the following scopes: **Project**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/hosts</code> | <ul><li>Type</li><ul><li><code>host</code></li></ul></ul> | <ul><li><code>create</code>: Create a host</li><ul><li>`type=<type>;actions=create`</li></ul><li><code>list</code>: List hosts</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/hosts/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Pin</li><ul><li><code>&lt;host-catalog-id&gt;</code></li></ul><li>Type</li><ul><li><code>host</code></li></ul></ul> | <ul><li><code>read</code>: Read a host</li><ul><li>`ids=<id>;actions=read`</li><li>`ids=<pin>;type=<type>;actions=read`</li></ul><li><code>update</code>: Update a host</li><ul><li>`ids=<id>;actions=update`</li><li>`ids=<pin>;type=<type>;actions=update`</li></ul><li><code>delete</code>: Delete a host</li><ul><li>`ids=<id>;actions=delete`</li><li>`ids=<pin>;type=<type>;actions=delete`</li></ul></ul> |
## Host catalog
The **Host catalog** resource type supports the following scopes: **Project**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/host-catalogs</code> | <ul><li>Type</li><ul><li><code>host-catalog</code></li></ul></ul> | <ul><li><code>create</code>: Create a host catalog</li><ul><li>`type=<type>;actions=create`</li></ul><li><code>list</code>: List host catalogs</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/host-catalogs/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Type</li><ul><li><code>host-catalog</code></li></ul></ul> | <ul><li><code>read</code>: Read a host catalog</li><ul><li>`ids=<id>;actions=read`</li></ul><li><code>update</code>: Update a host catalog</li><ul><li>`ids=<id>;actions=update`</li></ul><li><code>delete</code>: Delete a host catalog</li><ul><li>`ids=<id>;actions=delete`</li></ul></ul> |
## Host set
The **Host set** resource type supports the following scopes: **Project**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/host-sets</code> | <ul><li>Type</li><ul><li><code>host-set</code></li></ul></ul> | <ul><li><code>create</code>: Create a host set</li><ul><li>`type=<type>;actions=create`</li></ul><li><code>list</code>: List host sets</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/host-sets/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Pin</li><ul><li><code>&lt;host-catalog-id&gt;</code></li></ul><li>Type</li><ul><li><code>host-set</code></li></ul></ul> | <ul><li><code>read</code>: Read a host set</li><ul><li>`ids=<id>;actions=read`</li><li>`ids=<pin>;type=<type>;actions=read`</li></ul><li><code>update</code>: Update a host set</li><ul><li>`ids=<id>;actions=update`</li><li>`ids=<pin>;type=<type>;actions=update`</li></ul><li><code>delete</code>: Delete a host set</li><ul><li>`ids=<id>;actions=delete`</li><li>`ids=<pin>;type=<type>;actions=delete`</li></ul><li><code>add-hosts</code>: Add hosts to a host set</li><ul><li>`ids=<id>;actions=add-hosts`</li><li>`ids=<pin>;type=<type>;actions=add-hosts`</li></ul><li><code>remove-hosts</code>: Remove hosts from a host set</li><ul><li>`ids=<id>;actions=remove-hosts`</li><li>`ids=<pin>;type=<type>;actions=remove-hosts`</li></ul><li><code>set-hosts</code>: Set the full set of hosts on a host set</li><ul><li>`ids=<id>;actions=set-hosts`</li><li>`ids=<pin>;type=<type>;actions=set-hosts`</li></ul></ul> |
## Managed group
The **Managed group** resource type supports the following scopes: **Global**, **Org**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/managed-groups</code> | <ul><li>Type</li><ul><li><code>managed-group</code></li></ul></ul> | <ul><li><code>create</code>: Create a managed group</li><ul><li>`type=<type>;actions=create`</li></ul><li><code>list</code>: List managed groups</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/managed-groups/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Pin</li><ul><li><code>&lt;auth-method-id&gt;</code></li></ul><li>Type</li><ul><li><code>managed-group</code></li></ul></ul> | <ul><li><code>read</code>: Read a managed group</li><ul><li>`ids=<id>;actions=read`</li><li>`ids=<pin>;type=<type>;actions=read`</li></ul><li><code>update</code>: Update a managed group</li><ul><li>`ids=<id>;actions=update`</li><li>`ids=<pin>;type=<type>;actions=update`</li></ul><li><code>delete</code>: Delete a managed group</li><ul><li>`ids=<id>;actions=delete`</li><li>`ids=<pin>;type=<type>;actions=delete`</li></ul></ul> |
## Policy
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/policies</code> | <ul><li>Type</li><ul><li><code>policy</code></li></ul></ul> | <ul><li><code>create</code>: Create a policy</li><ul><li>`type=<type>;actions=create`</li></ul><li><code>list</code>: List policys</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/policies/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Type</li><ul><li><code>policy</code></li></ul></ul> | <ul><li><code>read</code>: Read a policy</li><ul><li>`ids=<id>;actions=read`</li></ul><li><code>update</code>: Update a policy</li><ul><li>`ids=<id>;actions=update`</li></ul><li><code>delete</code>: Delete a policy</li><ul><li>`ids=<id>;actions=delete`</li></ul></ul> |
## Role
The **Role** resource type supports the following scopes: **Global**, **Org**, **Project**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/roles</code> | <ul><li>Type</li><ul><li><code>role</code></li></ul></ul> | <ul><li><code>create</code>: Create a role</li><ul><li>`type=<type>;actions=create`</li></ul><li><code>list</code>: List roles</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/roles/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Type</li><ul><li><code>role</code></li></ul></ul> | <ul><li><code>read</code>: Read a role</li><ul><li>`ids=<id>;actions=read`</li></ul><li><code>update</code>: Update a role</li><ul><li>`ids=<id>;actions=update`</li></ul><li><code>delete</code>: Delete a role</li><ul><li>`ids=<id>;actions=delete`</li></ul><li><code>add-grant-scopes</code>: Add grant scopes to a role</li><ul><li>`ids=<id>;actions=add-grant-scopes`</li></ul><li><code>add-grants</code>: Add grants to a role</li><ul><li>`ids=<id>;actions=add-grants`</li></ul><li><code>add-principals</code>: Add principals to a role</li><ul><li>`ids=<id>;actions=add-principals`</li></ul><li><code>remove-grant-scopes</code>: Remove grant scopes from a role</li><ul><li>`ids=<id>;actions=remove-grant-scopes`</li></ul><li><code>remove-grants</code>: Remove grants from a role</li><ul><li>`ids=<id>;actions=remove-grants`</li></ul><li><code>remove-principals</code>: Remove principals from a role</li><ul><li>`ids=<id>;actions=remove-principals`</li></ul><li><code>set-grant-scopes</code>: Set the full set of grant scopes on a role</li><ul><li>`ids=<id>;actions=set-grant-scopes`</li></ul><li><code>set-grants</code>: Set the full set of grants on a role</li><ul><li>`ids=<id>;actions=set-grants`</li></ul><li><code>set-principals</code>: Set the full set of principals on a role</li><ul><li>`ids=<id>;actions=set-principals`</li></ul></ul> |
## Scope
The **Scope** resource type supports the following scopes: **Global**, **Org**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/scopes</code> | <ul><li>Type</li><ul><li><code>scope</code></li></ul></ul> | <ul><li><code>create</code>: Create a scope</li><ul><li>`type=<type>;actions=create`</li></ul><li><code>destroy-key-version</code>: </li><ul><li>`type=<type>;actions=destroy-key-version`</li></ul><li><code>list</code>: List scopes</li><ul><li>`type=<type>;actions=list`</li></ul><li><code>list-key-version-destruction-jobs</code>: </li><ul><li>`type=<type>;actions=list-key-version-destruction-jobs`</li></ul><li><code>list-keys</code>: </li><ul><li>`type=<type>;actions=list-keys`</li></ul><li><code>rotate-keys</code>: </li><ul><li>`type=<type>;actions=rotate-keys`</li></ul></ul> |
| <code>/scopes/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Type</li><ul><li><code>scope</code></li></ul></ul> | <ul><li><code>read</code>: Read a scope</li><ul><li>`ids=<id>;actions=read`</li></ul><li><code>update</code>: Update a scope</li><ul><li>`ids=<id>;actions=update`</li></ul><li><code>delete</code>: Delete a scope</li><ul><li>`ids=<id>;actions=delete`</li></ul><li><code>attach-storage-policy</code>: </li><ul><li>`ids=<id>;actions=attach-storage-policy`</li></ul><li><code>detach-storage-policy</code>: </li><ul><li>`ids=<id>;actions=detach-storage-policy`</li></ul></ul> |
## Session
The **Session** resource type supports the following scopes: **Project**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/sessions</code> | <ul><li>Type</li><ul><li><code>session</code></li></ul></ul> | <ul><li><code>list</code>: List sessions</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/sessions/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Type</li><ul><li><code>session</code></li></ul></ul> | <ul><li><code>read</code>: Read a session</li><ul><li>`ids=<id>;actions=read`</li></ul><li><code>cancel</code>: Cancel a session</li><ul><li>`ids=<id>;actions=cancel`</li></ul><li><code>cancel:self</code>: Cancel a session, which must be associated with the calling user</li><ul><li>`ids=<id>;actions=cancel:self`</li></ul><li><code>read:self</code>: Read a session, which must be associated with the calling user</li><ul><li>`ids=<id>;actions=read:self`</li></ul></ul> |
## Session recording
The **Session recording** resource type supports the following scopes: **Global**, **Org**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/session-recordings</code> | <ul><li>Type</li><ul><li><code>session-recording</code></li></ul></ul> | <ul><li><code>list</code>: List session recordings</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/session-recordings/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Type</li><ul><li><code>session-recording</code></li></ul></ul> | <ul><li><code>read</code>: Read a session recording</li><ul><li>`ids=<id>;actions=read`</li></ul><li><code>delete</code>: Delete a session recording</li><ul><li>`ids=<id>;actions=delete`</li></ul><li><code>download</code>: Download a session recording</li><ul><li>`ids=<id>;actions=download`</li></ul><li><code>reapply-storage-policy</code>: Reapply the storage policy to a session recording</li><ul><li>`ids=<id>;actions=reapply-storage-policy`</li></ul></ul> |
## Storage bucket
The **Storage bucket** resource type supports the following scopes: **Global**, **Org**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/storage-buckets</code> | <ul><li>Type</li><ul><li><code>storage-bucket</code></li></ul></ul> | <ul><li><code>create</code>: Create a storage bucket</li><ul><li>`type=<type>;actions=create`</li></ul><li><code>list</code>: List storage buckets</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/storage-buckets/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Type</li><ul><li><code>storage-bucket</code></li></ul></ul> | <ul><li><code>read</code>: Read a storage bucket</li><ul><li>`ids=<id>;actions=read`</li></ul><li><code>update</code>: Update a storage bucket</li><ul><li>`ids=<id>;actions=update`</li></ul><li><code>delete</code>: Delete a storage bucket</li><ul><li>`ids=<id>;actions=delete`</li></ul></ul> |
## Target
The **Target** resource type supports the following scopes: **Project**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/targets</code> | <ul><li>Type</li><ul><li><code>target</code></li></ul></ul> | <ul><li><code>create</code>: Create a target</li><ul><li>`type=<type>;actions=create`</li></ul><li><code>list</code>: List targets</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/targets/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Type</li><ul><li><code>target</code></li></ul></ul> | <ul><li><code>read</code>: Read a target</li><ul><li>`ids=<id>;actions=read`</li></ul><li><code>update</code>: Update a target</li><ul><li>`ids=<id>;actions=update`</li></ul><li><code>delete</code>: Delete a target</li><ul><li>`ids=<id>;actions=delete`</li></ul><li><code>add-credential-sources</code>: Add credential sources to a target</li><ul><li>`ids=<id>;actions=add-credential-sources`</li></ul><li><code>add-host-sources</code>: Add host sources to a target</li><ul><li>`ids=<id>;actions=add-host-sources`</li></ul><li><code>authorize-session</code>: Authorize a session via the target</li><ul><li>`ids=<id>;actions=authorize-session`</li></ul><li><code>remove-credential-sources</code>: Remove credential sources from a target</li><ul><li>`ids=<id>;actions=remove-credential-sources`</li></ul><li><code>remove-host-sources</code>: Remove host sources from a target</li><ul><li>`ids=<id>;actions=remove-host-sources`</li></ul><li><code>set-credential-sources</code>: Set the full set of credential sources on a target</li><ul><li>`ids=<id>;actions=set-credential-sources`</li></ul><li><code>set-host-sources</code>: Set the full set of host sources on a target</li><ul><li>`ids=<id>;actions=set-host-sources`</li></ul></ul> |
## User
The **User** resource type supports the following scopes: **Global**, **Org**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/users</code> | <ul><li>Type</li><ul><li><code>user</code></li></ul></ul> | <ul><li><code>create</code>: Create a user</li><ul><li>`type=<type>;actions=create`</li></ul><li><code>list</code>: List users</li><ul><li>`type=<type>;actions=list`</li></ul></ul> |
| <code>/users/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Type</li><ul><li><code>user</code></li></ul></ul> | <ul><li><code>read</code>: Read a user</li><ul><li>`ids=<id>;actions=read`</li></ul><li><code>update</code>: Update a user</li><ul><li>`ids=<id>;actions=update`</li></ul><li><code>delete</code>: Delete a user</li><ul><li>`ids=<id>;actions=delete`</li></ul><li><code>add-accounts</code>: Add accounts to a user</li><ul><li>`ids=<id>;actions=add-accounts`</li></ul><li><code>list-resolvable-aliases</code>: </li><ul><li>`ids=<id>;actions=list-resolvable-aliases`</li></ul><li><code>remove-accounts</code>: Remove accounts from a user</li><ul><li>`ids=<id>;actions=remove-accounts`</li></ul><li><code>set-accounts</code>: Set the full set of accounts on a user</li><ul><li>`ids=<id>;actions=set-accounts`</li></ul></ul> |
## Worker
The **Worker** resource type supports the following scopes: **Global**
| API endpoint | Parameters into permissions engine | Available actions / examples |
| ------------ | ---------------------------------- | ---------------------------- |
| <code>/workers</code> | <ul><li>Type</li><ul><li><code>worker</code></li></ul></ul> | <ul><li><code>create:controller-led</code>: Create a worker using the controller-led workflow</li><ul><li>`type=<type>;actions=create:controller-led`</li><li>`type=<type>;actions=create:controller-led`</li></ul><li><code>create:worker-led</code>: Create a worker using the worker-led workflow</li><ul><li>`type=<type>;actions=create:worker-led`</li><li>`type=<type>;actions=create:worker-led`</li></ul><li><code>list</code>: List workers</li><ul><li>`type=<type>;actions=list`</li></ul><li><code>read-certificate-authority</code>: </li><ul><li>`type=<type>;actions=read-certificate-authority`</li></ul><li><code>reinitialize-certificate-authority</code>: </li><ul><li>`type=<type>;actions=reinitialize-certificate-authority`</li></ul></ul> |
| <code>/workers/&lt;id&gt;</code> | <ul><li>ID</li><ul><li><code>&lt;id&gt;</code></li></ul><li>Type</li><ul><li><code>worker</code></li></ul></ul> | <ul><li><code>read</code>: Read a worker</li><ul><li>`ids=<id>;actions=read`</li></ul><li><code>update</code>: Update a worker</li><ul><li>`ids=<id>;actions=update`</li></ul><li><code>delete</code>: Delete a worker</li><ul><li>`ids=<id>;actions=delete`</li></ul><li><code>add-worker-tags</code>: Add worker tags to a worker</li><ul><li>`ids=<id>;actions=add-worker-tags`</li></ul><li><code>remove-worker-tags</code>: Remove worker tags from a worker</li><ul><li>`ids=<id>;actions=remove-worker-tags`</li></ul><li><code>set-worker-tags</code>: Set the full set of worker tags on a worker</li><ul><li>`ids=<id>;actions=set-worker-tags`</li></ul></ul> |
<!-- END TABLE -->
+6 -6
View File
@@ -5,11 +5,11 @@ description: >-
Learn about the parameters that make up the Boundary HCL configuration file. View parameters for HCP and self-managed installations.
---
# Configuration
# Top-level configuration parameters
[listener]: /boundary/docs/configuration/listener
[controller]: /boundary/docs/configuration/controller
[worker]: /boundary/docs/configuration/worker
[worker]: /boundary/docs/configuration/workers
[kms]: /boundary/docs/configuration/kms
[plugins]: /boundary/docs/configuration/plugins
[events]: /boundary/docs/configuration/events
@@ -30,7 +30,7 @@ path to the file.
## Shared self-managed and HCP Boundary parameters
- [`worker`](/boundary/docs/configuration/worker): Worker specific configuration. If
- [`worker`](/boundary/docs/configuration/workers): Worker specific configuration. If
present, `boundary server` will start a Worker subprocess.
- [`listener`](/boundary/docs/configuration/listener): Configures the listeners on which
@@ -45,7 +45,7 @@ path to the file.
where Boundary's operational endpoints live (eg: /health).
- [`kms`](/boundary/docs/configuration/kms): Configures KMS blocks [for various
purposes](/boundary/docs/concepts/security/data-encryption).
purposes](/boundary/docs/secure/encryption/data-encryption).
- [`events`](/boundary/docs/configuration/events): Configures event (observability,
audit, error) handling.
@@ -93,7 +93,7 @@ path to the file.
The `SIGHUP` signal causes worker and controller processes to reload their configuration files to pick up updated values.
~> **Note:** You cannot reload all configuration values using the `SIGHUP` signal. Refer to the configuration pages for
[workers](/boundary/docs/configuration/worker/) and [controllers](/boundary/docs/configuration/controller) for details
[workers](/boundary/docs/configuration/workers) and [controllers](/boundary/docs/configuration/controller) for details
on which values can be reloaded on `SIGHUP`.
The `SIGTERM` and `SIGINT` signals cause worker and controller processes to enter graceful shutdown. A graceful shutdown for a controller closes listeners and servers before shutting down the controller. A graceful shutdown for a worker waits for any sessions to drain
@@ -103,4 +103,4 @@ before shutting down the worker. Workers in a graceful shutdown state do not rec
For complete example configurations see the sections for
[controller](/boundary/docs/configuration/controller) and
[worker](/boundary/docs/configuration/worker).
[worker](/boundary/docs/configuration/workers).
@@ -32,7 +32,7 @@ These parameters apply to the `kms` stanza in the Boundary configuration file:
- `purpose` - Purpose of this KMS, acceptable values are: `worker-auth`, `worker-auth-storage`,
`root`, `previous-root`, `recovery`, `bsr`, or `config`.
To [enable session recording](/boundary/docs/configuration/session-recording/enable-session-recording), you must configure the `bsr` value for the `purpose`.
To [enable session recording](/boundary/docs/session-recording/configuration/enable-session-recording), you must configure the `bsr` value for the `purpose`.
- `region` `(string: "us-east-1")`: The AWS region where the encryption key
lives. If not provided, may be populated from the `AWS_REGION` or
@@ -54,22 +54,22 @@ These parameters apply to the `kms` stanza in the Boundary configuration file:
also be specified by the `AWS_SECRET_ACCESS_KEY` environment variable or as
part of the AWS profile from the AWS CLI or instance profile.
- `shared_creds_filename` `(string: "")`: (Boundary 0.5.1+) If set, the file
- `shared_creds_filename` `(string: "")`: If set, the file
name to read as a shared credentials file.
- `shared_creds_profile` `(string: "")`: (Boundary 0.5.1+) If set, the
- `shared_creds_profile` `(string: "")`: If set, the
profile to use from the shared credentials file. If not set, will use the
`AWS_PROFILE` env var, or if that is not set, `"default"`.
- `role_arn` `(string: "")`: (Boundary 0.5.1+) If this and
- `role_arn` `(string: "")`: If this and
`web_identity_token_file` are set, the role ARN to use when using a web
identity role provider with STS.
- `web_identity_token_file` `(string: "")`: (Boundary 0.5.1+) If this and
- `web_identity_token_file` `(string: "")`: If this and
`role_arn` are set, the token file to use when using a web identity role
provider with STS.
- `role_session_name` `(string: "")`: (Boundary 0.5.1+) If using the web
- `role_session_name` `(string: "")`: If using the web
identity role provider, the role session to use.
- `endpoint` `(string: "")`: The KMS API endpoint to be used to make AWS KMS
@@ -9,8 +9,6 @@ description: >-
The `kms` stanza configures Boundary kms-specific parameters.
For more examples, please choose a specific KMS technology from the sidebar.
## Configuration
KMS configuration can be done through the Boundary configuration file using the
@@ -29,3 +27,15 @@ kms "transit" {
# ...
}
```
## More information
For specific KMS examples, refer to the following topics:
- [aead KMS](/boundary/docs/configuration/kms/aead)
- [AliCloud KMS](/boundary/docs/configuration/kms/alicloudkms)
- [AWS KMS](/boundary/docs/configuration/kms/awskms)
- [Azure Key Vault KMS](/boundary/docs/configuration/kms/azurekeyvault)
- [GCP Cloud KMS](/boundary/docs/configuration/kms/gcpckms)
- [OCI KMS](/boundary/docs/configuration/kms/ocikms)
- [Vault Transit KMS](/boundary/docs/configuration/kms/transit)
@@ -1,40 +0,0 @@
---
layout: docs
page_title: Listener configuration
description: >-
Learn about TCP and Unix listener configuration settings. Understand where to change the default addresses and ports on which Boundary responds to requests.
---
# `listener` stanza
The `listener` stanza configures the addresses and ports on which Boundary will
respond to requests. At this time, there are two listener types:
[TCP](/boundary/docs/configuration/listener/tcp) and [Unix](/boundary/docs/configuration/listener/unix).
## `listener` purpose
The `purpose` field is used to determine what part of Boundary's functionality is
started and exposed for a given listener block. Each listener must have a `purpose` set.
Currently, Boundary recognizes the following listener purposes:
- `api`: Starts up and exposes Boundary's controller API.
At least one `api` listener must be present if a Boundary
instance is set-up as a controller.
By default, it runs on `:9200`.
- `cluster`: Starts up and exposes Boundary's worker and
controller communication layer. Only one `cluster` listener
is allowed per Boundary instance. Must be present if a Boundary
instance is set-up as a controller.
By default, it runs on `:9201`.
- `proxy`: Starts up a Boundary Worker. By default, it runs
on `:9202`.
- `ops`: Starts up and exposes Boundary's operational
endpoints (eg: /health). By default, it runs on `:9203`.
This listener's exposed functionality depends on what Boundary
components you're running on any given Boundary instance (eg: Health does not
run unless your Boundary instance has a controller running)
@@ -1,345 +0,0 @@
---
layout: docs
page_title: TCP listener configuration
description: >-
Learn about using the TCP listener on a TCP address and port, and view configurable parameters. Understand custom response headers. View example configurations.
---
# `tcp` listener
The TCP listener configures Boundary to listen on a TCP address/port.
```hcl
listener "tcp" {
purpose = "api"
address = "127.0.0.1:9200"
}
```
The `listener` stanza may be specified more than once to make Boundary listen on
multiple interfaces; however, only one listener marked for `cluster` purpose is
allowed.
## Listener's custom response headers
Boundary supports defining custom HTTP response headers for all requests on any Boundary controller.
Headers are defined based on the returned status code. For example, you can define a list of
custom response headers for the `200` status code, and another list of custom response headers for
the `307` status code, and so on. You can also define headers based on the hundred-level status
code. For example, a list of headers applied to the `4xx` code will be applied to 400, 401, 404, and
all other 400-level status codes. The more specific the status, the higher priority it has.
Default headers are overwritten by hundred-level headers, which are overwritten by status-specific
headers.
There are two different config parameters that define headers: `custom_api_response_headers` and
`custom_ui_response_headers`. API headers apply to API endpoints, currently all paths starting
with `/v1/`. UI headers apply to all other paths. This allows for configuring headers specifically
for serving content to a web browser, such as CSP headers.
## `tcp` listener parameters
Refer to the following sections for `tcp` listener parameters.
### General
- `purpose` `(string: "")` - Specifies the purpose. Can be `api`, `cluster`,
`proxy`, or `ops`.
- `address` `(string: "127.0.0.1:9200")` – Specifies the address to bind to for
listening.
- `http_idle_timeout` `(string: "5m")` - Specifies the maximum amount of time to
wait for the next request when keep-alives are enabled. If `http_idle_timeout`
is zero, the value of `http_read_timeout` is used. If both are zero, the value
of `http_read_header_timeout` is used. This is specified using a label suffix
like `"30s"` or `"1h"`.
- `http_read_header_timeout` `(string: "10s")` - Specifies the amount of time
allowed to read request headers. This is specified using a label suffix like
`"30s"` or `"1h"`.
- `http_read_timeout` `(string: "30s")` - Specifies the maximum duration for
reading the entire request, including the body. This is specified using a
label suffix like `"30s"` or `"1h"`.
- `http_write_timeout` `(string: "0")` - Specifies the maximum duration before
timing out writes of the response and is reset whenever a new request's header
is read. The default value of `"0"` means infinity. This is specified using a
label suffix like `"30s"` or `"1h"`.
<!-- We don't have this implemented yet
- `max_request_size` `(int: 33554432)` – Specifies a hard maximum allowed
request size, in bytes. Defaults to 32 MB. Specifying a number less than or
equal to `0` turns off limiting altogether.
!-->
- `max_request_duration` `(string: "90s")` – Specifies the maximum
request duration allowed before Boundary cancels the request. This overrides
`default_max_request_duration` for this listener.
- `cors_enabled` `(boolean: true)` - Specifies if CORS should be enabled, which
allows Boundary to support external browser-based clients (not including admin
UI), such as Boundary Desktop. If not specified, CORS will be enabled with an
allowed origin that grants access to Boundary Desktop, unless overridden with
`cors_disable_default_allowed_origin_values`.
- `cors_disable_default_allowed_origin_values` `(boolean: false)` - Specifies
that Boundary should not append default allowed origin values to any specified
in `cors_allowed_origins`, such as Boundary Desktop's origin. This also
disables the behavior of enabling CORS if `cors_enabled` is not specified.
- `cors_allowed_origins` `(array(string): ["serve://boundary"])` - An array of
allowed CORS origins. Origins must include protocol, host, and port (if port
is different than the default for the specified protocol). To allow all
origins, set to `['*']`. By default, Boundary Desktop's origin
`serve://boundary` is appended to any values included here, unless
`cors_disable_default_allowed_origin_values` is specified.
- `cors_allowed_headers` `(array(string): [])` – An array specifying headers
that are permitted to be on cross-origin requests. Headers set via this
parameter will be appended to the list of headers that Boundary allows by
default, such as `"Content-Type"`, `"X-Requested-With"`, and
`"Authorization"`.
### `custom_api_response_headers` parameters
- `default` `(key-value-map: {})` - A map of string header names to an array of
string values. The default headers are set on all endpoints regardless of
the status code value. For an example, refer to the
[Configuring custom http response headers](#configuring-custom-http-response-headers)
section.
- `<collective status code>` `(key-value-map: {})` - A map of string header names
to an array of string values. These headers are set only when the response status
code falls under the collective status code.
For example, `"2xx" = {"Header-A": ["Value1", "Value2"]}`, `"Header-A"`
is set when the http response status code is `"200"`, `"204"`, etc. This overrides
headers defined at the `default` level.
- `<specific status code>` `(key-value-map: {})` - A map of string header names
to an array of string values. These headers are set only when the specific status
code is returned. For example, `"200" = {"Header-A": ["Value1", "Value2"]}`, `"Header-A"`
is set when the http response status code is `"200"`. This overrides headers defined at
the `default` and `collective status code` level.
### `custom_ui_response_headers` parameters
- `default` `(key-value-map: {})` - A map of string header names to an array of
string values. The default headers are set on all endpoints regardless of
the status code value. For an example, refer to the
[Configuring custom http response headers](#configuring-custom-http-response-headers)
section.
- `<collective status code>` `(key-value-map: {})` - A map of string header names
to an array of string values. These headers are set only when the response status
code falls under the collective status code.
For example, `"2xx" = {"Header-A": ["Value1", "Value2"]}`, `"Header-A"`
is set when the http response status code is `"200"`, `"204"`, etc. This overrides
headers defined at the `default` level.
- `<specific status code>` `(key-value-map: {})` - A map of string header names
to an array of string values. These headers are set only when the specific status
code is returned. For example, `"200" = {"Header-A": ["Value1", "Value2"]}`, `"Header-A"`
is set when the http response status code is `"200"`. This overrides headers defined at
the `default` and `collective status code` level.
### TLS
~> `tls` parameters are valid for `api` and `ops` listeners. `cluster`
and `proxy` connections use their own ephemeral TLS stacks. For more
information, see [the connections security concepts
page](/boundary/docs/concepts/security/connections-tls).
- `tls_disable` `(string: "false")` – Specifies if TLS will be disabled. Boundary
assumes TLS by default, so you must explicitly disable TLS to opt-in to
insecure communication.
- `tls_cert_file` `(string: <required-if-enabled, reloads-on-SIGHUP>)` –
Specifies the path to the certificate for TLS. To configure the listener to
use a CA certificate, concatenate the primary certificate and the CA
certificate together. The primary certificate should appear first in the
combined file. On `SIGHUP`, the path set here _at Boundary startup_ will be
used for reloading the certificate; modifying this value while Boundary is
running will have no effect for `SIGHUP`s.
- `tls_key_file` `(string: <required-if-enabled, reloads-on-SIGHUP>)` –
Specifies the path to the private key for the certificate. If the key file is
encrypted, you will be prompted to enter the passphrase on server startup. The
passphrase must stay the same between key files when reloading your
configuration using `SIGHUP`. On `SIGHUP`, the path set here _at Boundary
startup_ will be used for reloading the certificate; modifying this value
while Boundary is running will have no effect for `SIGHUP`s.
- `tls_min_version` `(string: "tls12")` – Specifies the minimum supported
version of TLS. Accepted values are "tls10", "tls11", "tls12" or "tls13".
!> TLS 1.1 and lower are generally considered insecure.
- `tls_max_version` `(string: "tls13")` – Specifies the maximum supported
version of TLS, useful if appliances (e.g. load balancers) are not yet capable
of higher levels. Accepted values are "tls10", "tls11", "tls12" or "tls13".
!> TLS 1.1 and lower are generally considered insecure.
- `tls_cipher_suites` `(string: "")` – Override the default list of supported
ciphersuites (which varies by TLS version) with the the specified
comma-delimited list. The list of all available ciphersuites is available in
the [Golang TLS documentation][golang-tls].
- `tls_prefer_server_cipher_suites` `(string: "false")` – Specifies to prefer the
server's ciphersuite over the client ciphersuites.
- `tls_require_and_verify_client_cert` `(string: "false")` – Turns on client
authentication for this listener; the listener will require a presented
client cert that successfully validates against system CAs.
- `tls_client_ca_file` `(string: "")` – PEM-encoded Certificate Authority file
used for checking the authenticity of client.
<!-- Not enabled yet
- `x_forwarded_for_authorized_addrs` `(string: <required-to-enable>)` –
Specifies the list of source IP CIDRs for which an X-Forwarded-For header
will be trusted. Comma-separated list or JSON array. This turns on
X-Forwarded-For support.
- `x_forwarded_for_hop_skips` `(string: "0")` – The number of addresses that will be
skipped from the _rear_ of the set of hops. For instance, for a header value
of `1.2.3.4, 2.3.4.5, 3.4.5.6`, if this value is set to `"1"`, the address that
will be used as the originating client IP is `2.3.4.5`.
- `x_forwarded_for_reject_not_authorized` `(string: "true")` – If set false,
if there is an X-Forwarded-For header in a connection from an unauthorized
address, the header will be ignored and the client connection used as-is,
rather than the client connection rejected.
- `x_forwarded_for_reject_not_present` `(string: "true")` – If set false, if
there is no X-Forwarded-For header or it is empty, the client address will be
used as-is, rather than the client connection rejected.
### `telemetry` parameters
- `unauthenticated_metrics_access` `(string: "false")` - If set to true, allows
unauthenticated access to the `/v1/sys/metrics` endpoint.
!-->
## `tcp` listener examples
Refer to the following sections for examples of `tcp` listeners.
### Configure TLS
This example shows enabling a TLS listener.
```hcl
listener "tcp" {
purpose = "api"
tls_cert_file = "/etc/certs/Boundary.crt"
tls_key_file = "/etc/certs/Boundary.key"
}
```
### Configure custom http response headers
This example shows configuring custom http response headers. Operators can configure
`"custom_api_response_headers"` and `"custom_ui_response_headers"` sub-stanzas in the listener stanza to
set custom http headers that are appropriate to their applications. Examples of such headers are
`"Strict-Transport-Security"` and `"Content-Security-Policy"` which are known HTTP headers, and could be
configured to harden the security of an application communicating with the Boundary endpoints. Note that
vulnerability scans often examine such security related HTTP headers. In addition, you can configure
application-specific custom headers. For example, `"X-Custom-Header"` has been configured in the example
below.
```hcl
listener "tcp" {
custom_api_response_headers {
"default" = {
"Strict-Transport-Security" = ["max-age=31536000; includeSubDomains"],
"X-Custom-Header" = ["Custom Header Default Value"],
},
"2xx" = {
"X-Custom-Header" = ["Custom Header Value 1", "Custom Header Value 2"],
},
"301" = {
"Strict-Transport-Security" = ["max-age=31536000"],
},
}
custom_ui_response_headers {
"default" = {
"Strict-Transport-Security" = ["max-age=31536000; includeSubDomains"],
"Content-Security-Policy" = ["default-src 'none'; script-src 'self' 'wasm-unsafe-eval'; frame-src 'self'; font-src 'self'; connect-src 'self'; img-src 'self' data:; style-src 'self'; media-src 'self'; manifest-src 'self'; style-src-attr 'self'; frame-ancestors 'self'"],
"X-Custom-Header" = ["Custom Header Default Value"],
},
"2xx" = {
"X-Custom-Header" = ["Custom Header Value 1", "Custom Header Value 2"],
},
"301" = {
"Strict-Transport-Security" = ["max-age=31536000"],
"Content-Security-Policy" = ["default-src 'none'; script-src 'none'; connect-src 'none'"],
},
}
}
```
Note that Boundary requires `script-src 'wasm-unsafe-eval'` for playback of session recordings.
In situations where a header is defined under several status code subsections,
Boundary returns the header matching the most specific response code. For example,
with the config example below, a `307` response would return `307 Custom header value`,
while a `306` would return `3xx Custom header value`.
```hcl
listener "tcp" {
custom_api_response_headers {
"default" = {
"X-Custom-Header" = ["default Custom header value"]
},
"3xx" = {
"X-Custom-Header" = ["3xx Custom header value"]
},
"307" = {
"X-Custom-Header" = ["307 Custom header value"]
}
}
}
```
There may also be situations where default or collective status headers have been defined,
but you do not want them returned for a specific status code. You can unset headers at any
level by defining the headers as an empty list.
```hcl
listener "tcp" {
custom_api_response_headers {
"default" = {
"X-Custom-Header" = ["default Custom header value"]
},
"3xx" = {
"X-Custom-Header" = ["3xx Custom header value"]
},
"307" = {
// Do not return this header for 307 responses
"X-Custom-Header" = []
}
}
}
```
### Listen on mulitple interfaces
This example shows Boundary listening on a private interface, as well as localhost.
```hcl
listener "tcp" {
purpose = "api"
address = "127.0.0.1:9200"
}
listener "tcp" {
purpose = "cluster"
address = "10.0.0.5:9201"
}
```
[golang-tls]: https://golang.org/src/crypto/tls/cipher_suites.go
[api-addr]: /boundary/docs/configuration#api_addr
[cluster-addr]: /boundary/docs/configuration#cluster_addr
@@ -1,204 +0,0 @@
---
layout: docs
page_title: Unix domain socket listener configuration
description: >-
Learn about using the Unix listener on a specified Unix domain socket, and view configurable parameters. View example Unix listener configurations.
---
# `unix` listener
The `unix` listener configures Boundary to listen on a Unix domain socket.
~> **Note:** This is only available for listeners for `api` and `cluster` purpose.
Unix sockets cannot currently be used for `"proxy"` purpose on a Worker.
```hcl
listener "unix" {
purpose = "api"
address = "/var/run/boundary-api.sock"
}
```
The `listener` stanza may be specified more than once to make Boundary listen on
multiple interfaces; however, only one listener marked for `cluster` purpose is
allowed.
## `unix` listener parameters
Refer to the following sections for the supported `unix` listener parameters.
### General
- `purpose` `(string: "")` - Specifies the purpose. Can be `api`, `ops` or `cluster`.
- `address` `(string: "")` – Specifies the address (filesystem path) to bind to
for listening.
- `http_idle_timeout` `(string: "5m")` - Specifies the maximum amount of time to
wait for the next request when keep-alives are enabled. If `http_idle_timeout`
is zero, the value of `http_read_timeout` is used. If both are zero, the value
of `http_read_header_timeout` is used. This is specified using a label suffix
like `"30s"` or `"1h"`.
- `http_read_header_timeout` `(string: "10s")` - Specifies the amount of time
allowed to read request headers. This is specified using a label suffix like
`"30s"` or `"1h"`.
- `http_read_timeout` `(string: "30s")` - Specifies the maximum duration for
reading the entire request, including the body. This is specified using a
label suffix like `"30s"` or `"1h"`.
- `http_write_timeout` `(string: "0")` - Specifies the maximum duration before
timing out writes of the response and is reset whenever a new request's header
is read. The default value of `"0"` means infinity. This is specified using a
label suffix like `"30s"` or `"1h"`.
<!-- We don't have this implemented yet
- `max_request_size` `(int: 33554432)` – Specifies a hard maximum allowed
request size, in bytes. Defaults to 32 MB. Specifying a number less than or
equal to `0` turns off limiting altogether.
!-->
- `max_request_duration` `(string: "90s")` – Specifies the maximum
request duration allowed before Boundary cancels the request. This overrides
`default_max_request_duration` for this listener.
- `cors_enabled` `(boolean: true)` - Specifies if CORS should be enabled, which
allows Boundary to support external browser-based clients (not including admin
UI), such as Boundary Desktop. If not specified, CORS will be enabled with an
allowed origin that grants access to Boundary Desktop, unless overridden with
`cors_disable_default_allowed_origin_values`.
- `cors_disable_default_allowed_origin_values` `(boolean: false)` - Specifies
that Boundary should not append default allowed origin values to any specified
in `cors_allowed_origins`, such as Boundary Desktop's origin. This also
disables the behavior of enabling CORS if `cors_enabled` is not specified.
- `cors_allowed_origins` `(array(string): ["serve://boundary"])` - An array of
allowed CORS origins. Origins must include protocol, host, and port (if port
is different than the default for the specified protocol). To allow all
origins, set to `['*']`. By default, Boundary Desktop's origin
`serve://boundary` is appended to any values included here, unless
`cors_disable_default_allowed_origin_values` is specified.
- `cors_allowed_headers` `(array(string): [])` – An array specifying headers
that are permitted to be on cross-origin requests. Headers set via this
parameter will be appended to the list of headers that Boundary allows by
default, such as `"Content-Type"`, `"X-Requested-With"`, and
`"Authorization"`.
### TLS
~> `tls` parameters are valid for `api` and `ops` listeners. `cluster`
and `proxy` connections use their own ephemeral TLS stacks. For more
information, see [the connections security concepts
page](/boundary/docs/concepts/security/connections-tls).
- `tls_disable` `(string: "false")` – Specifies if TLS will be disabled. Boundary
assumes TLS by default, so you must explicitly disable TLS to opt-in to
insecure communication.
- `tls_cert_file` `(string: <required-if-enabled, reloads-on-SIGHUP>)` –
Specifies the path to the certificate for TLS. To configure the listener to
use a CA certificate, concatenate the primary certificate and the CA
certificate together. The primary certificate should appear first in the
combined file. On `SIGHUP`, the path set here _at Boundary startup_ will be
used for reloading the certificate; modifying this value while Boundary is
running will have no effect for `SIGHUP`s.
- `tls_key_file` `(string: <required-if-enabled, reloads-on-SIGHUP>)` –
Specifies the path to the private key for the certificate. If the key file is
encrypted, you will be prompted to enter the passphrase on server startup. The
passphrase must stay the same between key files when reloading your
configuration using `SIGHUP`. On `SIGHUP`, the path set here _at Boundary
startup_ will be used for reloading the certificate; modifying this value
while Boundary is running will have no effect for `SIGHUP`s.
- `tls_min_version` `(string: "tls12")` – Specifies the minimum supported
version of TLS. Accepted values are "tls10", "tls11", "tls12" or "tls13".
!> TLS 1.1 and lower are generally considered insecure.
- `tls_max_version` `(string: "tls13")` – Specifies the maximum supported
version of TLS, useful if appliances (e.g. load balancers) are not yet capable
of higher levels. Accepted values are "tls10", "tls11", "tls12" or "tls13".
!> TLS 1.1 and lower are generally considered insecure.
- `tls_cipher_suites` `(string: "")` – Override the default list of supported
ciphersuites (which varies by TLS version) with the the specified
comma-delimited list. The list of all available ciphersuites is available in
the [Golang TLS documentation][golang-tls].
- `tls_prefer_server_cipher_suites` `(string: "false")` – Specifies to prefer the
server's ciphersuite over the client ciphersuites.
- `tls_require_and_verify_client_cert` `(string: "false")` – Turns on client
authentication for this listener; the listener will require a presented
client cert that successfully validates against system CAs.
- `tls_client_ca_file` `(string: "")` – PEM-encoded Certificate Authority file
used for checking the authenticity of client.
<!-- Not enabled yet
- `x_forwarded_for_authorized_addrs` `(string: <required-to-enable>)` –
Specifies the list of source IP CIDRs for which an X-Forwarded-For header
will be trusted. Comma-separated list or JSON array. This turns on
X-Forwarded-For support.
- `x_forwarded_for_hop_skips` `(string: "0")` – The number of addresses that will be
skipped from the _rear_ of the set of hops. For instance, for a header value
of `1.2.3.4, 2.3.4.5, 3.4.5.6`, if this value is set to `"1"`, the address that
will be used as the originating client IP is `2.3.4.5`.
- `x_forwarded_for_reject_not_authorized` `(string: "true")` – If set false,
if there is an X-Forwarded-For header in a connection from an unauthorized
address, the header will be ignored and the client connection used as-is,
rather than the client connection rejected.
- `x_forwarded_for_reject_not_present` `(string: "true")` – If set false, if
there is no X-Forwarded-For header or it is empty, the client address will be
used as-is, rather than the client connection rejected.
### `telemetry` parameters
- `unauthenticated_metrics_access` `(string: "false")` - If set to true, allows
unauthenticated access to the `/v1/sys/metrics` endpoint.
!-->
## `unix` listener examples
Refer to the following sections for examples of `unix` listeners.
### Configure TLS
This example shows enabling a TLS listener.
```hcl
listener "unix" {
purpose = "api"
address = "/var/run/boundary-api.sock"
tls_cert_file = "/etc/certs/Boundary.crt"
tls_key_file = "/etc/certs/Boundary.key"
}
```
### Listen on multiple interfaces
This example shows Boundary listening on a private interface, as well as localhost.
```hcl
listener "tcp" {
purpose = "api"
address = "/var/run/boundary-api.sock"
}
listener "tcp" {
purpose = "cluster"
address = "/var/run/boundary-cluster.sock"
}
```
[golang-tls]: https://golang.org/src/crypto/tls/cipher_suites.go
[api-addr]: /boundary/docs/configuration#api_addr
[cluster-addr]: /boundary/docs/configuration#cluster_addr
@@ -0,0 +1,17 @@
---
layout: docs
page_title: Listeners - configuration reference
description: >-
The listener stanza configures the addresses and ports on which Boundary will respond to requests.
---
# `listener` stanza
The `listener` stanza configures the addresses and ports on which Boundary will
respond to requests. At this time, there are two listener types:
[TCP](/boundary/docs/configuration/listeners/tcp-listeners) and [Unix](/boundary/docs/configuration/listeners/unix-listeners).
## `listener` purpose
@include '/configuration-reference/listeners/listener-purpose.mdx'
@@ -0,0 +1,55 @@
---
layout: docs
page_title: TCP listeners - configuration reference
description: >-
Learn about using the TCP listener on a TCP address and port, and view configurable parameters. Understand custom response headers. View example configurations.
---
# `tcp` listener
@include '/configuration-reference/listeners/tcp-intro.mdx'
## Listener's custom response headers
@include '/configuration-reference/listeners/tcp-custom-response-headers.mdx'
## `tcp` listener parameters
Refer to the following sections for `tcp` listener parameters.
### General
@include '/configuration-reference/listeners/tcp-general-parameters.mdx'
### `custom_api_response_headers` parameters
@include '/configuration-reference/listeners/tcp-custom-api-response-headers.mdx'
### `custom_ui_response_headers` parameters
@include '/configuration-reference/listeners/tcp-custom-ui-response-headers.mdx'
### TLS
@include '/configuration-reference/listeners/tcp-tls.mdx'
<!-- Not enabled yet
### `telemetry` parameters
@include '/configuration-reference/listeners/tcp-telemetry.mdx' !-->
## `tcp` listener examples
Refer to the following sections for examples of `tcp` listeners.
### Configure TLS
@include '/configuration-reference/listeners/tcp-configure-tls.mdx'
### Configure custom http response headers
@include '/configuration-reference/listeners/tcp-configure-custom-http-response-headers.mdx'
### Listen on mulitple interfaces
@include '/configuration-reference/listeners/tcp-listen-on-mulitple-interfaces.mdx'
@@ -0,0 +1,45 @@
---
layout: docs
page_title: Unix domain socket - listeners - configuration reference
description: >-
Learn about using the Unix listener on a specified Unix domain socket, and view configurable parameters. View example Unix listener configurations.
---
# `unix` listener
@include '/configuration-reference/listeners/unix-intro.mdx'
## `unix` listener parameters
Refer to the following sections for the supported `unix` listener parameters.
### General
@include '/configuration-reference/listeners/unix-general-parameters.mdx'
### TLS
@include '/configuration-reference/listeners/unix-tls-parameters.mdx'
<!-- Not enabled yet
### `telemetry` parameters
@include '/configuration-reference/listeners/unix-telemetry.mdx'
!-->
## `unix` listener examples
Refer to the following sections for examples of `unix` listeners.
### Configure TLS
@include '/configuration-reference/listeners/unix-configure-tls.mdx'
### Listen on multiple interfaces
@include '/configuration-reference/listeners/unix-listen-on-multiple-interfaces.mdx'
[golang-tls]: https://golang.org/src/crypto/tls/cipher_suites.go
[api-addr]: /boundary/docs/configuration#api_addr
[cluster-addr]: /boundary/docs/configuration#cluster_addr
@@ -7,10 +7,8 @@ description: >-
# `plugin` stanza
The `plugin` stanza configures plugin-specific parameters. The plugin system was
introduced in Boundary 0.7.0 and is currently internal; over time, the intent is
to provide a mechanism for third-party plugins to be able to be used. Available
plugins are currently bundled with Boundary and executed automatically.
The `plugin` stanza configures plugin-specific parameters. The plugin system is currently internal; over time, the intent is to provide a mechanism for third-party plugins to be able to be used.
Available plugins are currently bundled with Boundary and executed automatically.
There is currently one configuration parameter available:
@@ -1,699 +0,0 @@
---
layout: docs
page_title: Configure storage bucket policies
description: >-
Configure storage bucket policies to manage the lifecycles of session recordings. Specify retention and deletion policies to codify compliance periods.
---
# Configure storage bucket policies
<EnterpriseAlert product="boundary">This feature requires <a href="https://www.hashicorp.com/products/boundary">HCP Boundary Plus or Boundary Enterprise</a></EnterpriseAlert>
As of Boundary 0.15.0, retention policies can codify storage bucket lifecycle management for [session recordings][].
A Boundary resource known as a [storage bucket][] is used to store recorded sessions.
A resource known as a [storage policy][] is used to codify how long session recordings must be kept and when they should be deleted.
A storage policy exists in either the global scope or an org scope.
Storage policies that are created in the global scope can be associated with any org scope.
However, a storage policy created in an org scope can only be associated with that org scope.
Any storage policies associated with an org scope are deleted when you delete the org itself.
For more information about using session recording to audit user sessions, refer to [Auditing](/boundary/docs/concepts/auditing).
## Requirements
Before you can create a storage bucket in Boundary, you must ensure that your environment meets certain requirements. Session recording requires specific configuration for both the external storage provider and the Boundary worker.
A Boundary worker configured for local storage is also required to set up session recording and configure recording bucket policies.
Refer to [Create a storage bucket](/boundary/docs/configuration/session-recording/create-storage-bucket) to learn more about setting up storage for session recordings.
## Example storage policies
A storage policy defines how long the recording within a scope should retain its session recordings. Storage policy examples include:
- Keep forever
- Do not delete
- Do not retain
- Custom retention period
## Create a storage policy
Complete the following steps to create a storage policy in Boundary for session recording:
<Tabs>
<Tab heading="UI" group="ui">
1. Log in to Boundary.
1. Click **Storage Policies** in the navigation panel in the `global` scope.
1. Click **Create a new storage policy**.
1. Complete the following fields to create the Boundary storage policy:
- **Name**: (Optional) The name field is optional, but if you enter a name it must be unique.
- **Description**: (Optional) An optional description of the Boundary storage policy for identification purposes.
- **Retention Policy**: (Required) Specifies how long a recording must be stored, in days.
Policy values include:
- `Forever`: If enabled, the **Deletion Policy** field is disabled.
- `Custom`: Specify a custom retention policy in days.
- `Do not protect, allow deletion at any time`
- `SOC 2 (7 years)`
- `HIPPA (6 years)`
- **Deletion Policy**: (Required) Specifies when to delete a recording, in days.
Policy values include:
- `Do not delete`: Do not delete recordings, even after the retention policy is met.
- `Custom`: Specifies the number of days after creation when a session recording should be deleted.
As an example, the following settings would create a SOC 2 compliant policy:
- **Name**: `soc2-policy`
- **Description**: `SOC 2 compliant storage policy for session recordings`
- **Retention Policy**: `SOC 2 (7 years)`
- **Deletion Policy**: `Custom`
Delete after: `2657` days
Toggle the switch beside **Allow orgs to override**.
1. Click **Save**.
</Tab>
<Tab heading="CLI" group="cli">
1. Log in to Boundary.
1. Use the following command to create a storage policy in Boundary:
```shell-session
$ boundary policies create storage \
-name soc2-policy \
-description 'SOC 2 compliant storage policy for session recordings' \
-scope-id global \
-retain-for-days 2557 \
-retain-for-overridable false \
-delete-after-days 2657 \
-delete-after-overridable true
```
The following [attributes](/boundary/docs/concepts/domain-model/storage-policies) can be used when defining a storage policy:
- `name`: (Optional) An optional human readable name.
- `description`: (Optional) An optional human readable description.
- `scope-id`: (Optional) The ID of the scope (global or an org) that owns the policy. Defaults to `global`.
- `retain-for-days`: (Optional) The number of days a session recording must be kept. A value of `-1` indicates an infinite retention.
- `retain-for-overridable`: (Optional) Indicates that a lower scope can override the `retain_for_days` attribute value. Defaults to `true`.
- `delete-after-days`: (Optional) The number of days after creation when a session recording should be deleted.
- `delete-after-overridable`: (Optional) Indicates that a lower scope can override the `delete_after_days` attribute value. Defaults to `true`.
</Tab>
<Tab heading="Terraform" group="terraform">
Apply the following Terraform policy:
```hcl
resource "boundary_policy_storage" "example" {
name = "soc2-policy"
description = "SOC 2 compliant storage policy for session recordings"
scope_id = data.boundary_scope.org.id
retain_for_days = 2557
retain_for_overridable = false
delete_after_days = 2657
delete_after_overridable = true
}
```
</Tab>
<Tab heading="API call using cURL" group="api">
The following API call is an example of creating a storage policy in Boundary:
```shell-session
$ curl --header "Content-Type: application/json" \
--header "Authorization: Bearer $(boundary config get-token)" \
--request POST \
--data '{"attributes":{"retain_for":{"days":2557,"overridable":false},"delete_after":{"days":2657,"overridable":true}},"scope_id":"global","description":"SOC 2 compliant storage policy for session recordings","name":"soc2-policy","type":"storage"}' \
$BOUNDARY_ADDR/v1/policies | jq
```
<Note>
This example uses [jq](https://stedolan.github.io/jq/download/) to process the JSON output for readability.
</Note>
**Example output:**
<CodeBlockConfig hideClipboard>
```plaintext
{
"id": "pst_wV4bWSYYwL",
"scope_id": "global",
"scope": {
"id": "global",
"type": "global",
"name": "global",
"description": "Global Scope"
},
"name": "soc2-api-test",
"description": "SOC 2 compliant storage policy for session recordings",
"created_time": "2024-01-26T03:44:58.119640Z",
"updated_time": "2024-01-26T03:44:58.119640Z",
"type": "storage",
"version": 1,
"attributes": {
"delete_after": {
"days": 2657,
"overridable": true
},
"retain_for": {
"days": 2557,
"overridable": false
}
},
"authorized_actions": [
"no-op",
"read",
"update",
"delete"
]
}
```
</CodeBlockConfig>
</Tab>
</Tabs>
In this example, recordings stored within the global scope must be retained for 7 years (2557 days), and will be automatically deleted 100 days later (at 2657 days). Scopes beneath `global` will not be able to override this retention policy, but are able to override the deletion policy.
<Warning>
Boundary does not support an undo action. Storage policies are meant to enforce compliance to a specific law or regulation. Updating the storage policy of a session recording can have immediate and possibly unexpected results such as the immediate deletion of session recordings.
</Warning>
## Attach storage policies to a scope
You must apply storage policies to a scope (`global` or a specific org) to take effect. Once attached, all recordings within the child scopes inherit the storage policy, unless overridden by a policy applied to the child scope.
The following example applies the policy created above to an org named `prod-databases` with the org ID `o_aDkVBCDTvY`.
<Tabs>
<Tab heading="UI" group="ui">
1. Log in to Boundary.
1. Click **Orgs** in the navigation panel and select the `prod-databases` org.
1. Click **Org Settings** in the navigation panel for the `prod-databases` org.
1. Under **Storage Policy**, click **Add Storage Policy**.
1. Select the `soc2-policy`.
1. Click **Save**. This applies the policy to this scope and its children.
</Tab>
<Tab heading="CLI" group="cli">
1. Log in to Boundary.
1. Obtain the storage policy ID:
<CodeBlockConfig highlight="1,3">
```shell-session
$ boundary policies list
Policy information:
ID: pst_WZ3SQSSYJY
Version: 1
Type: storage
Name: soc2-policy
Description: SOC 2 compliant storage policy for session recordings
Authorized Actions:
read
update
delete
no-op
```
</CodeBlockConfig>
1. Use the following command to apply the storage policy to the `prod-databases` org:
```shell-session
$ boundary scopes attach-storage-policy \
-id o_aDkVBCDTvY \
-storage-policy-id pst_WZ3SQSSYJY
```
</Tab>
<Tab heading="Terraform" group="terraform">
Apply the following Terraform policy:
```hcl
resource "boundary_scope_policy_attachment" "example" {
policy_id = boundary_policy_storage.example.id
scope_id = data.boundary_scope.org.id
}
```
</Tab>
<Tab heading="API call using cURL" group="api">
The following API call is an example of attaching a storage policy to a scope.
First, obtain the storage policy ID.
```shell-session
$ curl --header "Content-Type: application/json" \
--header "Authorization: Bearer $(boundary config get-token)" \
--request POST \
$BOUNDARY_ADDR/v1/policies?scope_id=global' | jq
```
In this example, the storage policy ID is `pst_WZ3SQSSYJY`.
Now attach the policy to the org.
```shell-session
$ curl --header "Content-Type: application/json" \
--header "Authorization: Bearer $(boundary config get-token)" \
--request POST \
--data '{"storage_policy_id":"pst_WZ3SQSSYJY","version":2}'' \
$BOUNDARY_ADDR/v1/scopes/o_aDkVBCDTvY:attach-storage-policy' | jq
```
**Example output:**
<CodeBlockConfig hideClipboard>
```plaintext
{
"id": "o_aDkVBCDTvY",
"scope_id": "global",
"scope": {
"id": "global",
"type": "global",
"name": "global",
"description": "Global Scope"
},
"name": "prod-databases",
"created_time": "2024-01-26T04:22:45.891800Z",
"updated_time": "2024-01-26T05:00:27.333892Z",
"version": 3,
"type": "org",
"authorized_actions": [
"delete",
"attach-storage-policy",
"detach-storage-policy",
"no-op",
"read",
"update"
],
"authorized_collection_actions": {
"auth-methods": [
"create",
"list"
],
"auth-tokens": [
"list"
],
"groups": [
"create",
"list"
],
"policies": [
"list",
"create"
],
"roles": [
"list",
"create"
],
"scopes": [
"list",
"list-keys",
"rotate-keys",
"list-key-version-destruction-jobs",
"destroy-key-version",
"create"
],
"session-recordings": [
"list"
],
"storage-buckets": [
"list",
"create"
],
"users": [
"create",
"list"
]
},
"storage_policy_id": "pst_WZ3SQSSYJY"
}
```
</CodeBlockConfig>
</Tab>
</Tabs>
### Verify attached policies
Check that the storage policy was successfully attached to the `prod-databases` scope.
<Tabs>
<Tab heading="UI">
1. Log in to Boundary.
1. Click **Orgs** in the navigation panel and select the `prod-databases` org.
1. Click **Org Settings** in the navigation panel for the `prod-databases` org.
1. Verify that the `soc2-policy` is listed under **Storage Policy**.
</Tab>
<Tab heading="CLI" group="cli">
1. Log in to Boundary.
1. Read the details of the `prod-databases` org:
<CodeBlockConfig highlight="1,5-6">
```shell-session
$ boundary scopes read -id o_aDkVBCDTvY
Scope information:
Created Time: Thu, 25 Jan 2024 21:22:45 MST
ID: o_aDkVBCDTvY
Name: prod-databases
Storage Policy ID: pst_WZ3SQSSYJY
Updated Time: Thu, 25 Jan 2024 22:00:27 MST
Version: 7
Scope (parent):
ID: global
Name: global
Type: global
Authorized Actions:
detach-storage-policy
no-op
read
update
delete
attach-storage-policy
...
... More Output ...
...
```
</CodeBlockConfig>
Verify that the `soc2-policy` ID (`pst_WZ3SQSSYJY` in this example) is listed under **Storage Policy ID**.
</Tab>
<Tab heading="API call using cURL" group="api">
The following API call is an example of reading the details of the `prod-databases` scope by ID (`o_aDkVBCDTvY` in this example).
```shell-session
$ curl --header "Content-Type: application/json" \
--header "Authorization: Bearer $(boundary config get-token)" \
--request GET \
$BOUNDARY_ADDR/v1/scopes/o_aDkVBCDTvY | jq
```
**Example output:**
<CodeBlockConfig hideClipboard highlight="2-3,63">
```plaintext
{
"id": "o_aDkVBCDTvY",
"scope_id": "global",
"scope": {
"id": "global",
"type": "global",
"name": "global",
"description": "Global Scope"
},
"name": "prod-databases",
"created_time": "2024-01-26T04:22:45.891800Z",
"updated_time": "2024-01-26T05:00:27.333892Z",
"version": 7,
"type": "org",
"authorized_actions": [
"update",
"delete",
"attach-storage-policy",
"detach-storage-policy",
"no-op",
"read"
],
"authorized_collection_actions": {
"auth-methods": [
"create",
"list"
],
"auth-tokens": [
"list"
],
"groups": [
"create",
"list"
],
"policies": [
"list",
"create"
],
"roles": [
"list",
"create"
],
"scopes": [
"list",
"list-keys",
"rotate-keys",
"list-key-version-destruction-jobs",
"destroy-key-version",
"create"
],
"session-recordings": [
"list"
],
"storage-buckets": [
"create",
"list"
],
"users": [
"create",
"list"
]
},
"storage_policy_id": "pst_WZ3SQSSYJY"
}
```
</CodeBlockConfig>
Verify that the `soc2-policy` ID (`pst_WZ3SQSSYJY` in this example) is listed under `storage_policy_id`.
</Tab>
</Tabs>
### Read and list session recordings
New session recordings under the `prod-databases` scope should now show a `retain_until` and `delete_after` date corresponding to the `soc2-policy` storage policy.
<Tabs>
<Tab heading="UI" group="ui">
1. Create a new session recording on a target within the `prod-databases` org.
1. Log in to Boundary.
1. Click **Session Recordings** in the navigation panel.
1. Click **View** for a new recording that was made after the storage policy was attached to the `prod-databases` scope.
1. Under **Session details**, verify that the *Retain until* and *Delete after* dates match the durations defined in the `soc2-policy`.
</Tab>
<Tab heading="CLI" group="cli">
1. Create a new session recording on a target within the `prod-databases` org.
1. Log in to Boundary.
1. List the available session recordings:
<CodeBlockConfig highlight="1,4">
```shell-session
$ boundary session-recordings list
Session Recording information:
ID: sr_nt5dFeBYdh
Storage Bucket ID: sb_DC8SPb9uc2
Created Time: Mon, 29 Jan 2024 23:25:31 MST
Updated Time: Tue, 30 Jan 2024 00:26:01 MST
Start Time: Mon, 29 Jan 2024 23:25:32 MST
End Time: Mon, 29 Jan 2024 23:25:53 MST
Type: ssh
State: available
Retain Until: Wed, 29 Jan 2031 23:25:53 MST
Delete After: Sat, 10 May 2031 00:25:53 MDT
Authorized Actions:
reapply-storage-policy
no-op
read
download
delete
```
</CodeBlockConfig>
Copy the recording **ID** (such as `sr_nt5dFeBYdh`).
1. Read the recording details by ID.
<CodeBlockConfig highlight="1,3,6-7,11">
```shell-session
$ boundary session-recordings read -id sr_nt5dFeBYdh
Session Recording information:
Bytes Down: 710
Bytes Up: 36
Created Time: Mon, 29 Jan 2024 23:25:31 MST
Delete After: Sat, 10 May 2031 00:25:53 MDT
Duration (Seconds): 21.01881
Endpoint: ssh://xx.xxx.xxx.xxx:22
ID: sr_nt5dFeBYdh
Retain Until: Wed, 29 Jan 2031 23:25:53 MST
Scope ID: global
Start Time: Mon, 29 Jan 2024 23:25:32 MST
State: available
Storage Bucket ID: sb_DC8SPb9uc2
Type: ssh
Updated Time: Mon, 29 Jan 2024 23:25:53 MST
...
... More Output ...
...
```
</CodeBlockConfig>
Verify that the `Retain Until` and `Delete After` dates match the durations defined in the 'soc2-policy'.
</Tab>
<Tab heading="API call using cURL" group="api">
1. Create a new session recording on a target within the `prod-databases` org.
1. The following API call is an example of reading the details of a session recording with the `soc2-policy` storage policy applied to the `prod-databases` scope.
List the available session recordings. This example recursively lists all recordings within the global scope.
```shell-session
$ curl --header "Content-Type: application/json" \
--header "Authorization: Bearer $(boundary config get-token)" \
--request GET \
$BOUNDARY_ADDR/v1/session-recordings?recursive=true&scope_id=global | jq
```
**Example output:**
<CodeBlockConfig hideClipboard highlight="4,57-58">
```plaintext
{
"items": [
{
"id": "sr_nt5dFeBYdh",
"scope": {
"id": "global",
"type": "global",
"name": "global",
"description": "Global Scope"
},
"storage_bucket_id": "sb_DC8SPb9uc2",
"created_time": "2024-01-30T06:25:31.873628Z",
"updated_time": "2024-01-30T07:26:01.182513Z",
"start_time": "2024-01-30T06:25:32.412373Z",
"end_time": "2024-01-30T06:25:53.431183Z",
"duration": "21.018810s",
"type": "ssh",
"state": "available",
"endpoint": "ssh://xx.xxx.xxx.xxx:22",
"create_time_values": {
"user": {
"id": "u_lLWuYy70Wo",
"name": "admin_user",
"description": "Global admin user",
"scope": {
"id": "global",
"type": "global",
"name": "global",
"description": "Global Scope"
}
},
"target": {
"id": "tssh_cjTsFSU10p",
"name": "recording-target",
"scope": {
"id": "p_ocJPxzrz2p",
"type": "project",
"name": "recording-project",
"parent_scope_id": "o_aDkVBCDTvY"
},
"session_max_seconds": 28800,
"session_connection_limit": -1,
"egress_worker_filter": "\"recording-worker\" in \"/tags/type\"",
"type": "ssh",
"attributes": {
"default_port": 22
}
}
},
"authorized_actions": [
"reapply-storage-policy",
"no-op",
"read",
"download",
"delete"
],
"retain_until": "2031-01-30T06:25:53.431183Z",
"delete_after": "2031-05-10T06:25:53.431183Z"
}
],
"response_type": "complete",
"list_token": "GnJNt3mPNy6Cp62MUBCnZPdrQF7cvh4udEoW4CjL5k2ufvesMfKAheSJyNHmKf3zwL5aVKHT4P6q",
"sort_by": "created_time",
"sort_dir": "desc",
"est_item_count": 1
}
```
</CodeBlockConfig>
1. Verify that the `retain_until` and `delete_after` dates match the durations defined in the `soc2-policy`.
Alternatively, the recording details can also be queried directly by ID:
```shell-session
$ curl --header "Content-Type: application/json" \
--header "Authorization: Bearer $(boundary config get-token)" \
--request GET \
$BOUNDARY_ADDR/v1/session-recordings/sr_nt5dFeBYdh | jq
```
</Tab>
</Tabs>
<Note>
Existing recordings within a scope or its children do not automatically have new or updated polices applied to them. Policies must be re-applied to existing recordings to take effect. Refer to the [Update storage bucket policies](/boundary/docs/configuration/session-recording/update-storage-policy) page for more details.
</Note>
### Manual deletion
Deleting a session recording will set the `delete_after` field of a session recording to the current database time. Deleting a session recording will fail if the retention duration has not been met.
If `delete_after` or `delete_time` is after the current time, the session recording will no longer be included in list responses; it also cannot be read, downloaded or played back.
## Next steps
After the storage policy is configured in Boundary, new recordings within the applied scope adhere to the defined policy. To retroactively apply the configured policy to existing recordings, refer to [update storage bucket policies](/boundary/docs/configuration/session-recording/update-storage-policy).
[storage bucket]: /boundary/docs/concepts/domain-model/storage-buckets
[storage policy]: /boundary/docs/concepts/domain-model/storage-policy
[session recordings]: /boundary/docs/concepts/domain-model/session-recordings
@@ -1,115 +0,0 @@
---
layout: docs
page_title: Configure workers for local storage
description: >-
Configure workers for session recording storage. View requirements and an example configuration. Understand possible storage states for local and remote storage.
---
# Configure workers for session recording
<EnterpriseAlert product="boundary">This feature requires <a href="https://www.hashicorp.com/products/boundary">HCP Boundary or Boundary Enterprise</a></EnterpriseAlert>
Session recording requires that you configure at least one worker for local storage.
<Note>
You cannot use an HCP managed worker for the local storage. HCP Boundary users must configure a self-managed worker to enable session recording.
</Note>
## Requirements
Workers that you configure for storage must:
- Have access to the external storage provider
- Have an accessible directory defined by `recording_storage_path` for storing session recordings while they are in progress. On session closure, Boundary moves the local session recording to remote storage and deletes the local copy.
- For HCP Boundary, refer to the [Self-managed worker configuration](/hcp/docs/boundary/self-managed-workers/session-recording) documentation.
- For Boundary Enterprise, refer to the refer to the [worker configuration](/boundary/docs/configuration/worker/worker-configuration#session-recording) documentation.
- Have available disk space defined by `recording_storage_minimum_available_capacity`. If you do not configure the minimum available storage capacity, Boundary uses the default value of 500MiB.
For more information about how much space is required to store BSR files, refer to [storage considerations](/boundary/docs/configuration/session-recording#storage-considerations).
- Run Darwin, Windows, or Linux. The following binaries are not supported for session recording: NetBSD, OpenBSD, Solaris.
## Local storage
Workers require sufficient local disk space in the `recording_storage_path` to store session recordings while they are in progress. Local disk space is also required for session recording playback.
The `recording_storage_minimum_available_capacity` vaule defines the minimum available disk space that must be available on the worker for session recording and session recording playback. This threshold determines the local storage state of the worker.
The possible storage states determined by the `recording_storage_minimum_available_capacity` are:
- `Available`: The worker is above the storage threshold and is available to proxy sessions that are enabled with session recording.
- `Low storage`: The worker is below the storage threshold. Existing sessions can continue without interruption, but new sessions that are enabled with session recording cannot be proxied. The worker is not available to record new sessions or play back existing recordings.
- `Critically low storage`: The worker is below half the storage threshold. Existing sessions that are enabled with session recording will be forcefully closed. The worker is not available to record new sessions or play back existing recordings.
- `Out of storage`: The worker is out of local disk space. It is not available to record new sessions or play back existing recordings. The worker is in a unrecoverable state. An administrator must intervene to remedy the issue.
- `Not configured`: The worker does not have a `recording_storage_path` configured.
- `Unknown`: The default local storage state of a worker. This state indicates that the local storage state of a worker is not yet known. Older workers (< 0.16.0) will be in this state.
If a worker is in an unhealthy local storage state, Boundary does not allow new session recordings or session recording playback until the worker is in an `available` local storage state.
## Remote storage state
The workers that you configure for session recording storage must have access to the external object store. Workers report permission states back to Boundary, depending on the availability of the external object store.
Boundary uses the permission states to determine what actions the worker can perform on the configured external storage.
Workers can have the following permission states:
- `read`: The worker can read from the external storage. It can also play back recorded sessions, if the permission state is `ok`.
- `write`: The worker can write to the external storage. It can also record sessions, if the permission state is `ok`.
- `delete`: The worker can delete data from the external storage. It can also clean up recorded sessions, if the permission state is `ok`.
Boundary uses the permission states to determine the remote storage state of a worker. The worker can have the following remote storage states:
- `available`: All permission states are healthy. The worker has the required access to the external storage.
- `error`: One or more of the permission states are not healthy. Workers may not be able to perform certain actions on the external storage.
Boundary periodically checks the states of any workers that use the external storage, and then reports them back to the controller.
You can check the remote storage state of a worker using the `boundary workers read -id $WORKER_ID` command.
```
Worker information:
Active Connection Count: 0
Address: 0.0.0.0:9202
Created Time: Tue, 04 Jun 2024 13:52:27 PDT
ID: w_RPfBj239to
Last Status Time: 2024-06-04 20:55:35.589282 +0000 UTC
Local Storage State: available
Remote Storage State:
sb_fhde575e:
Status: available
Permissions:
Write: ok
Read: ok
Delete: ok
sb_jksdgh4:
Status: error
Permissions:
Write: error
Read: ok
Delete: ok
Release Version: Boundary v0.17.0+ent
Type: pki
Updated Time: Tue, 04 Jun 2024 13:55:35 PDT
Version: 1
```
## Example configuration
Refer to the following example configuration to configure workers for session recording storage:
```hcl
worker {
auth_storage_path = "/boundary/demo-worker-1"
initial_upstreams = ["10.0.0.1"]
recording_storage_path = "/local/storage/directory"
recording_storage_minimum_available_capacity = "500MB"
}
```
## Next steps
After you configure worker storage, you can configure the external storage for [Amazon S3](/boundary/docs/configuration/session-recording/storage-providers/configure-s3), [MinIO](/boundary/docs/configuration/session-recording/storage-providers/configure-minio), or an [S3-compliant provider](/boundary/docs/configuration/session-recording/storage-providers/configure-s3-compliant).
@@ -1,486 +0,0 @@
---
layout: docs
page_title: Create a storage bucket
description: >-
Create a storage bucket in an external storage provider to store recorded sessions. You can review recorded sessions later for compliance and threat management.
---
# Create a storage bucket
<EnterpriseAlert product="boundary">This feature requires <a href="https://www.hashicorp.com/products/boundary">HCP Boundary Plus or Boundary Enterprise</a></EnterpriseAlert>
User sessions can be recorded and audited using Boundary 0.13 or greater. A Boundary resource known as a [storage bucket](/boundary/docs/concepts/domain-model/storage-buckets) is used to store the recorded sessions.
The storage bucket represents a bucket in an external storage provider.
Before you can enable session recording, you must create one or more storage buckets in Boundary and associate them with the external store.
A storage bucket can only belong to the global scope or an org scope. A storage bucket that is associated with the global scope can be associated with any target. However, a storage bucket in an Org scope can only be associated with targets in a project from the same org scope. Any storage buckets associated with an Org scope are deleted when the org itself is deleted.
For more information about using session recording to audit user sessions, refer to [Auditing](/boundary/docs/concepts/auditing).
## Requirements
Before you create a storage bucket in Boundary, you must:
- [Configure workers for storage](/boundary/docs/configuration/session-recording/configure-worker-storage)
- Configure one of the following storage providers:
- [Amazon S3](/boundary/docs/configuration/session-recording/storage-providers/configure-s3)
- [MinIO](/boundary/docs/configuration/session-recording/storage-providers/configure-minio)
- [S3-compliant](/boundary/docs/configuration/session-recording/storage-providers/configure-s3-compliant)
## Create a storage bucket
Select a storage provider.
<Tabs>
<Tab heading="Amazon S3">
Complete the following steps to create a storage bucket in Boundary.
<Tabs>
<Tab heading="UI">
1. Log in to Boundary.
1. Click **Storage Buckets** in the navigation bar.
1. Click **New Storage Bucket**.
1. Complete the following fields to create the Boundary storage bucket:
- **Name**: (Optional) The name field is optional, but if you enter a name it must be unique.
- **Description**: (Optional) An optional description of the Boundary storage bucket for identification purposes.
- **Scope**: (Required) A storage bucket can belong to the Global scope or an Org scope.
It can only associated with targets from the scope it belongs to.
- **Provider**: (Required) The external storage bucket provider.
- **Bucket name**: (Required) Name of the AWS bucket you want to associate with the Boundary storage bucket.
- **Bucket prefix**: (Optional) A base path where session recordings are stored.
- **Region**: (Required) The AWS region to use.
- **Credential type**: (Required) The type of credential you want to use to authenticate to the external storage.
The required fields for creating a storage bucket vary depending on whether you configured the Amazon S3 bucket with static or dynamic credentials:
- **Static**: Authenticates to the storage bucket using an access key that AWS generates.
- **Dynamic**: Authenticates to the storage bucket using credentials that were generated by AWS `AssumeRole`.
<Tabs>
<Tab heading="Static credentials">
- **Access key ID**: (Required) The access key ID that AWS generates for the IAM user to use with the storage bucket.
- **Secret access key**: (Required) The secret access key that AWS generates for the IAM user to use with this storage bucket.
- **Worker filter**: (Required) A filter expression that indicates which Boundary workers have access to the storage. The filter must match an existing worker to create a Boundary storage bucket. This should be a boolean expression. To generate a worker filter in the correct format, toggle the **Show filter generator** switch. Refer to [filter examples](/boundary/docs/concepts/filtering/worker-tags#example-worker-filter-for-storage-buckets) to learn about worker tags and filters.
- **Disable credential rotation**: (Optional) Prevents the AWS plugin from automatically rotating credentials.
Although credentials are stored encrypted in Boundary, by default the [AWS plugin](https://github.com/hashicorp/boundary-plugin-aws) attempts to rotate the credentials you provide. The given credentials are used to create a new credential, and then the original credential is revoked.
After rotation, only Boundary knows the client secret the plugin uses.
</Tab>
<Tab heading="Dynamic credentials">
- **Role ARN**: (Required) The ARN (Amazon Resource Name) role that is attached to the EC2 instance that the self-managed worker runs on.
- **Role external ID**: (Optional) A required value if you delegate third party access to your AWS resources.
For more information, refer to the AWS documentation for [How to use an external ID when granting access to your AWS resources to a third party](https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_create_for-user_externalid.html).
- **Role session name**: (Optional) A unique identifier for the AWS session.
You can use this value to control how IAM principals and applications name their role sesions when they assume an IAM role.
By providing a session name, you enable tracking session actions in AWS CloudTrail logs.
For more information, refer to the AWS documentation for [Logging IAM and AWS STS API calls with AWS CloudTrail](https://docs.aws.amazon.com/IAM/latest/UserGuide/cloudtrail-integration.html).
- **Role tags**: An object with key-value pair attributes that is passed when you assume an IAM role.
For more information, refer to the AWS documentation for [Passing session tags in AWS STS](https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html).
- **Worker filter**: (Required) A filter expression that indicates which Boundary workers have access to the storage. The filter must match an existing worker to create a Boundary storage bucket. This should be a boolean expression. To generate a worker filter in the correct format, toggle the **Show filter generator** switch. Refer to [filter examples](/boundary/docs/concepts/filtering/worker-tags#example-worker-filter-for-storage-buckets) to learn about worker tags and filters.
- **Disable credential rotation**: (Required) Prevents the AWS plugin from automatically rotating credentials.
This option is required if you use dynamic credentials.
</Tab>
</Tabs>
1. Click **Save**.
</Tab>
<Tab heading="CLI">
The required fields for creating a storage bucket depend on whether you configured the Amazon S3 bucket with static or dynamic credentials:
<Tabs>
<Tab heading="Static credentials">
<Note>
The preferred way to authenticate to the S3 bucket is by using dynamic credentials. The example below uses static credentials instead.
</Note>
1. Log in to Boundary.
1. Use the following command to create a storage bucket in Boundary:
```shell-session
$ boundary storage-buckets create \
-bucket-name mybucket1 \
-plugin-name aws \
-scope-id o_1234567890 \
-worker-filter ‘“aws-worker” in “/tags/type”’ \
-secret ‘{“access_key_id”: “123456789” , “secret_access_key” : “123/456789/12345678”}’ \
-attributes ‘{“region”:”us-east-1”,”disable_credential_rotation”:true}’
```
Replace the values above with the following required AWS secrets and any [attributes](/boundary/docs/concepts/domain-model/storage-buckets) you want to associate with the Boundary storage bucket:
- `region`: (Required) The AWS region to use.
- `bucket-name`: (Required) The name of the AWS bucket you want to associate with the Boundary storage bucket.
- `plugin-name`: (Required) The name of the Boundary storage plugin.
- `scope_id`: (Required) A storage bucket can belong to the Global scope or an Org scope.
- `worker-filter`: (Required) A filter expression that indicates which Boundary workers have access to the storage. The filter must match an existing worker in order to create a Boundary storage bucket. Refer to [filter examples](/boundary/docs/concepts/filtering/worker-tags#example-worker-filter-for-storage-buckets) to learn about worker tags and filters.
- `secret`: (Required) The AWS credentials to use.
- `access_key_id`: (Required) The AWS access key to use.
- `secret_access_key_id`: (Required) The AWS secret access key to use.
This attribute contains the secret access key for static credentials.
- `attributes` or `-attr`: Attributes of the Amazon S3 storage bucket.
- `shared_credentials_file`: (Optional) The shared credentials file to use.
- `shared_credentials_profile`: (Optional) The profile name to use in the shared credentials file.
- `disable_credential_rotation`: (Optional) Prevents the AWS plugin from automatically rotating credentials.
Although credentials are stored encrypted in Boundary, by default the [AWS plugin](https://github.com/hashicorp/boundary-plugin-aws) attempts to rotate the credentials you provide. The given credentials are used to create a new credential, and then the original credential is revoked. After rotation, only Boundary knows the client secret the plugin uses.
</Tab>
<Tab heading="Dynamic credentials">
1. Log in to Boundary.
1. Use the following command to create a storage bucket in Boundary:
```shell-session
$ boundary storage-buckets create \
-bucket-name mys3bucket \
-plugin-name aws \
-scope-id o_1234567890 \
-worker-filter ‘“s3” in “/tags/type”’ \
-attributes ‘{“region”:”us-east-1”,”disable_credential_rotation”:true,"role_arn":"arn:aws:iam::123456789012:role/S3Access"}’
```
Replace the values above with the following required AWS secrets and any [attributes](/boundary/docs/concepts/domain-model/storage-buckets) you want to associate with the Boundary storage bucket:
- `region`: (Required) The AWS region to use.
- `bucket-name`: (Required) The name of the AWS bucket you want to associate with the Boundary storage bucket.
- `plugin-name`: (Required) The name of the Boundary storage plugin.
- `scope_id`: (Required) A storage bucket can belong to the Global scope or an Org scope.
- `worker-filter`: (Required) A filter expression that indicates which Boundary workers have access to the storage. The filter must match an existing worker in order to create a Boundary storage bucket. Refer to [filter examples](/boundary/docs/concepts/filtering/worker-tags#example-worker-filter-for-storage-buckets) to learn about worker tags and filters.
- `attributes` or `-attr`: Attributes of the Amazon S3 storage bucket.
- `role_arn`: (Required) The ARN (Amazon Resource Name) role that is attached to the EC2 instance that the self-managed worker runs on.
- `role_external_id`: (Optional) A required value if you delegate third party access to your AWS resources.
For more information, refer to the AWS documentation for [How to use an external ID when granting access to your AWS resources to a third party](https://docs.aws.amazon.com/IAM/latest/UserGuide/ id_roles_create_for-user_externalid.html).
- `role_session_name`: (Optional) A unique identifier for the AWS session.
You can use this value to control how IAM principals and applications name their role sesions when they assume an IAM role.
By providing a session name, you enable tracking session actions in AWS CloudTrail logs.
For more information, refer to the AWS documentation for [Logging IAM and AWS STS API calls with AWS CloudTrail](https://docs.aws.amazon.com/IAM/ latest/UserGuide/cloudtrail-integration.html).
- `role_tags`: (Optional) An object with key-value pair attributes that is passed when you assume an IAM role.
For more information, refer to the AWS documentation for [Passing session tags in AWS STS](https://docs.aws.amazon.com/IAM/latest/UserGuide/ id_session-tags.html).
</Tab>
</Tabs>
</Tab>
<Tab heading="Terraform" group="terraform">
The HCL code for creating a storage bucket is different depending on whether you configured the AWS S3 bucket with static or dynamic credentials. This page provides example configurations for a generic Terraform deployment.
Refer to the [Boundary Terraform provider documentation](https://registry.terraform.io/providers/hashicorp/boundary/latest/docs) to learn about the requirements for the following example attributes.
Support for Amazon S3 storage providers leverages the [Boundary AWS plugin](https://github.com/hashicorp/boundary-plugin-aws).
<Tabs>
<Tab heading="Static credentials">
<Note>
The preferred way to authenticate to the S3 bucket is by using dynamic credentials. The code below uses static credentials instead.
</Note>
Apply the following Terraform policy:
```hcl
resource "boundary_storage_bucket" "aws_static_credentials_example" {
name = "My aws storage bucket with static credentials"
description = "My first storage bucket"
scope_id = "o_1234567890"
plugin_name = "aws"
bucket_name = "mybucket1"
attributes_json = jsonencode({ "region" = "us-east-1" })
# recommended to pass in aws secrets using a file() or using environment variables
# the secrets below must be generated in aws using an iam user with programmatic access
secrets_json = jsonencode({
"access_key_id" = "aws_access_key_id_value",
"secret_access_key" = "aws_secret_access_key_value"
})
worker_filter = "\"aws-worker\" in \"/tags/type\""
}
output "storage_bucket_id" {
value = boundary_storage_bucket.aws_static_credentials_example.id
}
```
</Tab>
<Tab heading="Dynamic credentials">
Apply the following Terraform policy:
```hcl
resource "boundary_storage_bucket" "aws_dynamic_credentials_example" {
name = "My aws storage bucket with dynamic credentials"
description = "My first storage bucket"
scope_id = "o_1234567890"
plugin_name = "aws"
bucket_name = "mybucket1"
# the role_arn value should be the same arn used in the instance profile attached to the ec2 instance
# https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use_switch-role-ec2_instance-profiles.html
attributes_json = jsonencode({
"region" = "us-east-1"
"role_arn" = "arn:aws:iam::123456789012:role/S3Access"
"disable_credential_rotation" = true
})
worker_filter = "\"s3-worker\" in \"/tags/type\""
}
output "storage_bucket_id" {
value = boundary_storage_bucket.aws_dynamic_credentials_example.id
}
```
</Tab>
</Tabs>
</Tab>
</Tabs>
</Tab>
<Tab heading="MinIO">
Complete the following steps to create a storage bucket in Boundary.
<Note>
MinIO requires a service account and its associated access keys to set up a Boundary storage bucket. Refer to the [Configure MinIO](/boundary/docs/configuration/session-recording/storage-providers/configure-minio#minio-requirements) page to learn more.
</Note>
<Tabs>
<Tab heading="UI">
1. Log in to Boundary.
1. Click **Storage Buckets** in the navigation bar.
1. Click **New Storage Bucket**.
1. Complete the following fields to create the Boundary storage bucket:
- **Name**: (Optional) The name field is optional, but if you enter a name it must be unique.
- **Description**: (Optional) An optional description of the Boundary storage bucket for identification purposes.
- **Scope**: (Required) A storage bucket can belong to the Global scope or an Org scope.
It can only be associated with targets from the scope it belongs to.
- **Provider**: (Required) The external storage bucket provider.
- **Endpoint URL**: (Required) The fully-qualified endpoint pointing to a MinIO S3 API, such as `https://my-minio-instance.dev:9000`.
- **Bucket name**: (Required) Name of the AWS bucket you want to associate with the Boundary storage bucket.
- **Region**: (Optional) The region to configure the storage bucket for.
- **Access key ID** (Required): The MinIO service account's access key to use with this storage bucket.
- **Secret access key** (Required): The MinIO service account's secret key to use with this storage bucket.
- **Worker filter**: (Required) A filter expression that indicates which Boundary workers have access to the storage. The filter must match an existing worker to create a Boundary storage bucket. This should be a boolean expression. To generate a worker filter in the correct format, toggle the **Show filter generator** switch. Refer to [filter examples](/boundary/docs/concepts/filtering/worker-tags#example-worker-filter-for-storage-buckets) to learn about worker tags and filters.
- **Disable credential rotation**: (Optional) Controls whether the plugin will rotate the incoming credentials and manage a new MinIO service account. If this attribute is set to false, or not provided, the plugin will rotate the incoming credentials, using them to create a new MinIO service account, then delete the incoming credentials.
1. Click **Save**.
</Tab>
<Tab heading="CLI">
1. Log in to Boundary.
1. Use the following command to create a storage bucket in Boundary:
```shell-session
$ boundary storage-buckets create \
-bucket-name myminiobucket \
-plugin-name minio \
-scope-id o_1234567890 \
-bucket-prefix="foo/bar/zoo" \
-worker-filter '"minio-worker" in "/tags/type"' \
-attr endpoint_url="https://my-minio-instance.dev:9000" \
-attr region="REGION" \
-attr disable_credential_rotation=true \
-secret access_key_id="KEY" \
-secret secret_access_key="SECRET"
```
Replace the values above with the following required secrets and any optional [attributes](/boundary/docs/concepts/domain-model/storage-buckets) you want to associate with the Boundary storage bucket:
- `bucket-name`: (Required) Name of the MinIO bucket you want to associate with the Boundary storage bucket.
- `plugin-name`: (Required) The name of the Boundary storage plugin.
- `scope_id`: (Required) A storage bucket can belong to the Global scope or an Org scope.
- `worker-filter`: (Required) A filter expression that indicates which Boundary workers have access to the storage. The filter must match an existing worker in order to create a Boundary storage bucket. Refer to [filter examples](/boundary/docs/concepts/filtering/worker-tags#example-worker-filter-for-storage-buckets) to learn about worker tags and filters.
- `secret`: (Required) The MinIO credentials to use.
- `access_key_id` (Required): The MinIO service account's access key to use with this storage bucket.
- `secret_access_key` (Required): The MinIO service account's secret key to use with this storage bucket.
- `attributes` or `-attr`: Attributes of the MinIO storage bucket.
- `endpoint_url` (Required): Fully-qualified endpoint pointing to a MinIO S3 API.
- `region`: (Optional) The region to configure the storage bucket for.
- `disable_credential_rotation`: (Optional) Controls whether the plugin will rotate the incoming credentials and manage a new MinIO service account. If this attribute is set to `false`, or not provided, the plugin will rotate the incoming credentials to create a new MinIO service account, then delete the incoming credentials.
This option must be set to `true` if you use dynamic credentials.
</Tab>
<Tab heading="Terraform" group="terraform">
This page provides example configurations for a generic Terraform deployment.
Refer to the [Boundary Terraform provider documentation](https://registry.terraform.io/providers/hashicorp/boundary/latest/docs) to learn about the requirements for the following example attributes.
Support for MinIO storage providers leverages the [Boundary MinIO plugin](https://github.com/hashicorp/boundary-plugin-minio).
Apply the following Terraform policy:
```hcl
resource "boundary_storage_bucket" "minio_credentials_example" {
name = "My MinIO storage bucket"
description = "My first storage bucket"
scope_id = "o_1234567890"
plugin_name = "minio"
bucket_name = "mybucket1"
attributes_json = jsonencode({
"endpoint_url" = "minio_access_key_id_value",
"disable_credential_rotation" = true
})
secrets_json = jsonencode({
"access_key_id" = "minio_access_key_id_value",
"secret_access_key" = "minio_secret_access_key_value"
})
worker_filter = "\"minio-worker\" in \"/tags/type\""
}
output "storage_bucket_id" {
value = boundary_storage_bucket.minio_credentials_example.id
}
```
</Tab>
</Tabs>
</Tab>
<Tab heading="S3-compliant">
Complete the following steps to create a storage bucket in Boundary using an S3-compliant storage provider. Hitachi Content Platform is used as an example below.
<Note>
S3-compliant storage requires a service account and its associated access keys to set up a Boundary storage bucket. Refer to the [Configure S3-compliant storage](/boundary/docs/configuration/session-recording/storage-providers/configure-s3-compliant#s3-compliant-storage-provider-requirements) page to learn more.
</Note>
<Tabs>
<Tab heading="UI">
1. Log in to Boundary.
1. Click **Storage Buckets** in the navigation bar.
1. Click **New Storage Bucket**.
1. Complete the following fields to create the Boundary storage bucket:
- **Name**: (Optional) The name field is optional, but if you enter a name it must be unique.
- **Description**: (Optional) An optional description of the Boundary storage bucket for identification purposes.
- **Scope**: (Required) A storage bucket can belong to the Global scope or an Org scope.
It can only be associated with targets from the scope it belongs to.
- **Provider**: (Required) The external storage bucket provider.
For S3-compliant storage, select **MinIO**.
- **Endpoint URL**: (Required) The fully-qualified endpoint pointing to a storage provider's S3 API, such as `https://my-hitachi-instance.dev:9000`.
- **Bucket name**: (Required) Name of the S3-compliant storage bucket you want to associate with the Boundary storage bucket.
- **Region**: (Optional) The region to configure the storage bucket for.
- **Access key ID** (Required): The storage provider's service account's access key to use with this storage bucket.
- **Secret access key** (Required): The storage provider's service account's secret key to use with this storage bucket.
- **Worker filter**: (Required) A filter expression that indicates which Boundary workers have access to the storage. The filter must match an existing worker to create a Boundary storage bucket. This should be a boolean expression. To generate a worker filter in the correct format, toggle the **Show filter generator** switch. Refer to [filter examples](/boundary/docs/concepts/filtering/worker-tags#example-worker-filter-for-storage-buckets) to learn about worker tags and filters.
- **Disable credential rotation**: (Optional) Controls whether the plugin will rotate the incoming credentials and manage a new storage service account. If this attribute is set to false, or not provided, the plugin will rotate the incoming credentials, using them to create a new storage service account, then delete the incoming credentials.
Note that credential rotation is not supported for Hitachi Content Platform, and it may not function for other S3-compatible providers.
1. Click **Save**.
</Tab>
<Tab heading="CLI">
1. Log in to Boundary.
1. Use the following command to create a storage bucket in Boundary:
```shell-session
$ boundary storage-buckets create \
-bucket-name mystoragebucket \
-plugin-name minio \
-scope-id o_1234567890 \
-bucket-prefix="foo/bar/zoo" \
-worker-filter '"storage-worker" in "/tags/type"' \
-attr endpoint_url="https://my-hitachi-instance.dev:9000" \
-attr region="REGION" \
-attr disable_credential_rotation=true \
-secret access_key_id="KEY" \
-secret secret_access_key="SECRET"
```
Replace the values above with the following required secrets and any optional [attributes](/boundary/docs/concepts/domain-model/storage-buckets) you want to associate with the Boundary storage bucket:
- `bucket-name`: (Required) Name of the S3-compliant storage bucket you want to associate with the Boundary storage bucket.
- `plugin-name`: (Required) The name of the Boundary storage plugin.
Use the `minio` plugin for S3-compatible storage.
- `scope_id`: (Required) A storage bucket can belong to the Global scope or an Org scope.
- `worker-filter`: (Required) A filter expression that indicates which Boundary workers have access to the storage. The filter must match an existing worker in order to create a Boundary storage bucket. Refer to [filter examples](/boundary/docs/concepts/filtering/worker-tags#example-worker-filter-for-storage-buckets) to learn about worker tags and filters.
- `secret`: (Required) The storage provider's credentials to use.
- `access_key_id` (Required): The storage provider's service account's access key to use with this storage bucket.
- `secret_access_key` (Required): The storage provider's service account's secret key to use with this storage bucket.
- `attributes` or `-attr`: Attributes of the S3-compliant storage bucket.
- `endpoint_url` (Required): Fully-qualified endpoint pointing to an S3-compliant API. This example uses Hitachi, but you should substitute your storage provider's endpoint.
- `region`: (Optional) The region to configure the storage bucket for.
- `disable_credential_rotation`: (Optional) Controls whether the plugin will rotate the incoming credentials and manage a new storage service account. If this attribute is set to `false`, or not provided, the plugin will rotate the incoming credentials to create a new storage service account, then delete the incoming credentials.
Note that credential rotation is not supported for Hitachi Content Platform, and it may not function for other S3-compatible providers.
</Tab>
<Tab heading="Terraform" group="terraform">
This page provides example configurations for a generic Terraform deployment.
Refer to the [Boundary Terraform provider documentation](https://registry.terraform.io/providers/hashicorp/boundary/latest/docs) to learn about the requirements for the following example attributes.
Support for S3-compliant storage providers leverages the [Boundary MinIO plugin](https://github.com/hashicorp/boundary-plugin-minio).
Apply the following Terraform policy:
```hcl
resource "boundary_storage_bucket" "storage_credentials_example" {
name = "My storage bucket"
description = "My first storage bucket"
scope_id = "o_1234567890"
plugin_name = "minio"
bucket_name = "mybucket1"
attributes_json = jsonencode({
"endpoint_url" = "minio_access_key_id_value",
"disable_credential_rotation" = true
})
secrets_json = jsonencode({
"access_key_id" = "storage_access_key_id_value",
"secret_access_key" = "storage_secret_access_key_value"
})
worker_filter = "\"storage-worker\" in \"/tags/type\""
}
output "storage_bucket_id" {
value = boundary_storage_bucket.storage_credentials_example.id
}
```
</Tab>
</Tabs>
</Tab>
</Tabs>
Boundary creates the storage bucket resource and provides you with the bucket's ID.
## Next steps
After the storage bucket is created in Boundary, you can use the bucket's ID to [enable session recording on targets](/boundary/docs/configuration/session-recording/enable-session-recording).
## Resources
The following docs are relevant to configuring storage buckets:
- [Storage bucket attributes](/boundary/docs/concepts/domain-model/storage-buckets)
- [Worker filter examples](/boundary/docs/concepts/filtering/worker-tags#example-worker-filter-for-storage-buckets)
- [Boundary AWS plugin](https://github.com/hashicorp/boundary-plugin-aws)
- [Boundary MinIO plugin](https://github.com/hashicorp/boundary-plugin-minio)
@@ -1,116 +0,0 @@
---
layout: docs
page_title: Enable session recording on a target
description: >-
Enable session recording for targets so that user sessions are recorded for compliance and threat management.
---
# Enable session recording on a target
<EnterpriseAlert product="boundary">This feature requires <a href="https://www.hashicorp.com/products/boundary">HCP Boundary Plus or Boundary Enterprise</a></EnterpriseAlert>
You must enable session recording for any targets that you want to record sessions on.
When you [create a storage bucket](/boundary/docs/configuration/session-recording/create-storage-bucket), Boundary provides you with an ID.
You use the storage bucket's ID to associate a target with the storage bucket.
## Requirements
- One or more storage buckets to store the recordings.
- Session recording is only supported for SSH targets at this time.
- A KMS key with the purpose `bsr` must be added to the controller configuration.
The key is used for encrypting data and checking the integrity of recordings.
Refer to [Create the controller configuration](/boundary/docs/install-boundary/configure-controllers#create-the-controller-configuration) and [the `bsr` KMS key](/boundary/docs/concepts/security/data-encryption#the-bsr-kms-key) documentation for more information about configuring a KMS block.
- The targets must be configured with an ingress or egress worker filter that includes a worker with access to the storage bucket you created.
Refer to [SSH target attributes](/boundary/docs/concepts/domain-model/targets#ssh-target-attributes) for more information.
- You must enable injected application credentials on any target that you want to use for session recording.
Refer to [Configure targets with credential injection](/boundary/docs/configuration/credential-management/configure-credential-injection) for more information about injecting application credentials.
Complete the following steps to enable session recording on a target.
<Tabs>
<Tab heading="UI">
1. Log in to Boundary.
1. Click **Orgs** in the navigation pane.
1. Select the org that contains the target you want to enable for session recording.
1. Select the project that contains the target you want to enable for session recording.
1. Select **Targets** in the navigation pane.
1. Do one of the following:
- To create a new target, select **New Target**.
- To edit an existing target, select the target, and then select **Edit Form**.
1. Configure the target with any relevant [attributes](/boundary/docs/concepts/domain-model/targets).
The following setting is required for session recording:
- Select **SSH** for the **Type**.
1. Click **Save**.
1. Click **Enable recording**.
![Example of enabling session recording](/img/ui/enable-session-recording_light.png#light-theme-only)
![Example of enabling session recording](/img/ui/enable-session-recording_dark.png#dark-theme-only)
1. Enable the **Record sessions for this target** option.
1. Select the storage bucket where you want to store recordings from this target.
You can also [create a new storage bucket](/boundary/docs/configuration/session-recording/create-storage-bucket).
1. Click **Save**.
</Tab>
<Tab heading="CLI" group="cli">
1. Log in to Boundary.
1. Do one of the following:
- To enable an existing SSH target for session recording, run the following commmand:
```shell-session
$ boundary targets update ssh -scope-id p_1234567890 -id tssh_1234567890 -enable-session-recording true -storage-bucket-id sb_1234567890
```
Make sure to add the `-enable-session-recording true` flag to turn on session recording for the target.
Add the `-storage-bucket-id ID` for the storage bucket you want to associate with this target.
- To create a new target and enable it for session recording, run the following command:
```shell-session
$ boundary targets create ssh -scope-id p_1234567890 -default -port 22 -name test1 -address 99.12.345.67 -enable-session-recording true -storage-bucket-id sb_1234567890
```
Make sure to add the `-enable-session-recording true` flag to turn on session recording for the target.
Add the `-storage-bucket-id ID` for the storage bucket you want to associate with this target.
You can configure any other [target attributes](/boundary/docs/concepts/domain-model/targets).
You can now view the target from the **Targets** page in the Boundary console.
</Tab>
<Tab heading="Terraform" group="terraform">
Apply the following Terraform policy:
```hcl
resource "boundary_target" "address_foo" {
name = "address_foo"
description = "Foo target with an address"
type = "tcp"
default_port = "22"
scope_id = boundary_scope.project.id
address = "127.0.0.1"
# Add the next two lines to an existing target to enable session recording.
# Modify the value of storage_bucket_id as appropriate
enable_session_recording = true
storage_bucket_id = boundary_storage_bucket.aws_example.id
}
```
</Tab>
</Tabs>
The target is now enabled for session recording.
Any user session that connects to the target is automatically recorded.
## Next steps
After you have enabled session recording, you may want to [configure storage policies](/boundary/docs/configuration/session-recording/configure-storage-policy) to codify the lifecycle management of your session recordings.
@@ -1,60 +0,0 @@
---
layout: docs
page_title: Session recording overview
description: >-
Learn about using session recording to audit user sessions for compliance and threat management. Understand considerations for local and remote storage.
---
# Overview
<EnterpriseAlert product="boundary">This feature requires <a href="https://www.hashicorp.com/products/boundary">HCP Boundary Plus or Boundary Enterprise</a></EnterpriseAlert>
Boundary provides auditing capabilities using a feature called session recording.
In Boundary, a session represents a set of connections between a user and a host from a target. The session begins when an authorized user requests access to a target, and it ends when that access is terminated.
When you enable session recording on a target, a worker records any sessions that access that target. The worker stores the session recording on local disk during the recording phase, and then moves the recording to the external object store when the session is terminated.
Session recordings are stored in the [BSR (Boundary Session Recording)](/boundary/docs/concepts/auditing/#bsr-directory-structure) format. Any credentials needed to access the external object store are passed from the controller to the recording worker when the session is established.
You can view the recordings later with a session player that runs in a web browser.
## Storage considerations
The BSR captures all the data transmitted between a user and a target during a single session. As a result, the size of a BSR is dependent on user activity. At a minimum, a BSR for a session with one connection requires 8KB of space for its file for BSR keys, checksums, and metadata.
Determining how much storage you need to allocate on workers and the external storage provider for recordings depends on user activity, but the following two examples are provided to help with storage estimates:
- For one minute of simple shell activity, a BSR can be around 20KB in size. The storage requirements for 1,000 such sessions would be 20MB.
- Sending 50MB of data results in a BSR around 50.1MB in size. The storage requirements for 1,000 such sessions would be 50.1 GB.
When you estimate worker storage requirements, consider the number of concurrent sessions that will be recorded on that worker. Boundary writes the BSR to the worker's local storage while the session is active, and then moves it to the remote storage bucket when the session is closed.
When you estimate storage requirements for the external storage provider, consider your [storage policy](/boundary/docs/concepts/domain-model/storage-policy) and how long a BSR will be retained in the external storage bucket.
<Warning>
Boundary supports recorded session files up to 5 GB in size.
If a recorded session file is over 5 GB, the session details show the recording state as `Failed` and you may not be able to play back the session.
Be careful when you use Secure File Copy (SCP) to transfer large files during a recorded session because it can result in large recorded session files.
</Warning>
## Enable session recording
To enable session recording, you must:
1. [Configure workers for local storage](/boundary/docs/configuration/session-recording/configure-worker-storage)
1. Configure an external storage provider:
- [Amazon S3](/boundary/docs/configuration/session-recording/storage-providers/configure-s3)
- [MinIO](/boundary/docs/configuration/session-recording/storage-providers/configure-minio)
- [S3-compliant](/boundary/docs/configuration/session-recording/storage-providers/configure-s3-compliant)
1. [Create a storage bucket](/boundary/docs/configuration/session-recording/create-storage-bucket)
1. [Enable session recording on a target](/boundary/docs/configuration/session-recording/enable-session-recording)
## Configure recording retention policies
After enabling session recording, you can configure retention policies for recorded sessions:
1. [Configure storage policies](/boundary/docs/configuration/session-recording/configure-storage-policy)
1. [Update storage policies](/boundary/docs/configuration/session-recording/update-storage-policy)
@@ -1,115 +0,0 @@
---
layout: docs
page_title: Configure MinIO storage
description: >-
Configure MinIO as a storage provider for recorded sessions. Understand session recording and MinIO requirements. View an example configuration.
---
# Configure MinIO as a storage provider
<EnterpriseAlert product="boundary">This feature requires <a href="https://www.hashicorp.com/products/boundary">HCP Boundary or Boundary Enterprise</a></EnterpriseAlert>
This page describes how to configure MinIO as a storage provider for session recording with Boundary.
## Requirements
Before you can create a storage bucket in Boundary, you must ensure that your environment meets certain requirements.
Session recording requires specific configuration for both the external storage provider and the Boundary worker.
Refer to [Configure workers for session recording](/boundary/docs/configuration/session-recording/configure-worker-storage) to learn about configuring self-managed workers for session recording.
When you determine storage requirements for the external bucket, you should consider:
- [BSR storage considerations](/boundary/docs/configuration/session-recording#storage-considerations)
- [Storage bucket retention policies](/boundary/docs/configuration/session-recording/configure-storage-policy)
### MinIO requirements
- A MinIO storage bucket
You must associate the Boundary storage bucket with a MinIO storage bucket. A Boundary MinIO storage bucket contains the bucket name, endpoint URL, optional region, optional prefix, and the service account credentials needed to access the bucket. To enable credential rotation, you cannot add a Boundary storage bucket without a MinIO service account. You can disable credential rotation when you create the Boundary storage bucket.
At the time of the 0.18.0 release, the latest tested and supported MinIO version is `RELEASE.2024-10-02T17-50-4Z`.
Newer versions may work as well, but they have not been tested.
<Note>
At this time, the NetBSD operating system is not supported for the MinIO storage bucket.
</Note>
- A MinIO service account and access keys
You must provide service account access keys when you configure a Boundary storage bucket later on.
Refer to the [MinIO Access Keys](https://min.io/docs/minio/kubernetes/upstream/administration/console/security-and-access.html#access-keys) documentation page to learn how to set up a MinIO service account.
- A MinIO storage bucket must be configured with R/W access. If you use a
restricted IAM user policy, the following policy actions must be allowed at a minimum.
```json
{
"Version": "2012-10-17",
"Statement": [
{
"Action": [
"s3:PutObject",
"s3:GetObject",
"s3:GetObjectAttributes",
"s3:DeleteObject"
],
"Effect": "Allow",
"Resource": "arn:aws:s3:::test-session-recording-bucket/*"
},
{
"Action": "s3:ListBucket",
"Effect": "Allow",
"Resource": "arn:aws:s3:::test-session-recording-bucket"
}
]
}
```
- HashiCorp recommends that you enable credential rotation. To enable credential rotation, use the following service account policy:
```json
{
"Version": "2012-10-17",
"Statement": [
{
"Action": [
"s3:PutObject",
"s3:GetObject",
"s3:GetObjectAttributes",
"s3:DeleteObject"
],
"Effect": "Allow",
"Resource": "arn:aws:s3:::test-session-recording-bucket/*"
},
{
"Action": "s3:ListBucket",
"Effect": "Allow",
"Resource": "arn:aws:s3:::test-session-recording-bucket"
},
{
"Action": [
"admin:CreateServiceAccount",
"admin:RemoveServiceAccount"
],
"Effect": "Allow"
}
]
}
```
## Resources
The following docs MinIO docs are relevant for configuring storage buckets and service accounts:
- Refer to the [MinIO Policy Action Keys](https://min.io/docs/minio/linux/administration/identity-access-management/policy-based-access-control.html#mc-admin-policy-action-keys) documentation to learn more about restricting IAM user policies.
- Refer to the [MinIO Object Encryption with KES](https://min.io/docs/minio/linux/operations/server-side-encryption/configure-minio-kes.html#minio-sse-vault) documentation to learn more about KMS and data encryption with vault key management.
## Next steps
After you configure the external storage provider, you can [create the storage bucket](/boundary/docs/configuration/session-recording/create-storage-bucket) in Boundary.
@@ -1,114 +0,0 @@
---
layout: docs
page_title: Configure S3-compliant storage
description: >-
Configure an S3-compliant storage provider for recorded sessions. Understand session recording and storage provider requirements. View an example configuration.
---
# Configure an S3-compliant storage provider
<EnterpriseAlert product="boundary">This feature requires <a href="https://www.hashicorp.com/products/boundary">HCP Boundary or Boundary Enterprise</a></EnterpriseAlert>
The [MinIO plugin](https://github.com/hashicorp/boundary-plugin-minio/) lets you configure S3-compliant storage providers for session recording.
<a name="providers"></a>
HashiCorp has tested and confirmed that you can configure the following S3-compliant storage products for session recording using the MinIO plugin:
- [Hitachi Content Platform](https://trycontent.hitachivantara.com)
At the time of the 0.18.0 release, the latest tested and supported Hitachi Content Platform version is `2.6.0.0`.
Newer versions may work as well, but they have not been tested.
- [Backblaze B2](https://www.backblaze.com/cloud-storage)
You can also configure other providers' S3-compliant storage products for session recording storage.
We will update the list of providers as we test them.
The process for [configuring the Hitachi Content Platform](#hitachi-content-platform-configuration) is included below as an example.
Configuring other S3-compliant storage products for use with session recording should be a similar process.
## Requirements
Before you can create a storage bucket in Boundary, you must ensure that your environment meets certain requirements.
Session recording requires specific configuration for both the external storage provider and the Boundary worker.
Refer to [Configure workers for session recording](/boundary/docs/configuration/session-recording/configure-worker-storage) to learn about configuring self-managed workers for session recording.
When you determine storage requirements for the external bucket, you should consider:
- [BSR storage considerations](/boundary/docs/configuration/session-recording#storage-considerations)
- [Storage bucket retention policies](/boundary/docs/configuration/session-recording/configure-storage-policy)
### S3-compliant storage provider requirements
- A storage bucket
You must associate the Boundary storage bucket with a third-party storage bucket. A third-party storage bucket contains the bucket name, endpoint URL, optional region, optional prefix, and the service account credentials needed to access the bucket.
- A service account and access keys for the storage provider
You must provide service account access keys when you configure a Boundary storage bucket later on.
Refer to your storage provider's documentation to learn how to set up a service account.
- The storage bucket must be configured with R/W access. If you use a
restricted IAM user policy, you must allow the following policy actions at a minimum.
```json
{
"Version": "2012-10-17",
"Statement": [
{
"Action": [
"s3:PutObject",
"s3:GetObject",
"s3:GetObjectAttributes",
"s3:DeleteObject"
],
"Effect": "Allow",
"Resource": "arn:aws:s3:::test-session-recording-bucket/*"
},
{
"Action": "s3:ListBucket",
"Effect": "Allow",
"Resource": "arn:aws:s3:::test-session-recording-bucket"
}
]
}
```
### Hitachi Content Platform configuration
HashiCorp has tested and confirmed that you can configure the Hitachi Content Platform for external session recording storage using the MinIO plugin.
It is included as an example in this topic.
You should be able to configure other S3-compliant storage providers to work for session recording storage as well, but we have only tested a [limited number of providers](#providers).
You must have an account with Hitachi Content Platform to create storage buckets.
You can sign up for an account at the following URL:
[https://trycontent.hitachivantara.com](https://trycontent.hitachivantara.com)
When you sign up for an account, Hitachi sends you the details you need to connect to the instance including the endpoint, S3 access key ID, and S3 secret key.
Log in to Hitachi's S3 console to create a storage bucket, and make a note of the bucket's name.
In Boundary, set the following environment variables using your Hitachi credentials and the name of the bucket:
```
export BUCKET_NAME=<YOUR_HITACHI_BUCKET_NAME>
export STORAGE_ACCESS_KEY_ID=<YOUR_HITACHI_ACCESS_KEY_ID>
export STORAGE_SECRET_ACCESS_KEY=<YOUR_HITACHI_SECRET_KEY>
```
<Note>
Credential rotation is not supported for Hitachi Content Platform.
</Note>
## Resources
Refer to your S3-compliant storage provider's documentation for more information about configuring storage buckets and service accounts.
## Next steps
After you configure the external storage provider, you can [create the storage bucket](/boundary/docs/configuration/session-recording/create-storage-bucket) in Boundary.
@@ -1,131 +0,0 @@
---
layout: docs
page_title: Configure Amazon S3 storage
description: >-
Configure Amazon S3 as a storage provider for recorded sessions. Understand session recording and AWS requirements. View an example configuration.
---
# Configure Amazon S3 as a storage provider
<EnterpriseAlert product="boundary">This feature requires <a href="https://www.hashicorp.com/products/boundary">HCP Boundary or Boundary Enterprise</a></EnterpriseAlert>
This page describes how to configure Amazon S3 as a storage provider for session recording with Boundary.
## Requirements
Before you can create a storage bucket in Boundary, you must ensure that your environment meets certain requirements.
Session recording requires specific configuration for both the external storage provider and the Boundary worker.
Refer to [Configure workers for session recording](/boundary/docs/configuration/session-recording/configure-worker-storage) to learn about configuring self-managed workers for session recording.
When you determine storage requirements for the external bucket, you should consider:
- [BSR storage considerations](/boundary/docs/configuration/session-recording#storage-considerations)
- [Storage bucket retention policies](/boundary/docs/configuration/session-recording/configure-storage-policy)
### AWS requirements
- An Amazon S3 storage bucket
You must associate the Boundary storage bucket with an Amazon S3 storage bucket. A Boundary Amazon S3 storage bucket contains the bucket name, region, and optional prefix, as well as any credentials needed to access the bucket.
The Amazon S3 storage bucket can use static or dynamic credentials.
You can configure static credentials using an access key and secret key or dynamic credentials using the AWS [`AssumeRole` API](https://docs.aws.amazon.com/STS/latest/APIReference/API_AssumeRole).
- An AWS IAM role policy with the following statement:
```json
{
"Version": "2012-10-17",
"Statement": [
{
"Action": [
"s3:PutObject",
"s3:GetObject",
"s3:GetObjectAttributes",
"s3:DeleteObject",
"s3:ListBucket"
],
"Effect": "Allow",
"Resource": "arn:aws:s3:::session_recording_storage*",
"Resource": "arn:aws:s3:::session_recording_storage/foo/bar/zoo/*"
},
{
"Action": [
"iam:DeleteAccessKey",
"iam:GetUser",
"iam:CreateAccessKey"
],
"Effect": "Allow",
"Resource": "arn:aws:iam::123456789012:user/JohnDoe"
}
]
}
```
- If you apply KMS encryption to the storage bucket, you must add these additional permissions to the role policy for the storage bucket's IAM user:
```json
{
"Action": [
"kms:Decrypt",
"kms:GenerateDataKey",
"kms:DescribeKey"
],
"Effect": "Allow",
"Resource": "arn:aws:kms:us-east-1:1234567890:key/uuid"
}
```
The following is an example working policy with KMS encryption configured on the S3 bucket:
```json
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "S3Permissions",
"Effect": "Allow",
"Action": [
"s3:PutObject",
"s3:GetObject",
"s3:GetObjectAttributes",
"s3:DeleteObject",
"s3:ListBucket"
],
"Resource": [
"arn:aws:s3:::test-session-recording-bucket/*"
]
},
{
"Sid": "UserPermissions",
"Effect": "Allow",
"Action": [
"iam:DeleteAccessKey",
"iam:GetUser",
"iam:CreateAccessKey"
],
"Resource": [
"arn:aws:iam::1234567890:user/test-boundary"
]
},
{
"Sid": "KMSPermissions",
"Effect": "Allow",
"Action": [
"kms:Decrypt",
"kms:GenerateDataKey",
"kms:DescribeKey"
],
"Resource": [
"arn:aws:kms:us-east-2:1234567890:key 4b887395-c376-4936-8f37-80c592ea582c"
]
}
]
}
```
## Next steps
After you configure the external storage provider, you can [create the storage bucket](/boundary/docs/configuration/session-recording/create-storage-bucket) in Boundary.
@@ -1,350 +0,0 @@
---
layout: docs
page_title: Update storage bucket policies
description: >-
Update storage bucket policies to manage the lifecycles of session recordings. Understand how changing a policy affects existing and new recorded sessions.
---
# Update storage bucket policies
<EnterpriseAlert product="boundary">This feature requires <a href="https://www.hashicorp.com/products/boundary">HCP Boundary Plus or Boundary Enterprise</a></EnterpriseAlert>
A [storage policy][] codifies [storage bucket][] lifecycle management for [session recordings][].
A storage policy exists in either the global scope or an org scope. Storage policies that are created in the global scope can be associated with any org scope.
When you update a storage policy, new session recordings within a scope where the policy is applied will conform to the updated policy. Existing recordings will maintain the previous policy unless the new policy is retroactively applied.
This page describes the process for applying updated storage policies to existing recordings within a scope.
For more information about setting up storage bucket policies, refer to the [configure storage bucket policies](/boundary/docs/configuration/session-recording/configure-storage-policy) page.
## Requirements
This page continues the workflows outlined in the [configure storage bucket policies](/boundary/docs/configuration/session-recording/configure-storage-policy) page. The requirements outlined in that page are prerequisites for the workflow defined below.
To apply an updated storage policy to existing session recordings, you first need:
1. An external storage provider configured to store session recordings.
1. A Boundary worker configured for local storage.
1. A Boundary storage bucket with a defined retention and/or deletion policy.
1. A scope with the storage policy attached.
1. A set of session recordings made when the storage policy was attached.
The policies mentioned here demonstrate how to apply an updated storage policy to an existing set of [session recordings][].
## Storage policy changes
A storage policy defines how long the recording within a scope should retain its session recordings.
Over time, you may update storage policies to reflect new organizational requirements, compliance changes, or cost management strategies. While updated policies automatically apply to new session recordings within the scopes associated with that policy, existing recordings maintain the previous policies unless you apply the new policy directly to those recordings.
In the [configure storage bucket policies](/boundary/docs/configuration/session-recording/configure-storage-policy) page, the following policy was created to implement compliance with SOC-2 retention requirement of 7 years:
- Name: `soc2-policy`
- Description: `SOC 2 compliant storage policy for session recordings`
- Retention policy: `2557` days, Overridable: `false`
- Deletion policy: `2657` days, Overridable: `true`
## Update a storage policy
In the following example, the `soc2-policy` should be updated to the following:
- Name: `soc2-policy`
- Description: `SOC 2 compliant storage policy for session recordings, V2`
- Retention policy: `2557` days, Overridable: `false`
- Deletion policy: `2757` days, Overridable: `false`
The updated policy requires the deletion of recordings after `2757` days, 200 days after the standard SOC 2 retention requirements. It also changes Overridable to `false`, preventing lower scopes from overwriting the Deletion policy.
The following is an example of updating the `soc2-policy` policy.
<Tabs>
<Tab heading="UI" group="ui">
1. Log in to Boundary.
1. Select **Storage Policies** in the navigation panel and select the `global` scope.
1. Click on **`soc2-policy`**.
1. Click the **Edit Form** button and update the following fields:
- **Description**: `SOC 2 compliant storage policy for session recordings, V2`
- **Retention Policy**: `SOC 2 (7 years)`
- **Deletion Policy**: `Custom`
**Delete after**: `2757` days
Toggle the switch beside **Allow orgs to override** to the off position.
1. Click **Save**.
</Tab>
<Tab heading="CLI" group="cli">
1. Log in to Boundary.
1. List the available storage policies and copy the `soc2-policy` ID.
<CodeBlockConfig highlight="1,3">
```shell-session
$ boundary policies list
Policy information:
ID: pst_WZ3SQSSYJY
Version: 1
Type: storage
Name: soc2-policy
Description: SOC 2 compliant storage policy for session recordings
Authorized Actions:
read
update
delete
no-op
```
</CodeBlockConfig>
1. Use the following command to update the `soc2-policy` storage policy to reflect the new deletion requirements:
```shell-session
$ boundary policies update storage \
-id pst_WZ3SQSSYJY \
-description 'SOC 2 compliant storage policy for session recordings, V2' \
-scope-id global \
-retain-for-days 2557 \
-retain-for-overridable false \
-delete-after-days 2757 \
-delete-after-overridable false
```
</Tab>
<Tab heading="Terraform" group="terraform">
Due to the declarative nature of Terraform, you update policies by modifying your existing Terraform configuration. To perform the requested changes, update your existing block of code as shown below, and then execute `terraform apply`.
```hcl
resource "boundary_policy_storage" "example" {
name = "soc2-policy"
v2"
scope_id = data.boundary_scope.org.id
retain_for_days = 2557
retain_for_overridable = false
delete_after_days = 2757
delete_after_overridable = false
}
```
</Tab>
<Tab heading="API call using cURL" group="api">
The following API call is an example of updating a storage policy in Boundary:
```shell-session
$ curl --header "Content-Type: application/json" \
--header "Authorization: Bearer $(boundary config get-token)" \
--request PATCH \
--data '{"attributes":{"retain_for":{"days":2557,"overridable":false},"delete_after":{"days":2757,"overridable":false}},"scope_id":"global","description":"SOC 2 compliant storage policy for session recordings, V2","type":"storage","version":"2"}' \
$BOUNDARY_ADDR/v1/policies/pst_WZ3SQSSYJY | jq
```
<Note>
This example uses [jq](https://stedolan.github.io/jq/download/) to process the JSON output for readability.
</Note>
**Example output:**
<CodeBlockConfig hideClipboard>
```plaintext
{
"id": "pst_WZ3SQSSYJY",
"scope_id": "global",
"scope": {
"id": "global",
"type": "global",
"name": "global",
"description": "Global Scope"
},
"name": "soc2-policy",
"description": "SOC 2 compliant storage policy for session recordings, V2",
"created_time": "2024-01-25T22:05:52.112677Z",
"updated_time": "2024-01-30T22:44:08.890715Z",
"type": "storage",
"version": 2,
"attributes": {
"delete_after": {
"days": 2757,
"overridable": false
},
"retain_for": {
"days": 2557,
"overridable": false
}
},
"authorized_actions": [
"no-op",
"read",
"update",
"delete"
]
}
```
</CodeBlockConfig>
</Tab>
</Tabs>
This policy was applied to the `prod-databases` org in the [configure storage bucket policies](/boundary/docs/configuration/session-recording/configure-storage-policy) page.
New recordings within the `prod-databases` org will automatically have the updated version of the `soc2-policy` applied.
### Reapply a storage policy
Many organizations compliance standards will require that previous versions of storage policies remain applied to existing recordings.
<Note>
During the initial migration to a Boundary version that includes storage policies, all existing session recordings will have a `retain_for` attribute of `-1`, which retains the recording forever.
</Note>
In the event that an updated policy should be retroactively applied to existing session recordings, you must reapply the storage policy.
<Tabs>
<Tab heading="UI" group="ui">
1. Log in to Boundary.
1. Select **Session Recordings** in the navigation panel in the `global` scope.
1. Click on **View** for a session recording that should have the storage policy re-applied.
1. Click the **Manage** dropdown and select **Re-apply storage policy**.
1. Verify the *Delete after* field has been updated under the recording's **Session details**.
</Tab>
<Tab heading="CLI" group="cli">
1. Log in to Boundary.
1. Find the ID of the session recording that should have the storage policy re-applied.
<CodeBlockConfig highlight="1,3">
```shell-session
$ boundary session-recordings list
Session Recording information:
ID: sr_nt5dFeBYdh
Storage Bucket ID: sb_DC8SPb9uc2
Created Time: Mon, 29 Jan 2024 23:25:31 MST
Updated Time: Tue, 30 Jan 2024 16:14:13 MST
Start Time: Mon, 29 Jan 2024 23:25:32 MST
End Time: Mon, 29 Jan 2024 23:25:53 MST
Type: ssh
State: available
Retain Until: Wed, 29 Jan 2031 23:25:53 MST
Delete After: Mon, 18 Aug 2031 00:25:53 MDT
Authorized Actions:
no-op
read
download
delete
reapply-storage-policy
```
</CodeBlockConfig>
1. Re-apply the storage policy to the session recording by providing its ID:
<CodeBlockConfig highlight="1,6">
```shell-session
$ boundary session-recordings reapply-storage-policy -id sr_nt5dFeBYdh
Session Recording information:
Bytes Down: 710
Bytes Up: 36
Created Time: Mon, 29 Jan 2024 23:25:31 MST
Delete After: Mon, 18 Aug 2031 00:25:53 MDT
Duration (Seconds): 21.01881
Endpoint: ssh://54.159.144.135:22
ID: sr_nt5dFeBYdh
Retain Until: Wed, 29 Jan 2031 23:25:53 MST
Scope ID: global
Start Time: Mon, 29 Jan 2024 23:25:32 MST
State: available
Storage Bucket ID: sb_DC8SPb9uc2
Type: ssh
Updated Time: Mon, 29 Jan 2024 23:25:53 MST
...
... More Output ...
...
```
</CodeBlockConfig>
Verify that the `Delete After` attribute reflects the updated storage policy.
</Tab>
<Tab heading="Terraform" group="terraform">
Once the policy changes have been applied with Terraform, you can reapply the policy as needed by following the CLI instructions in this section.
</Tab>
<Tab heading="API call using cURL" group="api">
The following API call is an example of re-applying a storage policy to a session recording by providing the recording's ID:
```shell-session
$ curl --header "Content-Type: application/json" \
--header "Authorization: Bearer $(boundary config get-token)" \
--request POST \
$BOUNDARY_ADDR/v1/session-recordings/sr_nt5dFeBYdh:reapply-storage-policy | jq
```
**Example output:**
<CodeBlockConfig hideClipboard highlight="2,25-26">
```plaintext
{
"id": "sr_nt5dFeBYdh",
"scope": {
"id": "global",
"type": "global",
"name": "global",
"description": "Global Scope"
},
"storage_bucket_id": "sb_DC8SPb9uc2",
"bytes_up": "36",
"bytes_down": "710",
"created_time": "2024-01-30T06:25:31.873628Z",
"updated_time": "2024-01-30T23:14:13.881110Z",
"start_time": "2024-01-30T06:25:32.412373Z",
"end_time": "2024-01-30T06:25:53.431183Z",
"duration": "21.018810s",
"type": "ssh",
"state": "available",
"endpoint": "ssh://xx.xxx.xxx.xxx:22",
...
... More Output ...
...
"retain_until": "2031-01-30T06:25:53.431183Z",
"delete_after": "2031-08-18T06:25:53.431183Z"
}
```
</CodeBlockConfig>
Verify that the `delete_after` attribute reflects the updated storage policy.
</Tab>
</Tabs>
### Detached or deleted storage policies
If a scope's storage policy is detached or deleted, new session recordings within that scope will automatically be retained forever, unless there is an overriding policy.
Existing session recordings will maintain their existing storage policy attributes until a new policy is re-applied, including any overriding policy from another scope.
[storage bucket]: /boundary/docs/concepts/domain-model/storage-buckets
[storage policy]: /boundary/docs/concepts/domain-model/storage-policy
[session recordings]: /boundary/docs/concepts/domain-model/session-recordings
@@ -1,30 +0,0 @@
---
layout: docs
page_title: Overview
description: >-
Learn how to connect to a target configured with an alias.
---
After you [Create a target alias](/boundary/docs/configuration/target-aliases/create-target-alias), you can refer to the alias when you establish sessions.
With aliases, you don't have to specify the target ID, target name, or scope when you connect with Boundary. Target aliases are also required to use [transparent sessions](/boundary/docs/configuration/target-aliases/transparent-sessions).
# Connect to a target using an alias
You can substitute an alias whenever you could use the `-id` flag or `-target` flag in the CLI.
For example, you can use the following command to connect to an SSH target with the ID `ttcp_1234567890`:
```shell-session
$ boundary connect ssh -target -id ttcp_1234567890
```
If you configured an alias named `example.alias.boundary` for the target, you can now use the alias to connect to the target:
```shell-session
$ boundary connect ssh example.alias.boundary
```
Aliases are globally unique, so you don't need to specify the scope to connect to the target.
After you verify that you can connect to the target using an alias, you can try to connect to the target using [transparent sessions](/boundary/docs/configuration/target-aliases/transparent-sessions). <sup>HCP/ENT</sup>
@@ -1,695 +0,0 @@
---
layout: docs
page_title: Create target aliases
description: >-
Learn how to create a target alias for an existing target, or assign one during target creation.
---
# Create target aliases
An alias is a globally unique, DNS-like string that is associated with a destination resource. You can establish a session to a target by referencing its alias, instead of having to provide a target ID or target name and scope ID.
For more information about aliases, including naming conventions and best practices, refer to [Aliases](/boundary/docs/concepts/aliases).
You can create aliases and associate them with targets using the following methods:
- [Create an alias for an existing target](#create-an-alias-for-an-existing-target)
- [Create an alias during target creation](#create-an-alias-during-target-creation)
- [Associate an existing alias with a target](#associate-an-existing-alias-with-a-target)
- [Create multiple target aliases: An example](#create-multiple-aliases-for-a-single-target)
## Create an alias for an existing target
You can create a new alias and associate it with an existing target at the same time.
When you create the target alias, you can choose from the following methods:
- Create the alias without adding a target
- Create the alias for one or more targets
- Create the alias with an optional host ID
Complete the following steps to create a new alias and associate it with a target:
<Tabs>
<Tab heading="UI" group="ui">
1. Log in to Boundary.
1. Select **Aliases** in the navigation pane.
1. Click **New Alias**.
1. Complete the following fields:
- **Name**: (Optional) Enter an optional name for the alias to use for identification purposes.
- **Description**: (Optional) Enter an optional description for the alias to use for identification purposes.
- **Type**: Select **Target**.
At this time, targets are the only Boundary resources that supports aliasing.
- **Alias Value**: Enter the string that you want to use as the alias to represent the target.
An alias's value can be a hostname or a DNS-like string.
- **Target ID**: (Optional) Specify any targets you want to associate with the alias.
- **Host ID**: (Optional) Enter an optional host ID, if you would like to specify that the alias always uses the same host when you use it to connect to a target.
1. Click **Save**.
</Tab>
<Tab heading="CLI" group="cli">
1. Log in to Boundary.
1. Use the following command to create an alias:
```shell-session
$ boundary aliases create target \
-description 'This is an example alias for target tcp_1234567890' \
-destination-id tcp_1234567890 \
-name Example Boundary alias \
-scope-id global \
-value example.alias.boundary \
-authorize-session-host-id hst_1234567890
```
You can use any of the following [attributes](/boundary/docs/concepts/domain-model/aliases) when you create an alias:
- `-description=<string>` - Specifies the optional description you want to use for identification purposes.
- `-destination-id=<string>` - Specifies the ID of the target that the alias references.
- `-name=<string>` - Specifies the optional name you want to use to describe the alias for identification purposes.
- `-scope-id=<string>` - Scope in which to create the alias. The default is `global`.
You can also specify the scope using the BOUNDARY_SCOPE_ID environment variable.
At this time, aliases are only supported for the global scope.
- `-value=<string>` - Specifies the string that you want to use as the alias to represent the target.
The alias `value` can be a hostname or a DNS-like string.
- `-authorize-session-host-id=<string>` - Optionally indicates the host ID to use when you use the alias to authorize a session.
</Tab>
<Tab heading="Terraform" group="terraform">
Apply the following Terraform policy to create target alias `example.bar.foo.boundary` for an existing target `foo_target` and host `bar_host`:
```hcl
resource "boundary_alias_target" "example_alias_target" {
name = "example_alias_target"
description = "Example alias to target foo using host boundary_host_static.bar_host"
scope_id = "global"
value = "example.bar.foo.boundary"
destination_id = boundary_target.foo_target.id
authorize_session_host_id = boundary_host_static.bar_host.id
}
```
</Tab>
</Tabs>
## Create an alias during target creation
You can create a new target and new alias at the same time and associate the two.
Complete the following steps to create a new target and new alias at the same time:
<Tabs>
<Tab heading="UI" group="ui">
1. Log in to Boundary.
1. Select **Targets** in the navigation pane.
1. Click **New Target**.
1. Complete the following fields:
- **Name**: Enter the target name for identification purposes.
- **Description**: (Optional) Enter an optional description for identification purposes.
- **Type**: Select the target type.
You can create SSH or TCP targets.
- **Target Address**: (Optional) Enter a valid IP address or DNS name.
Alternatively, you can configure host catalogs and host sets.
- **Default Port**: (Optional) Enter an optional default port for the target to use for connections.
- **Default Client Port**: (Optional) Enter an optional local proxy port on which to listen when a session is started on a client.
- **Maximum Duration**: (Required) Enter a maximum duration for sessions on this target, in seconds.
If you do not enter a value, Boundary uses the default of 8 hours (28,800 seconds).
- **Maximum Connection**: (Optional) Enter the maximum number of connections allowed per session on this target.
For unlimited connections, enter `-1`.
- **Workers**: (Optional) Select whether you want the worker to function as an ingress and/or egress worker.
- **Aliases**: (Optional) Enter the value fpr any aliases you want to associate with this target, and then click **Add**.
An alias's value can be a hostname or a DNS-like string.
You can associate multiple aliases with a target.
1. Click **Save**.
</Tab>
<Tab heading="CLI" group="cli">
1. Log in to Boundary.
1. Use the following command to create a target:
```shell-session
$ boundary targets create ssh \
-description 'This is an example ssh target' \
-name Example Boundary SSH target \
-scope-id global \
-with-alias-authorize-session-host-id hst_1234567890 \
-with-alias-scope-id global \
-with-alias-value example.alias.boundary
```
You can use any of the following [attributes](/boundary/docs/concepts/domain-model/targets) when you create a target:
- `description` - (optional)
An optional description that you can use for identification purposes.
- `name` - (required)
The `name` must be unique within the target's project.
- `scope-id` - (required)
The scope in which to create the target.
The default is `global`.
You can also specify the scope using the BOUNDARY_SCOPE_ID environment variable.
- `-address=<string>` - An optional valid network address for the target to connect to.
You cannot use an address alongside host sources.
- `-default-client-port=<string>` - The default client port on the target.
- `-default-port=<string>` - The default port on the target.
If you do not specify a default port, Boundary uses port 22.
- `-egress-worker-filter=<string>` - A Boolean expression that filters which egress workers can process sessions for the target.
- `-enable-session-recording=<string>` - A Boolean expression you can use to enable session recording for the target.
- `-ingress-worker-filter=<string>` - A Boolean expression that filters which ingress workers can process sessions for the target.
- `-session-connection-limit=<string>` - The maximum number of connections allowed for a session.
A value of `-1` means the connections are unlimited.
- `-session-max-seconds=<string>` - The maximum lifetime of the session, including all connections.
You can specify an integer number of seconds or a duration string.
- `-storage-bucket-id=<string>` - The public ID of the storage bucket to associate with the target.
- `-with-alias-authorize-session-host-id=<string>` - The host ID that an alias uses to authorize sessions for the target.
- `-with-aliasscope-id=<string>` - The scope ID that you want to create the target and alias in.
The default is `global`.
At this time, aliases are only supported for the global scope.
- `-with-alias-value=<string>` - The value of the alias that you want to use to represent the target.
Use this parameter to create the alias and target, and associate them with each other, at the same time.
Note that you can create SSH or TCP [target types](/boundary/docs/concepts/domain-model/targets#target-types).
The example command in this section creates an SSH target.
</Tab>
<Tab heading="Terraform" group="terraform">
Apply the following Terraform policy to create the following:
- A static host catalog `test_catalog` in `boundary_scope.project` (not shown) containing static host set `test_set`.
- A host `foo` belonging to `test_set`.
- A host `bar` belonging to `test_set`.
- A target `foo_target` using `foo_set` as its host source.
- A target alias `example.bar.foo.boundary` for `foo_target` that always uses `bar_host` to connect.
```hcl
resource "boundary_host_catalog_static" "foo_catalog" {
name = "foo_catalog"
description = "test catalog"
scope_id = boundary_scope.project.id
}
resource "boundary_host_static" "foo_host" {
name = "foo_host"
host_catalog_id = boundary_host_catalog_static.foo.id
address = "10.0.0.1"
}
resource "boundary_host_static" "bar_host" {
name = "bar_host"
host_catalog_id = boundary_host_catalog_static.foo.id
address = "127.0.0.1"
}
resource "boundary_host_set_static" "foo_set" {
name = "foo_set"
host_catalog_id = boundary_host_catalog_static.foo_catalog.id
host_ids = [
boundary_host_static.foo_host.id,
boundary_host_static.bar_host.id,
]
}
resource "boundary_target" "foo_target" {
name = "foo"
description = "Foo target"
type = "tcp"
default_port = "22"
scope_id = boundary_scope.project.id
host_source_ids = [
boundary_host_set_static.foo_set.id,
]
}
resource "boundary_alias_target" "example_alias_target" {
name = "example_alias_target"
description = "Example alias to target foo using host boundary_host_static.bar_host"
scope_id = "global"
value = "example.bar.foo.boundary"
destination_id = boundary_target.foo_target.id
authorize_session_host_id = boundary_host_static.bar_host.id
}
```
</Tab>
</Tabs>
## Associate an existing alias with a target
If you [created an alias](#create-an-alias-for-an-existing-target) without associating it with a target, you can update it with an existing target at a later time. Complete the following steps to add an alias to a target:
<Tabs>
<Tab heading="UI" group="ui">
1. Log in to Boundary.
1. Select **Targets** in the navigation pane.
1. Select the target you want to add an alias to.
1. Under the **Aliases** heading in the right sidebar, click **Add an alias**.
1. Complete the following fields:
- **Name**: (Optional) Enter an optional name for the alias to use for identification purposes.
- **Description**: (Optional) Enter an optional description for the alias to use for identification purposes.
- **Type**: Select **Target**.
At this time, targets are the only Boundary resources that supports aliasing.
- **Alias Value**: Enter the alias value you want to use in commands to represent the target.
An alias's value can be a hostname or a DNS-like string.
- **Target ID**: This field contains the ID of the target you selected to add an alias to.
It is read only.
- **Host ID**: (Optional) Enter an optional host ID, if you would like to specify that the alias always uses the same host when you use it to connect to a target.
1. Click **Save**.
</Tab>
<Tab heading="CLI" group="cli">
1. Log in to Boundary.
1. Use the following command to create an alias:
```shell-session
$ boundary aliases update target \
-destination-id tcp_1234567890 \
-id alt_1234567890 \
-authorize-session-host-id hst_1234567890
```
You can use any of the following [attributes](/boundary/docs/concepts/domain-model/aliases) when you update an alias:
- `-description=<string>` - Specifies the optional description you want to use for identification purposes.
- `-destination-id=<string>` - Specifies the ID of the target that the alias references.
- `id=<string>` - Specifies the ID of the alias you want to update.
- `-name=<string>` - Specifies the optional name you want to use to describe the alias for identification purposes.
- `-scope-id=<string>` - Scope in which to create the alias. The default is `global`.
You can also specify the scope using the BOUNDARY_SCOPE_ID environment variable.
At this time, aliases are only supported for the global scope.
- `-value=<string>` - Specifies the string that you want to use as the alias to represent the target.
The alias `value` must comply with DNS naming rules.
- `-authorize-session-host-id=<string>` - Optionally indicates the host ID to use when you use the alias to authorize a session.
</Tab>
<Tab heading="Terraform" group="terraform">
If you created a `boundary_alias_target` resource without setting a `destination_id` attribute, update the `destination_id` and reapply the following policy:
```hcl
resource "boundary_alias_target" "example_alias_target" {
name = "example_alias_target"
description = "Example alias to target foo using host boundary_host_static.bar_host"
scope_id = "global"
value = "example.bar.foo.boundary"
destination_id = boundary_target.foo_target.id
authorize_session_host_id = boundary_host_static.bar_host.id
}
```
</Tab>
</Tabs>
## Create multiple aliases for a single target
Target aliases point directly to the target they are associated with. You can assign targets a host set or a direct target address.
[Host sets](/boundary/docs/concepts/domain-model/host-sets) are sets of functionally equivalent hosts, and are commonly used for deployments at scale. When Boundary authorizes a session, a target assigned a host set will select a host from the host set at random to use for all connections for the session.
You assign [direct target addresses](/boundary/docs/concepts/domain-model/targets#address) directly to the target. They refer to a specific network resource, like an IP address. Boundary only connects to the direct target address when it establishes a connection to the associated target.
When you create a target alias, you can also assign it to a specific host. Assigning an alias to a specific host is useful if you want to avoid creating multiple targets for specific hosts using direct target addresses.
For example, you could create two aliases for the same target that has been assigned a host set. One alias could refer to the target itself, and would allow Boundary to randomly select a host to connect to for a session. Another alias could point to the same target, but you could assign a host ID that Boundary should use for a session.
### Example
You may want to create aliases that point to the same target, but that specify which host Boundary should use when it establishes a session.
In this example, you set up three aliases for the same target:
1. A target alias without a host specified
1. A target alias with a host ID specified
1. A target alias with a different host ID specified
<Note>
This example uses SSH target types, which are only available in HCP Boundary and Boundary Enterprise. This process also works for any other target type, including the TCP target type available in Boundary Community Edition.
</Note>
For this example, assume that the following scopes exist:
- Org: `engineering`, ID `o_2drCWvp3Oc`
- Project: `app-servers`, ID `p_3ECODJDbXV`
And the following host set and hosts exist:
- Host set: `linux-dev-servers`, ID `hsst_56oiL0WaKu`
- Host: `dev-040`, ID `hst_7wGXkF8e0Q`
- Host: `dev-041`, ID `hst_zlRwMMPKwp`
Because the `linux-dev-servers` hosts are functionally equivalent, you can create a single target for the host set, and create an alias for the target.
We recommend creating DNS-like aliases to ensure consistent naming conventions. In this example, an alias pattern might be:
`hostname.host-set.project.org`
For the `linux-dev-servers` target, create the alias `linux-dev.app-servers.eng`.
<Tabs>
<Tab heading="UI" group="ui">
Create the `linux-dev-servers` target.
1. Log in to Boundary.
1. Select the 'engineering' org and the `app-servers` project.
1. Select **Targets** in the navigation pane.
1. Click **New Target**.
1. Complete the following fields:
- **Name**: `linux-dev-servers`
- **Description**: `linux-dev.app-servers.eng target`
- **Type**: SSH
- **Default Port**: `22`
- **Aliases**: `linux-dev.app-servers.eng`
1. Click **Save**.
Then add the `linux-dev-servers` host set to the new `linux-dev-servers` target.
1. Click on the **Host Sources** tab.
1. Click **Add Host Sources**.
1. Select the `linux-dev-servers` host set.
1. Click **Add Host Sources**.
</Tab>
<Tab heading="CLI" group="cli">
Create the `linux-dev-servers` target.
1. Log in to Boundary.
1. Use the following command to create the `linux-dev-servers` target with alias `linux-dev.app-servers.eng`:
```shell-session
$ boundary targets create ssh \
-description 'linux-dev.app-servers.eng target' \
-name linux-dev-servers \
-scope-id p_3ECODJDbXV \
-default-port 22 \
-with-alias-scope-id global \
-with-alias-value linux-dev.app-servers.eng
```
Example output:
<CodeBlockConfig hideClipboard>
```shell-session
$ boundary targets create ssh \
-description 'linux-dev.app-servers.eng target' \
-name linux-dev-servers \
-scope-id p_pj6UUPVJT3 \
-default-port 22 \
-with-alias-scope-id global \
-with-alias-value linux-dev.app-servers.eng
Target information:
Created Time: Thu, 14 Nov 2024 13:39:36 MST
Description: linux-dev.app-servers.eng target
ID: tssh_lhH5pa425G
Name: linux-dev-servers
Session Connection Limit: -1
Session Max Seconds: 28800
Type: ssh
Updated Time: Thu, 14 Nov 2024 13:39:36 MST
Version: 1
Scope:
ID: p_3ECODJDbXV
Name: app-servers
Parent Scope ID: o_2drCWvp3Oc
Type: project
Authorized Actions:
remove-host-sources
remove-credential-sources
authorize-session
delete
set-credential-sources
no-op
read
update
add-host-sources
set-host-sources
add-credential-sources
Aliases:
ID: alt_CkC6wGKLWW
Value: linux-dev.app-servers.eng
Attributes:
Default Port: 22
Enable Session Recording: false
```
</CodeBlockConfig>
Then add the `linux-dev-servers` host set (ID `hsst_56oiL0WaKu`) to the new `linux-dev-servers` target (ID `tssh_lhH5pa425G`).
```shell-session
$ boundary targets add-host-sources -id tssh_lhH5pa425G -host-sourchsst_56oiL0WaKu
```
</Tab>
<Tab heading="Terraform" group="terraform">
<Note>
In the following examples, Terraform resources are named with underscores instead of dashes, such as `linux_dev_servers`. The target alias values use dashes, such as `dev-041.linux-dev.app-servers.eng`. You do not need to follow these naming conventions.
</Note>
Create the `linux_dev_servers` SSH target, with `scope_id` set to `app_servers` and the host source `linux_dev_servers` (these resources are not shown):
```hcl
resource "boundary_target" "linux_dev_servers" {
name = "linux_dev_servers"
description = "linux_dev_servers target"
type = "ssh"
default_port = "22"
scope_id = boundary_scope.app_servers.id
host_source_ids = [
boundary_host_set_static.linux_dev_servers.id,
]
}
```
</Tab>
</Tabs>
Next, create two more aliases for the target.
Create the `dev-040.linux-dev.app-servers.eng` alias for the host `dev-040`:
<Tabs>
<Tab heading="UI" group="ui">
1. Log in to Boundary. Navigate to the `global` scope.
1. Select **Aliases** in the navigation pane.
1. Click **New Alias**.
1. Complete the following fields:
- **Name**: `dev-040`
- **Description**: `Target alias for dev-040.linux-dev.app-servers.eng`
- **Type**: `Target`
- **Alias Value**: `dev-040.linux-dev.app-servers.eng`
- **Target ID**: `tssh_lhH5pa425G`
- **Host ID**: `hst_7wGXkF8e0Q`
1. Click **Save**.
</Tab>
<Tab heading="CLI" group="cli">
1. Log in to Boundary.
1. Use the following command to create an alias for host `dev-040:
```shell-session
$ boundary aliases create target \
-description 'Target alias for dev-040.linux-dev.app-servers.eng' \
-destination-id tssh_lhH5pa425G \
-name dev-040 \
-scope-id global \
-value dev-040.linux-dev.app-servers.eng \
-authorize-session-host-id hst_7wGXkF8e0Q
```
Example output:
<CodeBlockConfig hideClipboard>
```shell-session
$ boundary aliases create target \
-description 'Target alias for dev-040.linux-dev.app-servers.eng' \
-destination-id tssh_lhH5pa425G \
-name dev-040 \
-scope-id global \
-value dev-040.linux-dev.app-servers.eng \
-authorize-session-host-id hst_7wGXkF8e0Q
Alias information:
Created Time: Thu, 14 Nov 2024 13:55:41 MST
Description: Target alias for dev-040.linux-dev.app-servers.eng
Destination ID: tssh_lhH5pa425G
ID: alt_QeCGTcvlq2
Name: dev-040
Type: target
Updated Time: Thu, 14 Nov 2024 13:55:41 MST
Value: dev-040.linux-dev.app-servers.eng
Version: 1
Scope:
ID: global
Name: global
Type: global
Authorized Actions:
no-op
read
update
delete
Attributes:
authorize_session_arguments:
{
"host_id": "hst_7wGXkF8e0Q"
}
```
</CodeBlockConfig>
</Tab>
<Tab heading="Terraform" group="terraform">
```hcl
resource "boundary_alias_target" "dev_040" {
name = "dev_040"
description = "Example alias for target linux_dev_servers using host dev_040"
scope_id = "global"
value = "dev-040.linux-dev.app-servers.eng"
destination_id = boundary_target.linux_dev_servers.id
authorize_session_host_id = boundary_host_static.dev_040.id
}
```
</Tab>
</Tabs>
Then create the `dev-041.linux-dev.app-servers.eng` alias for the host `dev-041`.
<Tabs>
<Tab heading="UI" group="ui">
1. Log in to Boundary. Navigate to the `global` scope.
1. Select **Aliases** in the navigation pane.
1. Click **New Alias**.
1. Complete the following fields:
- **Name**: `dev-041`
- **Description**: `Target alias for dev-041.linux-dev.app-servers.eng`
- **Type**: `Target`
- **Alias Value**: `dev-041.linux-dev.app-servers.eng`
- **Target ID**: `tssh_lhH5pa425G`
- **Host ID**: `hst_7wGXkF8e0Q`
1. Click **Save**.
</Tab>
<Tab heading="CLI" group="cli">
1. Log in to Boundary.
1. Use the following command to create an alias for host `dev-041`:
```shell-session
$ boundary aliases create target \
-description 'Target alias for dev-041.linux-dev.app-servers.eng' \
-destination-id tssh_lhH5pa425G \
-name dev-041 \
-scope-id global \
-value dev-041.linux-dev.app-servers.eng \
-authorize-session-host-id hst_zlRwMMPKwp
```
Example output:
<CodeBlockConfig hideClipboard>
```shell-session
$ boundary aliases create target \
-description 'Target alias for dev-041.linux-dev.app-servers.eng' \
-destination-id tssh_lhH5pa425G \
-name dev-041 \
-scope-id global \
-value dev-041.linux-dev.app-servers.eng \
-authorize-session-host-id hst_zlRwMMPKwp
Alias information:
Created Time: Thu, 14 Nov 2024 14:00:13 MST
Description: Target alias for dev-040.linux-dev.app-servers.eng
Destination ID: tssh_lhH5pa425G
ID: alt_X5MRXRSi7t
Name: dev-041
Type: target
Updated Time: Thu, 14 Nov 2024 14:00:13 MST
Value: dev-041.linux-dev.app-servers.eng
Version: 1
Scope:
ID: global
Name: global
Type: global
Authorized Actions:
no-op
read
update
delete
Attributes:
authorize_session_arguments:
{
"host_id": "hst_zlRwMMPKwp"
}
```
</CodeBlockConfig>
</Tab>
<Tab heading="Terraform" group="terraform">
```hcl
resource "boundary_alias_target" "dev_041" {
name = "dev_040"
description = "Example alias for target linux_dev_servers using host dev_040"
scope_id = "global"
value = "dev-041.linux-dev.app-servers.eng"
destination_id = boundary_target.linux_dev_servers.id
authorize_session_host_id = boundary_host_static.dev_041.id
}
```
</Tab>
</Tabs>
You can now use the aliases to connect to the targets in different contexts.
The Boundary Desktop Client lists the `linux-dev-servers` target and its aliases under the **Aliases** column.
When you click **Connect**, a list of the hosts available for the connection appears in the **Quick Connect** box.
To establish a connection to any `linux-dev` host using the CLI, use the `linux-dev.app-servers.eng` alias:
```shell-session
$ boundary connect ssh linux-dev.app-servers.eng
```
This command randomly selects a host from the `linux-dev-servers` host set attached to the `linux-dev-servers` target.
To establish a connection to a specific host, connect to its target alias instead:
```shell-session
$ boundary connect ssh dev-041.linux-dev.app-servers.eng
```
This alias still points to the `linux-dev-servers` target, but will only create a session with the `dev-041` host.
@@ -1,35 +0,0 @@
---
layout: docs
page_title: Overview
description: >-
Learn how to configure aliases and transparent sessions to enhance end-user workflows and simplify target access.
---
# Overview
Target aliases simplify the connection workflow for end users by allowing them to reference targets using a globally unique DNS-like string.
Without aliases, connecting to an end target requires you to reference the target ID, or a combination of target name and scope:
```shell-session
$ boundary connect ssh -target-id ttcp_1234567890
```
```shell-session
$ boundary connect ssh -target-name sql-database -target-scope-name -staging
```
With target aliases, a single globally referenced value is assigned to a target, simplifying connection workflows and enabling transparent sessions for Enterprise and HCP end users.
```shell-session
$ boundary connect ssh sql-database-staging
```
## Configure target aliases
To set up a target alias:
1. [Create a target alias](/boundary/docs/configuration/target-aliases/create-target-alias)
1. [Connect to a target using an alias](/boundary/docs/configuration/target-aliases/connect-target-alias)
After you set up a target alias, you can optionally [Configure transparent sessions for end users](/boundary/docs/configuration/target-aliases/transparent-sessions). <sup>HCP/ENT</sup>
@@ -1,177 +0,0 @@
---
layout: docs
page_title: Transparent sessions interoperability matrix
description: >-
Refer to a matrix to determine which partner products and applications are supported by the Boundary components required for transparent sessions.
---
# Transparent sessions interoperability matrix
@include 'alerts/enterprise-only.mdx'
Transparent sessions require you to use the Boundary installer to install the Boundary Client Agent.
To support a variety of use cases, HashiCorp verifies implementation and integrations with partner products and applications.
HashiCorp engineering has tested and confirmed that you can use the following third-party products with the specific versions of the Boundary installer, Boundary Client Agent, and any operating systems listed in the table.
Transparent sessions may operate with other versions of the products listed below or with other products, but they have not been tested.
We will update the list of products as we test them.
<Note>
On May 27, 2025 new versions of the Boundary Client Agent and installer were released with a numbering scheme that more closely follows Boundary's release numbers.
Those versions were released as 0.19.5 to match the major Boundary version 0.19.x.
Going forward, the Client Agent and installer will use the same major number as the current Boundary release.
Any patches or updates will be reflected in the minor number.
</Note>
<table>
<thead>
<tr>
<th style={{verticalAlign: 'middle', width: '25%'}}>Product</th>
<th style={{verticalAlign: 'middle'}}>Boundary installer versions</th>
<th style={{veritcalAlign: 'middle'}}>Boundary Client Agent versions</th>
<th style={{verticalAlign: 'middle', width: '25%'}}>OS versions tested</th>
<th style={{veritcalAlign: 'middle'}}>Conflicts and workarounds</th>
</tr>
</thead>
<tbody>
<tr>
<td style={{verticalAlign: 'middle'}}>
CloudFlare WARP
<br /><br />
<b>MacOS version</b>: 2025.2.600.0
<br />
<b>Windows version</b>: 2025.2.600.0
</td>
<td style={{verticalAlign: 'middle'}}>
0.1.4, 0.19.5, 0.19.6
</td>
<td style={{verticalAlign: 'middle'}}>
0.1.4, 0.19.5, 0.19.6
</td>
<td style={{verticalAlign: 'middle'}}>
<b>MacOS</b>: 14.6, 15.3
<br />
<b>Windows</b>: 10 Pro, 11 Pro
</td>
<td style={{verticalAlign: 'middle'}}>
Refer to <a href="/boundary/docs/api-clients/client-agent#cloudflare-warp-client">Conflicting software</a>
</td>
</tr>
<tr>
<td style={{verticalAlign: 'middle'}}>
Huntress
<br /><br />
<b>MacOS version</b>: 0.14.10
<br />
<b>Windows version</b>: 0.14.14
</td>
<td style={{verticalAlign: 'middle'}}>
0.1.4, 0.19.6
</td>
<td style={{verticalAlign: 'middle'}}>
0.1.4, 0.19.6
</td>
<td style={{verticalAlign: 'middle'}}>
<b>MacOS</b>: 14.6, 15.3
<br />
<b>Windows</b>: 10 Pro, 11 Pro
</td>
<td style={{verticalAlign: 'middle'}}>
Refer to <a href="/boundary/docs/api-clients/client-agent#huntress-edr-client-windows">Conflicting software</a>
</td>
</tr>
<tr>
<td style={{verticalAlign: 'middle'}}>
Microsoft Defender for Endpoint
</td>
<td style={{verticalAlign: 'middle'}}>
0.1.4, 0.19.5, 0.19.6
</td>
<td style={{verticalAlign: 'middle'}}>
0.1.4, 0.19.5, 0.19.6
</td>
<td style={{verticalAlign: 'middle'}}>
<b>MacOS</b>: 14, 15
<br />
<b>Windows</b>: 10, 11 Pro
</td>
<td style={{verticalAlign: 'middle'}}>
&nbsp;
</td>
</tr>
<tr>
<td style={{verticalAlign: 'middle'}}>
Palo Alto GlobalProtect
</td>
<td style={{verticalAlign: 'middle'}}>
0.19.5, 0.19.6
</td>
<td style={{verticalAlign: 'middle'}}>
0.19.5, 0.19.6
</td>
<td style={{verticalAlign: 'middle'}}>
<b>MacOS</b>: 14, 15
<br />
<b>Windows</b>: 10, 11
</td>
<td style={{verticalAlign: 'middle'}}>
&nbsp;
</td>
</tr>
<tr>
<td style={{verticalAlign: 'middle'}}>
SentinelOne Singularity
</td>
<td style={{verticalAlign: 'middle'}}>
0.1.4, 0.19.5, 0.19.6
</td>
<td style={{verticalAlign: 'middle'}}>
0.1.4, 0.19.5, 0.19.6
</td>
<td style={{verticalAlign: 'middle'}}>
<b>MacOS</b>: 14, 15.2
<br />
<b>Windows</b>: 10, 11
</td>
<td style={{verticalAlign: 'middle'}}>
&nbsp;
</td>
</tr>
<tr>
<td style={{verticalAlign: 'middle'}}>
Zscaler ZPA
</td>
<td style={{verticalAlign: 'middle'}}>
0.1.4, 0.19.5, 0.19.6
</td>
<td style={{verticalAlign: 'middle'}}>
0.1.4, 0.19.5, 0.19.6
</td>
<td style={{verticalAlign: 'middle'}}>
<b>MacOS</b>: 15
<br />
<b>Windows</b>: 11
</td>
<td style={{verticalAlign: 'middle'}}>
&nbsp;
</td>
</tr>
</tbody>
</table>
## More information
For more information, refer to the following topics:
- [Transparent sessions](/boundary/docs/concepts/transparent-sessions)
- [Configure transparent sessions](/boundary/docs/configuration/target-aliases/transparent-sessions)
- [Boundary Client Agent](/boundary/docs/api-clients/client-agent)
@@ -1,119 +0,0 @@
---
layout: docs
page_title: Configure transparent sessions
description: >-
Learn how to configure transparent sessions to enhance end-user workflows and simplify target access.
---
# Configure transparent sessions
@include 'alerts/enterprise-only.mdx'
## Requirements
Before you configure transparent sessions, you must:
- If you have previous versions of the Boundary Desktop or CLI client in your local environment, ensure that they are fully uninstalled before you install with the latest Boundary installer.
- Download the appropriate Boundary installer for your Windows or MacOS environment from the [Install Boundary](/boundary/install#installer) page or the [releases](https://releases.hashicorp.com/boundary-installer) page.
- Ensure that both IPv4 and IPv6 protocols are enabled for your environment. The [Client Agent](/boundary/docs/api-clients/client-agent) requires both protocols to start and perform DNS lookups.
Once Boundary is installed, you should make sure you have the appropriate grants configured so that you can resolve aliases and establish transparent sessions.
For more information, refer to the [Grants](/boundary/docs/api-clients/client-agent#grants) section in the Client Agent documentation.
<Warning>
A known issue regarding how grants were previously created in HCP Boundary may cause you to receive a 500 error when you attempt to list resolvable aliases.
Clusters created before April 26, 2025 may be missing the following grants:
`ids={{.User.Id}};type=user;actions=list-resolvable-aliases`
`ids=*;type=target;actions=list,read`
If your cluster is missing these grants, HashiCorp recommends adding them.
For more information, refer to the [known issue](/boundary/docs/release-notes/v0_19_0#hcp-grants).
</Warning>
## Install the Boundary clients
Complete the following steps to install the Boundary Client Agent, CLI, and Desktop client:
1. Install Boundary using the installer.
Make sure to select the options **Boundary Client Agent**, **CLI**, and **Desktop**.
1. Open the CLI and type the following command to confirm that the version is 0.18.0:
```shell-session
$ boundary version
```
1. In the CLI, run the status command to confirm that the Boundary Client Agent has started:
```shell-session
$ boundary client-agent status
```
Refer to the [transparent sessions interoperability matrix](/boundary/docs/configuration/target-aliases/interoperability-matrix) for a list of the third-party products that have been tested for use with the Boundary installer and Client Agent.
## Configure targets
The following section details how to configure targets and use transparent sessions.
<Tip>
If you use a cluster that was created earlier than release 0.16.0, you must add the grant `list-resolvable-aliases` so that the client agent can populate the local alias cache.
As an example, you could add the grant:
`type=user;actions=list-resolvable-aliases;ids=*`.
For more information, refer to the [Grants](/boundary/docs/api-clients/client-agent#grants) section in the Client Agent documentation.
</Tip>
Complete the following steps to configure targets and test transparent sessions:
1. Authenticate to Boundary using the CLI or Desktop client.
1. [Create a new target with an alias](/boundary/docs/concepts/aliases#create-an-alias-during-target-creation) or [create an alias for an existing target](/boundary/docs/concepts/aliases#create-an-alias-for-an-existing-target).
Ensure that you have authorization to establish a session to the target.
1. Open the client of your choice and [connect to your target using the alias](/boundary/docs/concepts/aliases#connect-to-a-target-using-an-alias).
Boundary routes your session using the Boundary Client Agent.
You can validate that Boundary routed the session by looking at the **Sessions** page in the Desktop client, by typing `boundary sessions list -recursive` in the CLI, or by looking at sessions managed by the Client Agent using `boundary client-agent sessions`.
<Note>
The Client Agent periodically requests an updated list of aliases from the controller, so the alias may not work immediately after you create it.
The alias should be updated in the Client Agent within 2 minutes. If you still see connection issues after 2 minutes, follow the troubleshooting steps in [the Client Agent troubleshooting guide](/boundary/docs/api-clients/client-agent#troubleshooting).
</Note>
When you have validated that transparent sessions work, you can create and establish transparent sessions to other services.
To establish transparent sessions to other services:
1. Make a list of the services you use.
1. Create workers as needed for network partitions.
1. Add the services to Boundary as targets.
1. [Create aliases for the targets](/boundary/docs/configuration/target-aliases/create-target-alias).
1. Connect to the target using your client of choice.
## Connect using transparent sessions
Without transparent sessions, you must use the [Boundary connect helpers](/boundary/docs/concepts/connection-workflows) to establish a session:
```shell-session
$ boundary connect ssh -target-name sql-database -target-scope-name -staging
```
Alternatively, you can use the Boundary Desktop Client to start a session, and connect on a local port supplied by Boundary:
```shell-session
$ ssh 127.0.0.1 -p 55374
```
With transparent sessions, you use the target alias as the address to establish a session. If the [client agent is running](#install-the-boundary-clients) and you have authenticated using the CLI or Boundary Desktop Client, you can use the alias to start a session:
```shell-session
$ ssh my.alias.name
```
Boundary starts the session as usual, and brokers or injects any credentials you have configured.
@@ -1,222 +0,0 @@
---
layout: docs
page_title: Worker configuration overview
description: >-
Learn about worker configuration for proxies, storage, and tags. Understand how multi-hop configurations let you chain workers together in private networks.
---
# Worker stanza
The `worker` stanza configures Boundary worker-specific parameters.
All workers within Boundary use certificates and encryption keys to identify
themselves and protect data in transit. However, there are three different
ways to register them so that registration of workers can fit into any workflow: controller-led, worker-led, and via external KMS.
The sub-pages linked at the bottom of this page explain the differences in their configuration.
You must register workers using the worker-led or controller-led methods in the system with an API call. These workers require storage on disk to store the current set of credentials. Workers using an external KMS auto-register after authenticating. This makes them an easy mechanism to use for automatic scaling.
This also means they do not need to store
credentials locally; the KMS re-authenticates them each time they connect.
<Note title="Important">
Before version 0.15 of Boundary, there were two different types of workers, PKI & KMS workers.
If you are using pre-0.15 workers with pre-0.15 upstream configurations, please switch the documentation version to `0.13.x` - `0.14.x`. This will ensure you have the correct information.
</Note>
## Common worker parameters
The following fields apply to all registration mechanisms.
```hcl
worker {
public_addr = "5.1.23.198"
# Local storage path required if session recording is enabled
recording_storage_path = "tmp/boundary/"
# Minimum available disk space required in the local storage path if session recording is enabled
recording_storage_minimum_available_capacity = "500MB"
# Mutually exclusive with hcp_boundary_cluster_id
initial_upstreams = [
"10.0.0.1",
"10.0.0.2",
]
tags {
type = ["prod", "webservers"]
region = ["us-east-1"]
}
# HCP Boundary only
# hcp_boundary_cluster_id = "....."
}
```
- `public_addr` - Specifies the public host or IP address (and optionally port)
where clients can reach the worker for proxying. By default, it uses the
address of the listener marked for `proxy` purpose. This is useful for cloud
environments that do not bind a publicly accessible IP directly to a NIC on
the host, such as an Amazon EIP.
You should omit this parameter in multi-hop configurations if this self-managed worker connects to an upstream HCP-managed worker.
This value can reference any of the following:
- a direct address string
- read an address from a file on disk (file://)
- read an address from an environment variable (env://)
- `initial_upstreams` - A list of hosts/IP addresses and optionally ports for
reaching the Boundary cluster. The port will default to `:9201` if not
specified. This value can be a direct access string array with the addresses,
or it can refer to a file on disk (`file://`) from which the addresses will be
read, or an environment variable (`env://`) from which to read the addresses. When
using environment variable or file, their contents must formatted as a JSON array:
`["127.0.0.1", "192.168.0.1", "10.0.0.1"]`
Self-managed workers connecting to HCP Boundary require the [`hcp_boundary_cluster_id`](/boundary/docs/configuration/worker/#hcp_boundary_cluster_id) parameter instead of `initial upstreams`, unless you are configuring an HCP-managed worker as an ingress worker.
If you configure a self-managed worker with both `initial_upstreams` and `hcp_boundary_cluster_id`, the worker configuration fails.
- `hcp_boundary_cluster_id` - A string required to configure workers using worker-led or controller-led registration
to connect to your HCP Boundary cluster rather than specifying
`initial_upstreams`. This parameter is valid only for workers using the worker-led or controller-led
registration method and for workers directly connected to HCP Boundary.
- `recording_storage_path` - A path to the local storage for recorded sessions.
Boundary stores session recordings in the local storage while they are in progress.
When the session is complete, Boundary moves the local session recording to remote storage and deletes the local copy.
- `recording_storage_minimum_available_capacity` - A value measured in bytes that
defines the worker's local storage state. Boundary compares this value to the available local disk space found in the `recording_storage_path` and determines if a worker can perform session recording operations.
The supported suffixes are kb, kib, mb, mib, gb, gib, tb, tib, which are not case sensitive. Example: 2GB, 2gb, 2GiB, 2gib.
The possible storage states based on the `recording_storage_minimum_available_capacity` are:
- Available - The worker has storage above the threshold and can proxy sessions that have session recording enabled.
- Low storage - The worker has storage below the threshold. It allows existing sessions to continue without interruption but prevents proxying new sessions that have session recording enabled. The worker cannot record new sessions or play back existing recordings.
- Critically low storage - The worker falls below half the storage threshold. It forcefully closes existing sessions with session recording. The worker cannot record new sessions or play back existing recordings.
- Out of storage - The worker is out of local disk space. It cannot record new sessions or play back existing recordings. The worker enters an unrecoverable state, requiring an administrator to intervene and resolve the issue.
- Not configured - The worker lacks a configured local storage path.
- Unknown - The worker starts with this default local storage state. This state indicates that the worker's local storage state is not yet known.
- `tags` - A map of key-value pairs where values are an array of strings. Most
commonly used for [filtering](/boundary/docs/concepts/filtering) targets a
worker can proxy via [worker
tags](/boundary/docs/concepts/filtering/worker-tags). On `SIGHUP`, the tags
set here will be re-parsed and new values used. It can also be a string
referring to a file on disk (`file://`) or an environment variable (`env://`).
## Signals
The `SIGHUP` signal causes a worker to reload its configuration file to pick up any updates for the `initial_upstreams` and `tags` values.
Boundary ignores other updated values.
The `SIGTERM` and `SIGINT` signals initiate a graceful shutdown on a worker. The worker waits for any sessions to drain
before shutting down. Workers in a graceful shutdown state do not receive any new work, including session proxying, from the control plane.
## Multi-hop worker capabilities
<EnterpriseAlert product="boundary">This feature requires <a href="https://www.hashicorp.com/products/boundary">HCP Boundary or Boundary Enterprise</a></EnterpriseAlert>
Multi-hop capabilities, including multi-hop sessions and Vault private access,
is when a session or Vault credential request goes through more than one worker.
To enable this, you must connect two or more workers to each other in some
configuration. There are no limits on the number of workers allowed in a
multi-hop session configuration.
It helps to think of “upstream” and “downstream” nodes in the context of
multi-hop. If you view controllers as the “top” node of a multi-hop chain, any
worker connected to a node is "downstream" of that node. The node that any
particular worker connects to (whether another worker or a controller) is the
"upstream" of that node. For example, in the diagram below, Worker 2’s upstream
is Worker 1, and its downstream is Worker 3.
![multi-hop workers](/img/multi-hop-workers.png)
You can deploy multi-hop workers in scenarios where inbound network traffic is
not allowed. A worker in a private network can send outbound communication to
its upstream worker, and create a reverse proxy to establish a session.
You can configure [target worker filters][] with multi-hop workers to allow for
fine-grained control on which workers handle ingress and egress for session
traffic to a [target][]. Ingress worker filters specify the workers you use to initiate a session, and egress worker filters specify the workers you use to access targets.
### Multi-hop worker requirements
When you configure multi-hop sessions, there is an "ingress" worker, an "egress"
worker, and any number of intermediary workers. Ingress, egress, and
intermediary workers have the following requirements.
#### Ingress worker requirements
To proxy target connections, ingress workers require outbound access to the
Boundary control plane and inbound access from clients.
#### Intermediary worker requirements
Intermediary workers require outbound access to an upstream worker. The upstream
worker may be an ingress worker or another intermediary worker. Intermediary
workers also require inbound access from a downstream worker. The downstream
worker may be an egress worker or another intermediary worker.
#### Egress worker requirements
To proxy target connections, egress workers require outbound access to an
upstream worker and outbound access to the destination host or service.
## Complete configuration example
```hcl
listener "tcp" {
purpose = "proxy"
tls_disable = true
address = "127.0.0.1"
}
worker {
# Path for worker storage, assuming worker-led or controller-led registration. Must be unique across workers
auth_storage_path="/boundary/demo-worker-1"
# Local storage path required if session recording is enabled
recording_storage_path = "tmp/boundary/"
# Minimum available disk space required in the local storage path if session recording is enabled
recording_storage_minimum_available_capacity = "500MB"
# Workers typically need to reach upstreams on :9201
initial_upstreams = [
"10.0.0.1",
"10.0.0.2",
"10.0.0.3",
]
public_addr = "myhost.mycompany.com"
tags {
type = ["prod", "webservers"]
region = ["us-east-1"]
}
}
# The following KMS config is an example only
# Use a production KMS such as AWS KMS for production installs
kms "aead" {
purpose = "worker-auth-storage"
aead_type = "aes-gcm"
key = "X+IJMVT6OnsrIR6G/9OTcJSX+lM9FSPN"
key_id = "worker-auth-storage"
}
```
## Tutorials
Refer to the [Self-Managed Worker Registration with HCP Boundary](/boundary/tutorials/hcp-administration/hcp-manage-workers) tutorial to learn how to register and manage Workers.
Refer to the [Manage Multi-Hop Sessions with HCP Boundary](/boundary/tutorials/hcp-administration/hcp-manage-multi-hop) tutorial to learn how to configure a multi-hop session.
[Worker Configuration Methods]: /boundary/docs/configuration/worker/worker-configuration
[target]: /boundary/docs/concepts/domain-model/targets
[target worker filters]: /boundary/docs/concepts/filtering/worker-tags#target-worker-filtering
[session recording]: /boundary/docs/configuration/session-recording
@@ -1,219 +0,0 @@
---
layout: docs
page_title: Worker configuration
description: >-
Learn about authorizing workers to the controller and configuring workers for session recording storage. View a complete worker configuration example.
---
# Worker configuration
Workers authenticate to Boundary using an activation token. They require an
accessible directory defined by `auth_storage_path` for credential storage and
rotation. Transport level communication between the worker & Controller is secured through PKI.
Example (not safe for production!):
```hcl
worker {
auth_storage_path="/var/lib/boundary"
initial_upstreams = ["10.0.0.1"]
}
```
## Authorization methods
There are three mechanisms that can be used to initially register a worker to the cluster, Controller-Led, Worker-Led, and registration through an external KMS.
### Controller-led authorization flow
In this flow, the operator fetches an activation token from the controller's
`workers:create:controller-led` action (on the CLI, this is via `boundary
workers create controller-led`). That activation token is given to the worker
via the `controller_generated_activation_token` parameter. This can be done
either directly or via an env var or file by using `env://` or `file://` syntax:
```hcl
worker {
auth_storage_path="/var/lib/boundary"
initial_upstreams = ["10.0.0.1"]
controller_generated_activation_token = "neslat_........."
# controller_generated_activation_token = "env://ACT_TOKEN"
# controller_generated_activation_token = "file:///tmp/worker_act_token"
}
```
Once the worker starts, it reads this token and uses it to authorize to the
cluster. Note that this token is one-time-use; it is safe to keep it here even
after the worker has successfully authorized and authenticated, as it will be
unusable at that point.
Note: If this value is not present at worker startup time and the worker is not
authorized, it will print and write out suitable information for the worker-led
flow, described below. If the worker-led flow has not been used to
authorize the worker, and the controller-generated activation token is provided
and the worker restarted, it will make use of it.
### Worker-led authorization flow
In this flow, the worker prints out an authorization request token to two
places: the startup information printed to stdout, and a file called
`auth_request_token` in the base of the configured `auth_storage_path`. This
token can be submitted to a controller at the `workers:create:worker-led` path;
on the CLI this would be via `boundary workers create worker-led
-worker-generated-auth-token`. No values are needed in the configuration file.
### KMS-led authorization & authentication flow
In this flow, the worker authenticates upstream, either to a controller or worker, using a shared KMS provided by the customer. This mechanism auto-registers the worker in addition to authenticating it, and does not require on-disk storage for credentials since each time it connects, it re-authenticates using the trusted KMS.
Optionally with the Multi-Hop workers feature, trusted Workers can authenticate downstream nodes using a separate KMS.
Workers using KMS-led authorization require a `name` field. This specifies a unique name of this worker
within the Boundary cluster and _must be unique across workers_. The `name`
value can be:
- a direct name string (must be all lowercase)
- a reference to a file on disk (`file://`) from which the name is read
- an env var (`env://`) from which the name is read.
Workers using KMS-led authorization accept an optional `description` field. The `description` value can
be:
- a direct description string
- a reference to a file on disk (`file://`) from which the name is read
- an env var (`env://`) from which the name is read.
```hcl
worker {
name = "example-worker"
description = "An example worker"
public_addr = "5.1.23.198"
}
```
Workers using the KMS authorization flow also require a KMS block designated for `worker-auth`. This is the KMS configuration for authentication between the workers and controllers and must be present. Example (not safe for production!):
```hcl
kms "aead" {
purpose = "worker-auth"
aead_type = "aes-gcm"
key = "X+IJMVT6OnsrIR6G/9OTcJSX+lM9FSPN"
key_id = "global_worker-auth"
}
```
The upstream controller or worker must have a `kms` block that references the
same key and purpose. If both a controller and worker are running as the same
server process, only one stanza is needed.
For Multi-Hop workers, It is also possible to specify a `kms` block with the `downstream-worker-auth` purpose. If specified, this will be a separate KMS that can be used for authenticating new downstream nodes. Blocks with this purpose can be specified multiple times. This allows a single upstream node to authenticate with one key to its own upstream (via the `worker-auth` purpose) and then serve as an authenticating upstream to nodes
across various networks, each with their own separate KMS system or key:
```hcl
kms "aead" {
purpose = "downstream-worker-auth"
aead_type = "aes-gcm"
key = "XthZVtFtBD1Bw1XwAWhZKVrIwRhR7HcZ"
key_id = "iot-nodes-auth"
}
kms "aead" {
purpose = "downstream-worker-auth"
aead_type = "aes-gcm"
key = "OLFhJNbEb3umRjdhY15QKNEmNXokY1Iq"
key_id = "production-nodes-auth"
}
```
In the examples above we are encoding key bytes directly in the configuration
file. This is because we are using the `aead` method where you directly supply a
key; in production you'd want to use a KMS such as AWS KMS, GCP CKMS, Azure
KeyVault, or HashiCorp Vault. For a complete guide to all available KMS types,
see our [KMS documentation](/boundary/docs/configuration/kms).
## Complete configuration example
```hcl
listener "tcp" {
purpose = "proxy"
tls_disable = true
address = "127.0.0.1"
}
worker {
# Name attr must be unique across workers
name = "demo-worker-1"
description = "A default worker created for demonstration"
# Workers must be able to reach upstreams on :9201
initial_upstreams = [
"10.0.0.1",
"10.0.0.2",
"10.0.0.3",
]
public_addr = "myhost.mycompany.com"
tags {
type = ["prod", "webservers"]
region = ["us-east-1"]
}
}
# must be same key as used on controller config
kms "aead" {
purpose = "worker-auth"
aead_type = "aes-gcm"
key = "X+IJMVT6OnsrIR6G/9OTcJSX+lM9FSPN"
key_id = "global_worker-auth"
}
```
[`initial_upstreams`](/boundary/docs/configuration/worker#initial_upstreams)
are used to connect to upstream Boundary clusters.
## Resources
For more on how `tags{}` in the above configuration are used to facilitate
routing to the correct target, refer to the [Worker
Tags](/boundary/docs/concepts/filtering/worker-tags) page.
## KMS configuration
When using Controller or Worker-led Authentication, a worker’s generated activation token is stored in clear-text on disk. Using an external KMS, a Workers' credentials can be encrypted by including an optional KMS stanza with the purpose `worker-auth-storage`.
Example (not safe for production!):
```hcl
kms "aead" {
purpose = "worker-auth-storage"
aead_type = "aes-gcm"
key = "X+IJMVT6OnsrIR6G/9OTcJSX+lM9FSPN"
key_id = "worker-auth-storage"
}
```
## Session recording
<EnterpriseAlert product="boundary">This feature requires <a href="https://www.hashicorp.com/products/boundary">HCP Boundary or Boundary Enterprise</a></EnterpriseAlert>
[Session recording](/boundary/docs/configuration/session-recording) requires at least one Worker with access to local and remote storage.
Workers used for session recording require an accessible directory defined by `recording_storage_path` for storing in-progress session recordings. On session closure, a local session recording is moved to remote storage and deleted locally.
The `recording_storage_minimum_available_capacity` value determines the minimum amount of storage space that is required for workers to perform session recording operations. If a worker is at or below the storage threshold, Boundary does not use the worker to record sessions or play back recordings.
Development example:
```hcl
worker {
auth_storage_path="/var/lib/boundary"
initial_upstreams = ["10.0.0.1"]
recording_storage_path="/local/storage/directory"
recording_storage_minimum_available_capacity="500MB"
}
```
<Note>
The `name` and `description` fields are not valid configuration fields for workers that use worker-led or controller-led authorization. You can only set these fields through the API and they are only valid for workers that use the [KMS authorization method](/boundary/docs/configuration/worker/worker-configuration#kms-led-authorization-authentication-flow).
</Note>
@@ -0,0 +1,16 @@
---
layout: docs
page_title: Worker stanza
description: >-
Learn about how to configure workers for proxies, storage, and tags.
---
# worker stanza
The `worker` stanza configures Boundary worker-specific parameters.
@include '/configuration-reference/workers/common-worker-parameters.mdx'
## Complete configuration example
@include '/configuration-reference/workers/complete-configuration-example.mdx'