I want to have a dynamic control on storage rules from database. I mean it should check database nodes to allow read or write. But I cannot find a way. For example
match /files/{fileKey} {
allow read: // here will check db to get result of allowRead
allow write: // here will check db to get result allowWrite
}
db:
files: {
fileKey1: {
allowRead: true,
allowWrite: false
},
fileKey2: {
allowRead: true,
allowWrite: true
}