[MONGOCRYPT-450] Remove unnecessary fields from rewrapManyDataKey result Created: 28/Jun/22 Updated: 28/Oct/23 Resolved: 28/Jun/22 |
|
| Status: | Closed |
| Project: | Libmongocrypt |
| Component/s: | Field Level Encryption |
| Affects Version/s: | None |
| Fix Version/s: | 1.5.0, 1.6.0, 1.6.0-alpha0 |
| Type: | Improvement | Priority: | Unknown |
| Reporter: | Ezra Chung | Assignee: | Ezra Chung |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||
| Binding Changes: | Not Needed | ||||||||||||
| Description |
Summarylibmongocrypt is arbitrarily (and misleadingly) making an effort to return all fields of the key document(s) being rewrapped by rewrapManyDataKey. Only _id, keyMaterial, and masterKey are required to construct the bulk write operations to update rewrapped key documents in the key vault collection. MotivationWho is the affected end user?Drivers implementing rewrapManyDataKey. How does this affect the end user?Avoids unnecessarily consuming memory for unused fields in the resulting documents. How likely is it that this problem or use case will occur?Unlikely; Drivers should not be using any of the extra fields in the key document(s). This is also asserted by the CSE unified spec tests. If the problem does occur, what are the consequences and how severe are they?Not severe. Returning a "full" key document gives the mistaken impression that a replaceOne operation may be appropriate to update the given key document in the key vault collection. Is this issue urgent?No. Is this ticket required by a downstream team?No. Is this ticket only for tests?No. It has functional impact, but the impact should be minimal/none. |
| Comments |
| Comment by Githook User [ 28/Jun/22 ] |
|
Author: {'name': 'Ezra Chung', 'email': '88335979+eramongodb@users.noreply.github.com', 'username': 'eramongodb'}Message: |
| Comment by Githook User [ 28/Jun/22 ] |
|
Author: {'name': 'Ezra Chung', 'email': '88335979+eramongodb@users.noreply.github.com', 'username': 'eramongodb'}Message: |