From 909f5a700a24d0d02fbcf31a80d7f7404e9bf88c Mon Sep 17 00:00:00 2001 From: emadum Date: Tue, 9 Mar 2021 12:21:33 -0500 Subject: [PATCH] fix(csfle): ensure that monitoring connections are not encrypted --- lib/core/sdam/monitor.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/core/sdam/monitor.js b/lib/core/sdam/monitor.js index e86cba3d08..e681a4ba1a 100644 --- a/lib/core/sdam/monitor.js +++ b/lib/core/sdam/monitor.js @@ -91,6 +91,10 @@ class Monitor extends EventEmitter { // ensure no authentication is used for monitoring delete connectOptions.credentials; + + // ensure encryption is not requested for monitoring + delete connectOptions.autoEncrypter; + this.connectOptions = Object.freeze(connectOptions); }