1 #include "permission/worker_permission.h" 2 3 #include <string> 4 #include <vector> 5 6 namespace node { 7 8 namespace permission { 9 10 // Currently, PolicyDenyWorker manage a single state 11 // Once denied, it's always denied Apply(const std::string& allow, PermissionScope scope)12void WorkerPermission::Apply(const std::string& allow, PermissionScope scope) { 13 deny_all_ = true; 14 } 15 is_granted(PermissionScope perm, const std::string_view& param)16bool WorkerPermission::is_granted(PermissionScope perm, 17 const std::string_view& param) { 18 return deny_all_ == false; 19 } 20 21 } // namespace permission 22 } // namespace node 23