简体   繁体   English

Derby.js(Racer)访问控制

[英]Derby.js (Racer) access control

I'm new in Derby.js environment, and as far as I see Racer is exposing all the data on client side. 我是Derby.js环境中的新手,据我所知,Racer公开了客户端的所有数据。

So, basically anybody could manipulate any data stored on server? 那么,基本上任何人都可以操纵存储在服务器上的任何数据? Am I correct? 我对么? Is there any way to manage access control? 有没有办法管理访问控制?

There is plugin for Racer - racer-access Racer有一个插件 - racer-access

Use it like this: 像这样使用它:

var racerAccess = require('racer-access');
derby.use(racerAccess);
store.allow('change', 'users', function (some usefull arguments) {
    return true || false;
});

At now racer-access is deprecated. 现在不推荐使用racer-access You can use share-access . 您可以使用共享访问权限

It seems share-access is now deprecated in favor of sharedb-access . 似乎现在不赞成使用share-access来支持sharedb-access

Here's a related discussion on the Derby mailing list "racer-access deprecated". 以下是关于Derby邮件列表“racer-access deprecated”相关讨论。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM