encryptedfields mongoose encrypt

Solutions on MaxInterview for encryptedfields mongoose encrypt by the best coders in the world

showing results for - "encryptedfields mongoose encrypt"
Nicolás
29 Oct 2020
1// encrypt age regardless of any other options. name and _id will be left unencrypted
2userSchema.plugin(encrypt, { encryptionKey: encKey, signingKey: sigKey, encryptedFields: ['age'] });
3
Cameron
25 Feb 2016
1// exclude age from encryption, still encrypt name. _id will also remain unencrypted
2userSchema.plugin(encrypt, { encryptionKey: encKey, signingKey: sigKey, excludeFromEncryption: ['age'] });
3