Skip to content

Commit b8821d8

Browse files
DOCSP-38147 "Choosing an In Use Encryption Approach" crypto team review (#7058)
* New topic, TOC update, refs * TOC and link restructuring to move limitations topics up * Fixed drawer page * Shorter title * Title fixes * Added stub headings * Stub headings * More topic structure * Copied language on implementation considerations to main QE and CSFLE topics * Typo fix * Reordered headings * Fixed heading level * Parallel wording * Reorder * Fixed ref typo * Removed unused stubs and links to them * Added draft language for security considerations * Added link for client-side schema enforcement * Updated image * Internal PR feedback Co-authored-by: Ashley Brown <98361885+mdb-ashley@users.noreply.github.com> * Internal PR feedback Co-authored-by: Ashley Brown <98361885+mdb-ashley@users.noreply.github.com> * Internal PR feedback Co-authored-by: Ashley Brown <98361885+mdb-ashley@users.noreply.github.com> * Rebuild * Updated CSFLE features topic to use same image * Updated image * Image update * Image update * Removed ambiguous/misleading statement about CSFLE being a mature security product * Some re-wording of the term implementation * Consolidated some limitations for brevity * Split bullet * Changed the order of some statements to move important info up * Reverted image to master --------- Co-authored-by: Ashley Brown <98361885+mdb-ashley@users.noreply.github.com>
1 parent d6e965a commit b8821d8

File tree

11 files changed

+132
-77
lines changed

11 files changed

+132
-77
lines changed

snooty.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@ toc_landing_pages = [
7878
"/core/kerberos",
7979
"/core/map-reduce",
8080
"/core/queryable-encryption/",
81+
"/core/queryable-encryption/about-qe-csfle",
8182
"/core/queryable-encryption/fundamentals/keys-key-vaults",
8283
"/core/queryable-encryption/fundamentals/",
8384
"/core/queryable-encryption/overview-enable-qe",

source/core/csfle.txt

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,17 @@ You can set up {+csfle-abbrev+} using the following mechanisms:
2929
specify the logic for encryption with this library throughout your
3030
application.
3131

32+
Considerations
33+
--------------
34+
35+
When implementing an application that uses {+csfle+}, consider the points listed in :ref:`Security Considerations <qe-csfle-security-considerations>`.
36+
37+
For limitations, see :ref:`{+csfle-abbrev+} limitations
38+
<csfle-reference-encryption-limits>`.
39+
40+
Compatibility
41+
~~~~~~~~~~~~~
42+
3243
The following table shows which MongoDB server products support which {+csfle-abbrev+}
3344
mechanisms:
3445

@@ -97,13 +108,11 @@ To learn how to perform specific tasks with {+csfle-abbrev+}, see the
97108
Reference
98109
---------
99110

100-
To view information to help you develop your {+csfle-abbrev+} enabled applications,
101-
see the :ref:`csfle-reference` section.
111+
To learn about encryption key management, read :ref:`qe-reference-keys-key-vaults`.
102112

103-
The reference section contains the following pages:
113+
For more information about developing your {+csfle-abbrev+}-enabled applications,
114+
see the :ref:`csfle-reference` section, which contains the following pages:
104115

105-
- :ref:`csfle-compatibility-reference`
106-
- :ref:`csfle-reference-encryption-limits`
107116
- :ref:`csfle-reference-encryption-schemas`
108117
- :ref:`csfle-reference-server-side-schema`
109118
- :ref:`csfle-reference-automatic-encryption-supported-operations`

source/core/csfle/features.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ Comparison of Features
124124
The following diagram lists security features MongoDB supports
125125
and the potential security vulnerabilities that they address:
126126

127-
.. image:: /images/CSFLE_Security_Feature_Chart.png
127+
.. image:: /images/QE_Security_Feature_Chart.png
128128
:alt: Diagram that describes MongoDB security features and the potential vulnerabilities that they address
129129

130130
.. important:: Use the Mechanisms Together

source/core/csfle/fundamentals.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,9 @@ Fundamentals
1212
:depth: 2
1313
:class: singlecol
1414

15-
Read the following sections to learn how {+csfle+} works and how to use it:
15+
To learn about encryption key management, read :ref:`qe-reference-keys-key-vaults`.
16+
17+
To learn how {+csfle+} works and how to use it, read the following sections:
1618

1719
- :ref:`csfle-fundamentals-automatic-encryption`
1820
- :ref:`csfle-fundamentals-manual-encryption`

source/core/csfle/reference.txt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ Reference
1515
Read the following sections to learn about components
1616
of the {+csfle+} ({+csfle-abbrev+}) feature:
1717

18-
- :ref:`csfle-reference-encryption-limits`
1918
- :ref:`csfle-reference-encryption-schemas`
2019
- :ref:`csfle-reference-server-side-schema`
2120
- :ref:`csfle-reference-automatic-encryption-supported-operations`
@@ -30,7 +29,6 @@ of the {+csfle+} ({+csfle-abbrev+}) feature:
3029
.. toctree::
3130
:titlesonly:
3231

33-
/core/csfle/reference/limitations
3432
/core/csfle/reference/encryption-schemas
3533
/core/csfle/reference/server-side-schema
3634
/core/csfle/reference/supported-operations

source/core/csfle/reference/limitations.txt

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
.. meta::
2+
:keywords: CSFLE, in-use encryption, security, supported operations
3+
14
.. _csfle-reference-encryption-limits:
25

36
=================
@@ -12,6 +15,13 @@ CSFLE Limitations
1215
:depth: 1
1316
:class: singlecol
1417

18+
Overview
19+
--------
20+
Consider these limitations and restrictions before you enable {+csfle-abbrev+}.
21+
Some operations are unsupported, and others behave differently.
22+
23+
For compatibility limitations, see :ref:`<qe-csfle-compatibility>`.
24+
1525
Read and Write Operation Support
1626
--------------------------------
1727

source/core/queryable-encryption.txt

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,12 @@ You can set up {+qe+} using the following mechanisms:
5656
Considerations
5757
--------------
5858

59+
When implementing an application that uses {+qe+}, consider the points listed
60+
in :ref:`Security Considerations <qe-csfle-security-considerations>`.
61+
62+
For other limitations, see :ref:`{+qe+} limitations
63+
<qe-reference-encryption-limits>`.
64+
5965
Compatibility
6066
~~~~~~~~~~~~~
6167

@@ -112,16 +118,16 @@ To start using {+qe+}, see the :ref:`<qe-quick-start>`.
112118
Fundamentals
113119
------------
114120

115-
To learn how {+qe+} works and how to set it up, see the
116-
:ref:`<qe-fundamentals>` section.
121+
To learn about encryption key management, see :ref:`qe-reference-keys-key-vaults`.
117122

118-
The fundamentals section contains the following pages:
123+
To learn how {+qe+} works, see the :ref:`<qe-fundamentals>` section,
124+
which contains the following pages:
119125

120126
- :ref:`qe-fundamentals-encrypt-query`
127+
- :ref:`qe-create-encryption-schema`
121128
- :ref:`qe-fundamentals-collection-management`
122-
- :ref:`qe-reference-keys-key-vaults`
129+
- :ref:`qe-fundamentals-manual-encryption`
123130
- :ref:`qe-fundamentals-manage-keys`
124-
- :ref:`qe-fundamentals-kms-providers`
125131

126132
Tutorials
127133
---------
@@ -137,12 +143,8 @@ see the :ref:`qe-reference` section.
137143

138144
The reference section contains the following pages:
139145

140-
- :ref:`qe-compatibility-reference`
141-
- :ref:`qe-reference-encryption-limits`
142146
- :ref:`qe-reference-automatic-encryption-supported-operations`
143147
- :ref:`qe-reference-mongo-client`
144-
- :ref:`qe-csfle-install-library`
145-
- :ref:`qe-reference-libmongocrypt`
146148

147149
.. toctree::
148150
:titlesonly:

source/core/queryable-encryption/about-qe-csfle.txt

Lines changed: 83 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,84 @@ to encrypt data before transporting it over the network. Sensitive data is
3030
transparently encrypted and decrypted by the client and only
3131
communicated to and from the server in encrypted form.
3232

33-
For more information, see :ref:`{+qe+} Features <qe-features>` and
33+
To compare features in detail, see :ref:`{+qe+} Features <qe-features>` and
3434
:ref:`{+csfle-abbrev+} Features <csfle-features>`.
3535

36+
Considerations
37+
--------------
38+
39+
When implementing and application that uses {+qe+} or {+csfle-abbrev+}, review
40+
the security considerations in this section.
41+
42+
For the limitations of each approach, see :ref:`{+qe+} limitations
43+
<qe-reference-encryption-limits>` or :ref:`{+csfle-abbrev+} limitations
44+
<csfle-reference-encryption-limits>`.
45+
46+
For MongoDB server and driver version compatibility, see :ref:`Compatibility
47+
<qe-csfle-compatibility>`.
48+
49+
.. _qe-csfle-security-considerations:
50+
51+
Security Considerations
52+
~~~~~~~~~~~~~~~~~~~~~~~
53+
54+
* {+csfle-abbrev+} and {+qe+} do not provide any cryptographic integrity
55+
guarantees against adversaries with access to your {+cmk-long+},
56+
{+dek-long+}s.
57+
58+
* {+csfle-abbrev+} and {+qe+} do not provide any cryptographic integrity
59+
guarantees against adversaries with arbitrary write access to collections
60+
containing encrypted data.
61+
62+
* MongoDB uses :ref:`schema validation <schema-validation-overview>` to enforce
63+
encryption of specific fields in a collection. Without a client-side schema,
64+
the client downloads the server-side schema for the collection to determine
65+
which fields to encrypt. To avoid this issue, use client-side schema validation.
66+
67+
Because {+csfle-abbrev+} and {+qe+} do not provide a mechanism to verify
68+
the integrity of a schema, relying on a server-side schema means
69+
trusting that the server's schema has not been tampered with. If an adversary
70+
compromises the server, they can modify the schema so that a previously
71+
encrypted field is no longer labeled for encryption. This causes the client
72+
to send plaintext values for that field.
73+
74+
For an example of {+csfle-abbrev+} configuration for client and server-side
75+
schemas, see :ref:`CSFLE Server-Side Field Level Encryption Enforcement <field-level-encryption-automatic-remote-schema>`.
76+
77+
78+
Using {+qe+} and {+csfle-abbrev+}
79+
------------------------------------------------------------------------
80+
81+
You can use {+qe+}, {+csfle+}, or both in your application. However,
82+
you can't use both approaches in the same collection.
83+
84+
Consider using {+qe+} in the following scenarios:
85+
86+
- You are developing a new application and want to use the latest
87+
cryptographic advancements from MongoDB.
88+
- You expect users to run ranged, prefix, suffix, or substring queries
89+
against encrypted data.
90+
- Your application can use a single key for a given field, rather than
91+
requiring separate keys on a per-user or per-tenant basis.
92+
- You value read performance over storage requirements. {+qe+} generates
93+
internal :ref:`metadata collections <qe-metadata-collections>` and
94+
indexes to improve query performance. As a result, a collection
95+
encrypted with {+qe+} uses 2-4 times the storage space that it would
96+
if it were plaintext or encrypted with {+csfle-abbrev+}.
97+
98+
There are situations where {+csfle-abbrev+} may be a preferable solution:
99+
100+
- Your application already uses {+csfle-abbrev+}.
101+
- You need to use different keys for the same field. This is commonly
102+
encountered when separating tenants or using user-specific keys.
103+
- You need to be flexible with your data schema and potentially add more
104+
encrypted fields. Adding encrypted fields for {+qe+}
105+
requires rebuilding metadata collections and indexes.
106+
- The increased storage requirements of {+qe+} are a concern.
107+
36108
Querying Encrypted Fields
37109
~~~~~~~~~~~~~~~~~~~~~~~~~
110+
38111
{+qe+} supports equality queries on encrypted fields.
39112
Support for ranged queries is upcoming, and support for prefix, suffix,
40113
and substring queries with {+qe+} is under development.
@@ -76,44 +149,6 @@ field has very few values, like sex, then attackers can reasonably guess
76149
them and use that information to help to decipher the cryptographic
77150
algorithm.
78151

79-
Using {+qe+} and {+csfle-abbrev+}
80-
------------------------------------------------------------------------
81-
You can use {+qe+}, {+csfle+}, or both in your application. However,
82-
you can't use both approaches in the same collection.
83-
84-
Consider using {+qe+} in the following scenarios:
85-
86-
- You are developing a new application and want to use the latest
87-
cryptographic advancements from MongoDB.
88-
- You expect users to run ranged, prefix, suffix, or substring queries
89-
against encrypted data.
90-
- Your application can use a single key for a given field, rather than
91-
requiring separate keys on a per-user or per-tenant basis.
92-
- You value read performance over storage requirements. {+qe+} generates
93-
internal :ref:`metadata collections <qe-metadata-collections>` and
94-
indexes to improve query performance. As a result, a collection
95-
encrypted with {+qe+} uses 2-4 times the storage space that it would
96-
if it were plaintext or encrypted with {+csfle-abbrev+}.
97-
98-
There are situations where {+csfle-abbrev+} may be a preferable solution:
99-
100-
- Your application already uses {+csfle-abbrev+}.
101-
- You need to use different keys for the same field. This is commonly
102-
encountered when separating tenants or using user-specific keys.
103-
- You need to be flexible with your data schema and potentially add more
104-
encrypted fields. Adding encrypted fields for {+qe+}
105-
requires rebuilding metadata collections and indexes.
106-
- The increased storage requirements of {+qe+} are a concern.
107-
- Your company or industry prefers mature products over emerging
108-
technologies.
109-
110-
Compatibility
111-
~~~~~~~~~~~~~
112-
{+qe+} and {+csfle+} are compatible with different MongoDB server and
113-
driver versions. Both {+qe+} and {+csfle-abbrev+} are supported for the
114-
foreseeable future. For details, see :ref:`Compatibility
115-
<qe-csfle-compatibility>`.
116-
117152
Private Querying
118153
~~~~~~~~~~~~~~~~
119154

@@ -123,18 +158,12 @@ With {+qe+}, private querying goes a step further and redacts logs and
123158
metadata to scrub information around the query's existence. This ensures
124159
stronger privacy and confidentiality.
125160

126-
Limitations
127-
~~~~~~~~~~~
128-
129-
For the limitations of each approach, see :ref:`{+qe+} limitations
130-
<qe-reference-encryption-limits>` or :ref:`{+csfle-abbrev+} limitations
131-
<csfle-reference-encryption-limits>`.
132-
133161
Choosing Between Automatic and {+manual-enc-title+}
134162
---------------------------------------------------------
135163

136164
Using Automatic Encryption
137165
~~~~~~~~~~~~~~~~~~~~~~~~~~
166+
138167
We recommend automatic encryption in most situations, as it streamlines
139168
the process of writing your client application. With automatic
140169
encryption, MongoDB automatically encrypts and decrypts fields in read
@@ -146,4 +175,11 @@ Using {+manual-enc-title+}
146175
.. include:: /includes/queryable-encryption/qe-csfle-manual-enc-overview.rst
147176

148177
For details, see :ref:`{+manual-enc-title+} with {+qe+}
149-
<qe-fundamentals-manual-encryption>` or :ref:`{+manual-enc-title+} with {+csfle-abbrev+} <csfle-fundamentals-manual-encryption>`.
178+
<qe-fundamentals-manual-encryption>` or :ref:`{+manual-enc-title+} with
179+
{+csfle-abbrev+} <csfle-fundamentals-manual-encryption>`.
180+
181+
.. toctree::
182+
:titlesonly:
183+
184+
/core/queryable-encryption/reference/limitations
185+
/core/csfle/reference/limitations

source/core/queryable-encryption/fundamentals.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,9 @@ Fundamentals
1212
:depth: 2
1313
:class: singlecol
1414

15-
Read the following sections to learn how {+qe+} works and how to use it:
15+
To learn about encryption key management, read :ref:`qe-reference-keys-key-vaults`.
16+
17+
To learn how {+qe+} works and how to use it, read the following sections:
1618

1719
- :ref:`qe-fundamentals-encrypt-query`
1820
- :ref:`qe-create-encryption-schema`

source/core/queryable-encryption/reference.txt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,11 @@ Reference
1515
Read the following sections to learn about components
1616
of {+qe+}:
1717

18-
- :ref:`qe-reference-encryption-limits`
1918
- :ref:`qe-reference-automatic-encryption-supported-operations`
2019
- :ref:`qe-reference-mongo-client`
2120

2221
.. toctree::
2322
:titlesonly:
2423

25-
/core/queryable-encryption/reference/limitations
2624
/core/queryable-encryption/reference/supported-operations
2725
/core/queryable-encryption/reference/qe-options-clients

0 commit comments

Comments
 (0)