Open dguedry opened 7 years ago
Turns out that the following statement was evaluating to true in CollectionEncryption:
if (self.schema && !Match.test(doc, self.schema)) { // if the document does not match the schema we stop before encrypting // since collection2 will deny the db insert anyway return doc; }
I commented it out and the inserts are being encrypted now.
Really cool solution. Are inserts into collections not encrypted? Updates encrypt just fine, but when initially inserting, I get plain text on the server-side collection. Thanks.