Google Common Expression Language
(opensource.google)- सुरक्षा नीतियाँ, प्रोटोकॉल आदि को लिखने और मूल्यांकन करने के लिए एक expression language
→ छोटी और तेज़, embed और extend की जा सकने वाली, तथा developer-friendly
→ C जैसी syntax
-
Google ने Firebase के security rules बनाते समय विकसित किए गए spec का विस्तार किया है
-
Protocol Buffer type का उपयोग, JSON समर्थन
-
C++ और Go में बना high-performance evaluator open source के रूप में उपलब्ध
service cloud.firestore {
match /databases/{database}/documents {
// यदि उपयोगकर्ता लॉग-इन है या अनुरोधित डेटा public है तो true
function signedInOrPublic() {
return request.auth.uid != null || resource.data.visibility == 'public';
}
match /cities/{city} {
allow read, write: if signedInOrPublic();
}
match /users/{user} {
allow read, write: if signedInOrPublic();
}
}
}
1 टिप्पणियां
Caddy 2 रिलीज़ - बेहतर प्रदर्शन वाला और आसान HTTPS ऑटो-सपोर्ट वेब सर्वर https://hi.news.hada.io/topic?id=2028
Caddy वेब सर्वर भी Request Matcher जैसी चीज़ों को कॉन्फ़िगर करते समय CEL का उपयोग करता है.
https://caddyserver.com/docs/caddyfile/matchers