How do I prevent anonymous users from deleting/editing my documents in couchDB?
couchdb, function, security, validation
Solution
Another way to restrict access to your database is to configure the `[couch_httpd_auth]` with `require_valid_user:true`
Then every request must send credentials to login to your couchdb.
Problem
I know that CouchDB does not allow non-admin users to edit/delete design documents, but how do I prevent them from editing/deleting all documents? The only info I could find is that user permissions can be set with validation functions. I am a little confused on how I would write a validation function to do this/where validation functions live. Are they all in the _users DB? Thanks