Live data from Hacker News

MongoDB Releases Queryable Encryption Preview

mongodb.com

41–50 of 69 posts

Re: MongoDB Releases Queryable Encryption Preview

#41
post #34

Earlier quoted context omitted.

Not sure about any specific use cases for this Mongo feature, but security requirements are often just checkboxes without much thought put behind them, or not valid in certain contexts, like SaaS/cloud. Classic example is on-prem enterprises requiring data encryption at rest when moving to a cloud vendor. I can explain to a client that encrypting an S3 bucket with an AWS-managed key doesn't really prevent anything be…

> that encrypting an S3 bucket with an AWS-managed key doesn't really prevent anything beyond someone physically stealing a hard drive from the AWS data center It does, though. To get that data, you now need access to the bucket itself _and_ the KMS-managed encryption key. You might not be protecting the data from AWS, but one bucket misconfiguration doesn't lead to wholesale data loss now. Is it perfect? No. You can…

To be clear, I"m talking about using the default "AWS KMS key" as they call it now, not managing your own keys. Just click the box on S3 and it's encrypted at rest, but completely transparent. If a user has access to the S3 bucket, they have access to the data within it. This has been sufficient for every enterprise client I've worked with because it checks the "data encrypted at rest" box for SOC2, ISO-27001, etc.

Re: MongoDB Releases Queryable Encryption Preview

#42

This feature is a result of MongoDB's acquisition of Aroki. It looks like a good product but we actually beat them to it with https://cipherstash.com/activestash CipherStash works with any Database and also supports Range queries and sorting/ordering. We do it in the application layer. Only supports Ruby so far but C#, Java, Python, Rust are in the works.

What about Go, or even Tcl, and Ocaml? Do you have pointers to docs that'd help OSS efforts in this department?

Re: MongoDB Releases Queryable Encryption Preview

#43

This is a really neat technology, but I don't understand it's use case. I've worked in HealthTech and currently in the compliance space. I'm skeptical of Mongo's claims (and their familiarity with compliance laws). Kind of feels like a solution in search of a problem. "In use" implies that you have a need to process that data. It doesn't matter if the end client is submitting queries in plain text (protected in trans…

No post body was provided.

Re: MongoDB Releases Queryable Encryption Preview

#44
post #23

This is a really neat technology, but I don't understand it's use case. I've worked in HealthTech and currently in the compliance space. I'm skeptical of Mongo's claims (and their familiarity with compliance laws). Kind of feels like a solution in search of a problem. "In use" implies that you have a need to process that data. It doesn't matter if the end client is submitting queries in plain text (protected in trans…

> It doesn't matter if the end client is submitting queries in plain text (protected in transit) or this fancy encryption It's not just the query that is encrypted in this case, but the data being queried. From MongoDB's description, the server never receives or stores plaintext data, and the query results can only be decrypted by a client who has the same key that was used to encrypt the data in the first place. Fro…

Yes, and in the context of Mongo-as-a-Service, it's amazing both to the client and also the service provider (less liability).

Re: MongoDB Releases Queryable Encryption Preview

#45

Help me understand this... It says it will support prefix search, substring search, and the like. Can anyone point me in the right direction on what the algorithm may be here? I don't get how you could do those things without making the encryption less secure and/or decrypting every record the fly. Another interesting use case I found that isn't mentioned here is sort. I've had customers ask me to be able to sort the…

These things are indeed possible while maintaining fully semantically secure encryption. Recent, mostly theoretical work shows that this is possible using fully homomorphic encryption. The basic idea is, the client can encrypt its query, the server can process the encrypted query and produce an encrypted result, and send this back to the client. It sounds impossible, but it isn’t! Very cool stuff. There are actually also some practical implementations that work… so it’s gradually exiting the “theoretical only” stage.

MongoDB is very short on details, and I suspect they do something worse than homomorphic encryption, that does indeed make some kind of compromise between privacy and convenience.

Re: MongoDB Releases Queryable Encryption Preview

#46
post #45

Help me understand this... It says it will support prefix search, substring search, and the like. Can anyone point me in the right direction on what the algorithm may be here? I don't get how you could do those things without making the encryption less secure and/or decrypting every record the fly. Another interesting use case I found that isn't mentioned here is sort. I've had customers ask me to be able to sort the…

These things are indeed possible while maintaining fully semantically secure encryption. Recent, mostly theoretical work shows that this is possible using fully homomorphic encryption. The basic idea is, the client can encrypt its query, the server can process the encrypted query and produce an encrypted result, and send this back to the client. It sounds impossible, but it isn’t! Very cool stuff. There are actually…

Yeah, they contrast their method with homomorphic encryption, which makes me share your suspicion

Re: MongoDB Releases Queryable Encryption Preview

#47
post #46
post #45

Earlier quoted context omitted.

These things are indeed possible while maintaining fully semantically secure encryption. Recent, mostly theoretical work shows that this is possible using fully homomorphic encryption. The basic idea is, the client can encrypt its query, the server can process the encrypted query and produce an encrypted result, and send this back to the client. It sounds impossible, but it isn’t! Very cool stuff. There are actually…

Yeah, they contrast their method with homomorphic encryption, which makes me share your suspicion

Yeah, I've been looking for more information and I can't really see any indication as to how they are planning on implementing it. The whole thing seems more like marketing than actual innovation: searching encrypted data isn't that complicated if you are always dealing with the entire ciphertext, it's just another string in that use case.

Re: MongoDB Releases Queryable Encryption Preview

#48
post #27

Earlier quoted context omitted.

This seems more applicable for the SaaS hosting model where the database service is managed by a 3rd party. So the use case is "I trust your SaaS service is compliant with my legal obligations to protect my customer data, but it'd be easier for everyone involved if your database service also has no way of seeing sensitive data fields. That would make it easier for me to pass my compliance audits, otherwise I need to…

The problem is that situation doesn't really exist. At an organizational level, it's extremely hard to control what information get put into a SaaS. There are far too many ways in which data can be de-anonymized or inferred against (e.g. a field existing can have privacy implications). It's far safer to use a SaaS provider that meets general control requirements than to try to shoe-horn encrypted data into them.

Correct, a database feature can't prevent errant developers from posting customer credit card numbers on Twitter either, but compliance auditors won't accept "We don't bother encrypting data because it's pointless!" as an answer. The very real use case here is when private contracts between an end customer and a service provider says "You are in breach of this contract if load my data to any 3rd party service that has the ability to see my data, regardless of whether they use that ability or not. You are allowed to use that other service if you extend your audit program to also audit that other service provider according to my standards and report back to me." I've personally seen this situation prevent the use of SaaS. An encryption control like this where the 3rd party doesn't have keys to decrypt the data is considered satisfactory.

Re: MongoDB Releases Queryable Encryption Preview

#49

Help me understand this... It says it will support prefix search, substring search, and the like. Can anyone point me in the right direction on what the algorithm may be here? I don't get how you could do those things without making the encryption less secure and/or decrypting every record the fly. Another interesting use case I found that isn't mentioned here is sort. I've had customers ask me to be able to sort the…

Related video explaining encryption schemes to make encrypted data in a DB queryable:

CryptDB: Processing Queries on an Encrypted Database

https://youtu.be/xsaXMUelOEA?t=807

Re: MongoDB Releases Queryable Encryption Preview

#50
This is really neat. Recently I explored similar functionality for relational databases and only got as far as implementing column-level encryption [0] in this Go library [1], but without support for querying the encrypted data. HashiCorp Vault's transit secrets engine supports Convergent Encryption [2] which provides limited ability to query the encrypted data, but I haven't yet experimented with it. If anyone is doing something like this in production, would love to hear about your experience.

[0]: https://en.wikipedia.org/wiki/Column_Level_Encryption

[1]: https://github.com/bincyber/go-sqlcrypter

[2]: https://www.vaultproject.io/docs/secrets/transit#convergent-...

Post reply on HN