1
1
title : Create an AWS IAM User
2
2
ref : create-an-aws-iam-user
3
3
content : |
4
- Create a new programmatic IAM user to use in CSFLE-enabled clients.
5
- The user will encrypt and decrypt the remote master key and must have
4
+ Create a new programmatic IAM user in the AWS management console.
5
+ CSFLE-enabled clients authenticate with AWS KMS using the IAM user to
6
+ encrypt and decrypt the remote master key. The IAM user must be granted
6
7
full ``List`` and ``Read`` permissions for the KMS service.
7
8
8
9
.. admonition:: Client IAM User Credentials
9
10
:class: note
10
11
11
- The CSFLE-enabled client takes the IAM User's :guilabel:`Access Key
12
- ID` and :guilabel:`Secret Access Key` as configuration values. Note
13
- these down for later when we reconfigure the client.
12
+ The CSFLE-enabled client uses the IAM User's :guilabel:`Access Key
13
+ ID` and :guilabel:`Secret Access Key` as configuration values. Take
14
+ note of these and reference them when we update the client.
14
15
---
15
16
title : Create the Master Key
16
17
ref : create-the-master-key
17
18
content : |
18
- In AWS KMS, generate a new master key. The key's name and description
19
- don't affect the functionality of CSFLE but should describe that it's
20
- for the CSFLE-enabled client.
19
+
20
+ The following diagram shows how the **master key** is created and stored
21
+ when using a KMS provider:
22
+
23
+ .. image:: /figures/CSFLE_Master_Key_KMS.png
24
+ :alt: Diagram that describes creating a master key when using a KMS provider
25
+
26
+ In AWS management console, create a new symmetric master key in the KMS
27
+ section. Choose a name and description that helps you identify it; these
28
+ fields do not affect the functionality or configuration.
21
29
22
30
In the :guilabel:`Usage Permissions` step of the key generation
23
- process, select the newly created IAM User with full KMS ``List`` and
24
- ``Read`` permissions . This allows the user to encrypt and decrypt the
25
- new master key.
31
+ process, add the full KMS ``List`` and ``Read`` permissions to the IAM
32
+ user you created in the previous step . This authorizes the user to encrypt
33
+ and decrypt the new master key.
26
34
27
35
.. important::
28
36
@@ -32,13 +40,15 @@ content: |
32
40
title : Specify the AWS KMS Provider Credentials
33
41
ref : specify-the-aws-kms-provider-credentials
34
42
content : |
35
- Unlike the local KMS provider, the AWS KMS provider does not accept
36
- the master key directly from the client configuration code . Instead,
43
+ Unlike the local key provider, the AWS KMS provider does not read
44
+ the master key directly from the client application . Instead,
37
45
it accepts the :guilabel:`Access Key ID` and :guilabel:`Secret Access
38
- Key` of the IAM user with permission to encrypt and decrypt the master
39
- key.
46
+ Key` configurations that point to the master key. The IAM user must have
47
+ the permissions set up in the previous step in order for the client to
48
+ use the KMS to encrypt and decrypt data encryption keys.
40
49
41
- Update the KMS Provider configuration in CSFLE-enabled client creation code:
50
+ Update the KMS Provider configuration in your CSFLE-enabled client
51
+ creation code:
42
52
43
53
.. tabs-drivers::
44
54
@@ -82,18 +92,26 @@ content: |
82
92
}
83
93
}
84
94
---
85
- title : Create a New Data Key
95
+ title : Create a New Data Encryption Key
86
96
ref : create-a-new-data-key
87
97
content : |
88
- The development data key was generated from a local master key, so you
89
- need to generate a new data key from the remote master key. To
90
- generate the key from an AWS KMS master key, you will need to know the
91
- key's AWS region and `Amazon Resource Number
98
+ The following diagram shows how the **customer master key** is created and
99
+ stored when using a KMS provider:
100
+
101
+ .. image:: /figures/CSFLE_Data_Key_KMS.png
102
+ :alt: Diagram that describes creating a data encryption key when using a KMS provider
103
+
104
+ You must generate a new **data encryption key** using the **master key**
105
+ in the remote KMS. The original data encryption key was encrypted by
106
+ your locally-managed master key.
107
+
108
+ Specify the AWS region and `Amazon Resource Number
92
109
<https://docs.aws.amazon.com/kms/latest/developerguide/viewing-keys.html#find-cmk-id-arn>`_
93
- (ARN).
110
+ (ARN) of the new CMK in the CSFLE-enabled client settings. Use the client
111
+ to create a new data encryption key as follows:
94
112
95
113
Once you have the required information, run the following code to
96
- generate the new data key:
114
+ generate the new data encryption key:
97
115
98
116
.. tabs-drivers::
99
117
@@ -173,10 +191,9 @@ content: |
173
191
data_key_id = client_encryption.create_data_key("aws")
174
192
175
193
---
176
- title : Update the JSON Schema
194
+ title : Update the Automatic Encryption JSON Schema
177
195
ref : update-the-json-schema
178
196
content : |
179
- If you have embedded the key id for your data encryption key in your JSON
180
- Schema by hardcoding the string value, you will need to update your
181
- :ref:`JSON Schema <fle-define-a-json-schema>` with the new key id of your data
182
- encryption key.
197
+ If you embedded the key id of your data encryption key in your
198
+ automatic encryption rules, you will need to update the :ref:`JSON
199
+ Schema <fle-define-a-json-schema>` with the new data encryption key id.
0 commit comments