|
I am not able to implement collection level access control. Here are the steps and commands I have used:
1. created db authdb
2. Created collections in db - collection1, collection2, collection3, collection4, collection5.
3. db.createRole( {role:"collection1Read", privileges: [ { resource:
{db: "authdb", collection: "collection1"}
, actions: ["find"]}],roles:["read"]});
4. db.createUser({user: "user1Read", pwd: "user", roles: [
{role: "collection1Read", db: "authdb"}
]});
5. Now if I login as user1Read, I can all collections both by command line or through RoboMongo.
It doesn't work with the steps provided.
|