Skip to content

Commit db64e3c

Browse files
committed
chore(deps): bump mongodb-client-encryption to 1.2.6
1 parent 1646c21 commit db64e3c

File tree

6 files changed

+9
-26
lines changed

6 files changed

+9
-26
lines changed

packages/service-provider-core/package-lock.json

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/service-provider-core/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
"mongodb-connection-string-url": "^1.0.0"
3636
},
3737
"optionalDependencies": {
38-
"mongodb-client-encryption": "^1.2.5"
38+
"mongodb-client-encryption": "^1.2.6"
3939
},
4040
"dependency-check": {
4141
"entries": [

packages/service-provider-server/package-lock.json

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/service-provider-server/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646
"mongodb-connection-string-url": "^1.0.0"
4747
},
4848
"optionalDependencies": {
49-
"mongodb-client-encryption": "^1.2.5",
49+
"mongodb-client-encryption": "^1.2.6",
5050
"os-dns-native": "^1.0.3",
5151
"resolve-mongodb-srv": "^1.1.0",
5252
"kerberos": "^1.1.5"

packages/shell-api/src/field-level-encryption.spec.ts

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -185,15 +185,6 @@ describe('Field Level Encryption', () => {
185185
});
186186
});
187187
describe('createKey', () => {
188-
beforeEach(() => {
189-
// This can/should be removed once https://jira.mongodb.org/browse/NODE-3118 is fixed
190-
sinon.replace(keyVault, 'getKey', sinon.fake(() => {
191-
return { next() { return { keyAltNames: ['altname'] }; } };
192-
}));
193-
});
194-
afterEach(() => {
195-
sinon.restore();
196-
});
197188
it('calls createDataKey on libmongoc with no key for local', async() => {
198189
const raw = { result: 1 };
199190
const kms = 'local';

packages/shell-api/src/field-level-encryption.ts

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,6 @@ export class KeyVault extends ShellApiWithMongoClass {
122122
createKey(kms: ClientEncryptionDataKeyProvider, options: AWSEncryptionKeyOptions | AzureEncryptionKeyOptions | GCPEncryptionKeyOptions | undefined, keyAltNames: string[]): Promise<Document>
123123
@returnsPromise
124124
@apiVersions([1])
125-
// eslint-disable-next-line complexity
126125
async createKey(
127126
kms: ClientEncryptionDataKeyProvider,
128127
masterKeyOrAltNames?: AWSEncryptionKeyOptions | AzureEncryptionKeyOptions | GCPEncryptionKeyOptions | string | undefined | string[],
@@ -175,14 +174,7 @@ export class KeyVault extends ShellApiWithMongoClass {
175174
};
176175
}
177176

178-
const keyId = await this._clientEncryption._libmongocrypt.createDataKey(kms, options as ClientEncryptionCreateDataKeyProviderOptions);
179-
// This can/should be removed once https://jira.mongodb.org/browse/NODE-3118 is fixed
180-
if (options?.keyAltNames?.length && !(await this.getKey(keyId).next())?.keyAltNames?.length) {
181-
for (const altname of options.keyAltNames) {
182-
await this.addKeyAlternateName(keyId, altname);
183-
}
184-
}
185-
return keyId;
177+
return await this._clientEncryption._libmongocrypt.createDataKey(kms, options as ClientEncryptionCreateDataKeyProviderOptions);
186178
}
187179

188180
@returnType('Cursor')

0 commit comments

Comments
 (0)