2020-09-23 12:15:21 -07:00
|
|
|
---
|
|
|
|
|
layout: docs
|
2024-12-04 13:28:17 -05:00
|
|
|
page_title: AliCloud KMS configuration
|
2020-09-23 12:15:21 -07:00
|
|
|
description: >-
|
2024-12-04 13:28:17 -05:00
|
|
|
Learn about using the AliCloud KMS for key management and configuring parameters and authentication. View an example alicloudkms configuration.
|
2020-09-23 12:15:21 -07:00
|
|
|
---
|
|
|
|
|
|
|
|
|
|
# `alicloudkms` KMS
|
|
|
|
|
|
|
|
|
|
The AliCloud KMS configures Boundary to use AliCloud KMS for key management.
|
|
|
|
|
The AliCloud KMS is activated by one of the following:
|
|
|
|
|
|
|
|
|
|
- The presence of a `kms "alicloudkms"` block in Boundary's configuration file.
|
|
|
|
|
|
2023-07-07 14:42:11 -04:00
|
|
|
## `alicloudkms` example
|
2020-09-23 12:15:21 -07:00
|
|
|
|
|
|
|
|
This example shows configuring AliCloud KMS through the Boundary configuration file
|
|
|
|
|
by providing all the required values:
|
|
|
|
|
|
|
|
|
|
```hcl
|
|
|
|
|
kms "alicloudkms" {
|
2020-10-13 15:21:09 -04:00
|
|
|
purpose = "root"
|
2020-09-23 12:15:21 -07:00
|
|
|
region = "us-east-1"
|
|
|
|
|
access_key = "0wNEpMMlzy7szvai"
|
|
|
|
|
secret_key = "PupkTg8jdmau1cXxYacgE736PJj4cA"
|
|
|
|
|
kms_key_id = "08c33a6f-4e0a-4a1b-a3fa-7ddfa1d4fb73"
|
|
|
|
|
}
|
|
|
|
|
```
|
|
|
|
|
|
2023-07-07 14:42:11 -04:00
|
|
|
## `alicloudkms` parameters
|
2020-09-23 12:15:21 -07:00
|
|
|
|
|
|
|
|
These parameters apply to the `kms` stanza in the Boundary configuration file:
|
|
|
|
|
|
2022-11-24 19:07:37 -06:00
|
|
|
- `purpose` - Purpose of this KMS, acceptable values are: `worker-auth`, `worker-auth-storage`,
|
2024-04-12 15:37:52 -04:00
|
|
|
`root`, `previous-root`, `recovery`, `bsr`, or `config`.
|
2020-10-13 15:21:09 -04:00
|
|
|
|
2020-09-23 12:15:21 -07:00
|
|
|
- `region` `(string: <required> "us-east-1")`: The AliCloud region where the encryption key
|
|
|
|
|
lives. May also be specified by the `ALICLOUD_REGION`
|
|
|
|
|
environment variable.
|
|
|
|
|
|
|
|
|
|
- `domain` `(string: "kms.us-east-1.aliyuncs.com")`: If set, overrides the endpoint
|
|
|
|
|
AliCloud would normally use for KMS for a particular region. May also be specified
|
|
|
|
|
by the `ALICLOUD_DOMAIN` environment variable.
|
|
|
|
|
|
|
|
|
|
- `access_key` `(string: <required>)`: The AliCloud access key ID to use. May also be
|
|
|
|
|
specified by the `ALICLOUD_ACCESS_KEY` environment variable or as part of the
|
|
|
|
|
AliCloud profile from the AliCloud CLI or instance profile.
|
|
|
|
|
|
|
|
|
|
- `secret_key` `(string: <required>)`: The AliCloud secret access key to use. May
|
|
|
|
|
also be specified by the `ALICLOUD_SECRET_KEY` environment variable or as
|
|
|
|
|
part of the AliCloud profile from the AliCloud CLI or instance profile.
|
|
|
|
|
|
|
|
|
|
- `kms_key_id` `(string: <required>)`: The AliCloud KMS key ID to use for encryption
|
2020-10-13 15:21:09 -04:00
|
|
|
and decryption. May also be specified by the `ALICLOUDKMS_WRAPPER_KEY_ID`
|
2020-09-23 12:15:21 -07:00
|
|
|
environment variable.
|
|
|
|
|
|
|
|
|
|
## Authentication
|
|
|
|
|
|
|
|
|
|
Authentication-related values must be provided, either as environment
|
|
|
|
|
variables or as configuration parameters.
|
|
|
|
|
|
|
|
|
|
~> **Note:** Although the configuration file allows you to pass in
|
|
|
|
|
`ALICLOUD_ACCESS_KEY` and `ALICLOUD_SECRET_KEY` as part of the 's parameters, it
|
|
|
|
|
is _strongly_ recommended to set these values via environment variables.
|
|
|
|
|
|
|
|
|
|
```text
|
|
|
|
|
AliCloud authentication values:
|
|
|
|
|
|
|
|
|
|
* `ALICLOUD_REGION`
|
|
|
|
|
* `ALICLOUD_ACCESS_KEY`
|
|
|
|
|
* `ALICLOUD_SECRET_KEY`
|
|
|
|
|
```
|
|
|
|
|
|
2022-07-12 12:29:35 -07:00
|
|
|
The client uses the official AliCloud SDK and will use environment credentials,
|
2020-09-23 12:15:21 -07:00
|
|
|
the specified credentials, or RAM role credentials in that order.
|